You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Brett Porter (JIRA)" <ji...@codehaus.org> on 2005/09/29 16:12:11 UTC

[jira] Created: (MNG-1045) resolve ordering of parent build in reactor

resolve ordering of parent build in reactor
-------------------------------------------

         Key: MNG-1045
         URL: http://jira.codehaus.org/browse/MNG-1045
     Project: Maven 2
        Type: Bug
  Components: maven-project  
 Reporter: Brett Porter
 Assigned to: Brett Porter 
     Fix For: 2.0-beta-3


previously, parent always built first. This caused issues with cycles when the parent depended on the child (Which may also be the case with modules and an aggregating root if that occurs).

Now, with the parent last, the "clean:clean" command is causing issues (previously it0065 - until dependency on parent's target directory was removed). A child is using/writing to the parent's target directory, and then clean comes and wipes it out.

- is this acceptable?
- what alternatives are there?

Currently proposed solution:
- parent is not factored into dependency graph to avoid cycles
- parent is forced to come before children if not aggregating
- parent is forced to come last if aggregating (currently aggregating doesn't run children anyway, relying on earlier output)





-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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


[jira] Commented: (MNG-1045) resolve ordering of parent build in reactor

Posted by "Bob Allison (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-1045?page=comments#action_47477 ] 

Bob Allison commented on MNG-1045:
----------------------------------

Not being up-to-speed on all the details of the DAG process, this may not be possible, but...

How about this approach:  Do not automatically add the parent-child edge.  After the entire graph is built, locate any projects which are isolated (no edges reach them) and place them at the end of the build.  The hard part I see in this is being able to locate the isolated projects (maybe add an int field to count the number of edges that reach a particular project).

Using this approach, no edges are added which can cause unexpected cycles.  If non-aggregating parents need to come first, then isolated projects can be added to the start and end as appropriate.

> resolve ordering of parent build in reactor
> -------------------------------------------
>
>          Key: MNG-1045
>          URL: http://jira.codehaus.org/browse/MNG-1045
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: Brett Porter
>     Assignee: Brett Porter
>      Fix For: 2.0-beta-3

>
>
> previously, parent always built first. This caused issues with cycles when the parent depended on the child (Which may also be the case with modules and an aggregating root if that occurs).
> Now, with the parent last, the "clean:clean" command is causing issues (previously it0065 - until dependency on parent's target directory was removed). A child is using/writing to the parent's target directory, and then clean comes and wipes it out.
> - is this acceptable?
> - what alternatives are there?
> Currently proposed solution:
> - parent is not factored into dependency graph to avoid cycles
> - parent is forced to come before children if not aggregating
> - parent is forced to come last if aggregating (currently aggregating doesn't run children anyway, relying on earlier output)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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


[jira] Commented: (MNG-1045) resolve ordering of parent build in reactor

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-1045?page=comments#action_47641 ] 

Brett Porter commented on MNG-1045:
-----------------------------------

irrelevant for the aggregation case as it will be last due to the goal being executed in a separate task set.

So parent should come first, but not incur cyclic deps.

> resolve ordering of parent build in reactor
> -------------------------------------------
>
>          Key: MNG-1045
>          URL: http://jira.codehaus.org/browse/MNG-1045
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: Brett Porter
>     Assignee: Brett Porter
>      Fix For: 2.0-beta-3

>
>
> previously, parent always built first. This caused issues with cycles when the parent depended on the child (Which may also be the case with modules and an aggregating root if that occurs).
> Now, with the parent last, the "clean:clean" command is causing issues (previously it0065 - until dependency on parent's target directory was removed). A child is using/writing to the parent's target directory, and then clean comes and wipes it out.
> - is this acceptable?
> - what alternatives are there?
> Currently proposed solution:
> - parent is not factored into dependency graph to avoid cycles
> - parent is forced to come before children if not aggregating
> - parent is forced to come last if aggregating (currently aggregating doesn't run children anyway, relying on earlier output)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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


[jira] Closed: (MNG-1045) resolve ordering of parent build in reactor

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1045?page=all ]
     
Brett Porter closed MNG-1045:
-----------------------------

    Resolution: Fixed

> resolve ordering of parent build in reactor
> -------------------------------------------
>
>          Key: MNG-1045
>          URL: http://jira.codehaus.org/browse/MNG-1045
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: Brett Porter
>     Assignee: Brett Porter
>      Fix For: 2.0-beta-3

>
>
> previously, parent always built first. This caused issues with cycles when the parent depended on the child (Which may also be the case with modules and an aggregating root if that occurs).
> Now, with the parent last, the "clean:clean" command is causing issues (previously it0065 - until dependency on parent's target directory was removed). A child is using/writing to the parent's target directory, and then clean comes and wipes it out.
> - is this acceptable?
> - what alternatives are there?
> Currently proposed solution:
> - parent is not factored into dependency graph to avoid cycles
> - parent is forced to come before children if not aggregating
> - parent is forced to come last if aggregating (currently aggregating doesn't run children anyway, relying on earlier output)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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


[jira] Commented: (MNG-1045) resolve ordering of parent build in reactor

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-1045?page=comments#action_47513 ] 

Brett Porter commented on MNG-1045:
-----------------------------------

I think that's the same as what I was suggesting. cool :)

> resolve ordering of parent build in reactor
> -------------------------------------------
>
>          Key: MNG-1045
>          URL: http://jira.codehaus.org/browse/MNG-1045
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: Brett Porter
>     Assignee: Brett Porter
>      Fix For: 2.0-beta-3

>
>
> previously, parent always built first. This caused issues with cycles when the parent depended on the child (Which may also be the case with modules and an aggregating root if that occurs).
> Now, with the parent last, the "clean:clean" command is causing issues (previously it0065 - until dependency on parent's target directory was removed). A child is using/writing to the parent's target directory, and then clean comes and wipes it out.
> - is this acceptable?
> - what alternatives are there?
> Currently proposed solution:
> - parent is not factored into dependency graph to avoid cycles
> - parent is forced to come before children if not aggregating
> - parent is forced to come last if aggregating (currently aggregating doesn't run children anyway, relying on earlier output)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


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