Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] artifact and version to use in a POM

Greetings,

Jetty has indeed undergone several transformations in version 7, including having been moved into org.eclipse namespace, and been split into multiple modules, so you will have to figure out whichever modules your application will now have dependency on and include all these modules. Below is a sample dependency block that establishes dependency on jetty-servlets module containing several useful servlets.

    <dependency>
        <groupId>org.eclipse.jetty</groupId>
        <artifactId>jetty-servlets</artifactId>
        <version>7.0.1.v20091125</version>
        <type>jar</type>
        <scope>compile</scope>
    </dependency>

The following wiki may be helpful in determining dependencies in Jetty 7, although it may require some adjustments to account for the changes between the version of Jetty you are using and Jetty 6...

http://wiki.eclipse.org/Jetty/Starting/Porting_to_Jetty_7/Packages_and_Classes

Finally, in order to use Jetty Maven Plugin, you will need to add the following plugin definition to the <plugins> section to your application's pom.xml and tweak the settings in it (e.g. change context path, etc.)

    <plugin>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty-maven-plugin</artifactId>
            <version>7.0.1.v20091125</version>
            <configuration>
                    <stopPort>9966</stopPort>
                    <stopKey>mortbay</stopKey>
                    <webAppConfig>
                            <contextPath>/</contextPath>
                    </webAppConfig>
            </configuration>
    </plugin>

Michael Gorovoy / michael@xxxxxxxxxxx


On Wed, Jan 27, 2010 at 10:53 AM, Lorenzo Bigagli <lorenzo.bigagli@xxxxxxxx> wrote:
I'm having quite a few problems figuring out the information in object.

In the JXSE project, we have been using the following dependency so far:

<dependency>
<groupId>jetty</groupId>
<artifactId>org.mortbay.jetty</artifactId>
<version>4.2.27</version>
<optional>true</optional>
</dependency>

I understand that jetty had been moved, repackaged and renamed a few times since.
How should the POM snippet above be modified, to use the latest Jetty 7 maven plugin?

Thanks,
  Lorenzo




_______________________________________________
jetty-users mailing list
jetty-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-users



Back to the top