You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Sony Antony <so...@gmail.com> on 2011/07/23 18:08:41 UTC

Maven build order

We have a fairly large project, that uses teh following 3 constructs in
various pom files
<dependency>
<parent>
<module>


Given that, will maven reactor come out with the correct order after
considering all of these ?
I inherited this project recently from somebody else.
I havent completed my investigation. but it appeared that it doesnt consider
<parent> clause while deciding teh build order. Could this be true ?

--sony

Re: Maven build order

Posted by Wayne Fay <wa...@gmail.com>.
> In this scenario should it be expected that maven reactor  will figure out
> the correct build order and will follow that ( I mean it will make sure that
> parents are built first. And similarly that dependencies are built first )

Generally yes the reactor will figure out the correct build order.

Wayne

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


Re: Maven build order

Posted by Sony Antony <so...@gmail.com>.
Thanks
This Project starts their build at a pom which pulls in many other pins
though <module> statements
Which in turns pulls in even more poms
Some of these are dependencies of others
Some are parents of others
Some are launched as modules of others
In this scenario should it be expected that maven reactor  will figure out
the correct build order and will follow that ( I mean it will make sure that
parents are built first. And similarly that dependencies are built first )
--sony

On Saturday, July 23, 2011, Jeff Jensen <je...@upstairstechnology.com>
wrote:
> The parent and dependencies must exist, either in a repo (heavily
> preferred) or via a specified relative path.  It does not "build"
> parent or a dependency, as with a module (or itself).
>
> However, if module A is a dependency of module B and both are listed
> as modules of a common parent, when you run a build of the parent,
> Maven will build them in the correct order: A, B.
>
>
> On Sat, Jul 23, 2011 at 11:08 AM, Sony Antony <so...@gmail.com>
wrote:
>> We have a fairly large project, that uses teh following 3 constructs in
>> various pom files
>> <dependency>
>> <parent>
>> <module>
>>
>>
>> Given that, will maven reactor come out with the correct order after
>> considering all of these ?
>> I inherited this project recently from somebody else.
>> I havent completed my investigation. but it appeared that it doesnt
consider
>> <parent> clause while deciding teh build order. Could this be true ?
>>
>> --sony
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: Maven build order

Posted by Jeff Jensen <je...@upstairstechnology.com>.
The parent and dependencies must exist, either in a repo (heavily
preferred) or via a specified relative path.  It does not "build"
parent or a dependency, as with a module (or itself).

However, if module A is a dependency of module B and both are listed
as modules of a common parent, when you run a build of the parent,
Maven will build them in the correct order: A, B.


On Sat, Jul 23, 2011 at 11:08 AM, Sony Antony <so...@gmail.com> wrote:
> We have a fairly large project, that uses teh following 3 constructs in
> various pom files
> <dependency>
> <parent>
> <module>
>
>
> Given that, will maven reactor come out with the correct order after
> considering all of these ?
> I inherited this project recently from somebody else.
> I havent completed my investigation. but it appeared that it doesnt consider
> <parent> clause while deciding teh build order. Could this be true ?
>
> --sony

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