You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Grant Rettke <gr...@acm.org> on 2009/05/01 01:41:05 UTC

Clarification on dependencyManagement

Hi folks,

When you use the dependencyManagement section in a parent POM, its
purpose is to allow for children to optionally specify those entries
dependencies, without a version number. It is a convenience.

When you specify them, though, are you making those entries serve as
dependencies for the POM in which they are defined?

My understanding is YES, because if you were to enter them in the
dependencies section, they they would automatically be dependencies in
the child POM, too.

Best wishes,

Grant

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Clarification on dependencyManagement

Posted by Nick Stolwijk <ni...@gmail.com>.
NO, ;) , not all dependencies in the parent should be dependencies of
the child, that is completely up to the child project. For example, in
the parent pom you have defined the depManagement for Hibernate,
Spring-MVC and commons-validator. You have different child modules:
project-web, project-model and project-data. Project-web should have a
dependency on spring-mvc and commons-validator, project-data on
hibernate and project-model on commons-validator. You set the version
numbers in the parent pom and define the exact dependencies in the
child poms.

Hth,

Nick Stolwijk
~Java Developer~

Iprofs BV.
Claus Sluterweg 125
2012 WS Haarlem
www.iprofs.nl



On Fri, May 1, 2009 at 1:41 AM, Grant Rettke <gr...@acm.org> wrote:
> My understanding is YES, because if you were to enter them in the
> dependencies section, they they would automatically be dependencies in
> the child POM, too.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org