But I've also seen with the properties used with dependencyManagement
-- particularly with something like Spring or Camel that has tons of
JARs:

<properties>
  <spring.version>2.5.5</spring.version>
</properties>
...
<dependencyManagement>
  <dependency>
    <artifactId>spring-foo</artifactId>
    <version>${spring.version}</version>
    ...
  <dependency>
    <artifactId>spring-bar</artifactId>
    <version>${spring.version}</version>
    ...

Does that kind of usage have the same issue you described where if
some other dependency declares "spring.version" to be 2.5.3 then there
would be some confusion over which version to use?

Thanks,
      Aaron

On Thu, Sep 18, 2008 at 9:26 AM, Guillaume Nodet <[EMAIL PROTECTED]> wrote:
> Currently, we're mostly using properties to define versions of our 
> dependencies.
> For example,
> <properties>
>   <jaxb.api.version>2.1</jaxb.api.version>
> </properties>
>
> and later in a submodule:
>
>  <dependency>
>    <groupId>javax.xml.bind</groupId>
>    <artifactId>jaxb-api</artifactId>
>    <version>${jaxb.api.version}</version>
> </dependency>
>
> It seems that this way of handling dependencies does not work very well.
> If another dependency uses the same mechanism but with a different
> version, I've seen maven using the one from the dependency instead of
> the one specified in the root pom.
> I think we should change this mechanism and use the
> <dependencyManagement/> section of the pom instead.
>
> Thoughts ?
>
> --
> Cheers,
> Guillaume Nodet
> ------------------------
> Blog: http://gnodet.blogspot.com/
>
>

Reply via email to