Details
Description
At the moment maven plugin use it internal defaults about embedded Jetty version that plugin use.
I with to have an ability to specify Jetty's version something like this:
<configuration>
<container>
<containerId>jetty6x</containerId>
<type>embedded</type>
<version>6.1.7</version>
</container>
and it looks natural that maven plugin will pick up particular Jetty version from maven repository (http://www.mvnrepository.com/artifact/org.mortbay.jetty/jetty) together with all its depenedencies.
—
@alitokmen: I rather think it will probably be something like:
<configuration>
<container>
<containerId>jetty6x</containerId>
<type>embedded</type>
<properties>
<jetty.version>6.1.7</jetty.version>
<servlet-api.version>2.5</servlet-api.version>
</properties>
</container>
</configuration>
Therefore, the user would declare all versions of dependencies to override. We would in this case need to document all usable properties somewhere, and keep the list updated.
This is not as simple as it looks. For example, the current embedded Jetty 6 implementation needs 17 other dependencies for it to work (and these are not all automatically brought in through the maven dependency management). What happens when the Jetty version is updated and the dependencies change or the versions of the dependencies change.
I don't like the way we have it right now where the dependencies and their versions are hard coded.
So we have two options:
1) try and keep a list of dependencies for each of the embedded Jetty versions (or version groups, ie 6.1.x). For these embedded servers, the version of the org.mortbay.jetty dependencies will be set via the version option, but the version of the other dependencies will be hardcoded. This makes it easy for the user, but introduces problems if the other Jetty versions don't agree with the other hardcoded dependencies.
or
2) don't hardcode anything and make the user list every dependency in the pom file and use those instead. This gives the user full control, but also means more work on the users part.
or both could be possible. Give the user the option to specify the jetty version and use option 1 (which makes it easy for the user), or allow the user to specify some other variable and then make them specify each dependency (which gives the user more control).