You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "David Jackman (JIRA)" <ji...@codehaus.org> on 2005/11/10 18:34:06 UTC

[jira] Created: (MNG-1499) Execution order is arbitrary if inheritance is involved

Execution order is arbitrary if inheritance is involved
-------------------------------------------------------

         Key: MNG-1499
         URL: http://jira.codehaus.org/browse/MNG-1499
     Project: Maven 2
        Type: Bug
  Components: maven-project  
    Reporter: David Jackman


According to the documentation, "When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first."  I assume that the order of the inherited executions would be in the order specified in the parent POM, but the docs are unclear here.

However, in practice, it seems the ordering is as documented if there is no inheritance from the parent.  But if there are plugins inherited, then the ordering is completely arbitrary, with the inherited plugins not necessarily coming first.  I created a project that runs two plugins, both bound to the same phase, with one specified in the parent and one specified in the project.  The parent-specified plugin does not run first.

-- 
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] Updated: (MNG-1499) Execution order is arbitrary if inheritance is involved

Posted by "David Jackman (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1499?page=all ]

David Jackman updated MNG-1499:
-------------------------------

    Attachment: MNG-1499.patch

The attached patch fixes this problem.  Instead of keeping the list of merged plugins for parent and child in a map, it keeps the list in a List.  (It still uses the maps to make sure plugins are only executed once if mentioned in both parent and child.)

> Execution order is arbitrary if inheritance is involved
> -------------------------------------------------------
>
>          Key: MNG-1499
>          URL: http://jira.codehaus.org/browse/MNG-1499
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: David Jackman
>  Attachments: MNG-1499.patch
>
>
> According to the documentation, "When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first."  I assume that the order of the inherited executions would be in the order specified in the parent POM, but the docs are unclear here.
> However, in practice, it seems the ordering is as documented if there is no inheritance from the parent.  But if there are plugins inherited, then the ordering is completely arbitrary, with the inherited plugins not necessarily coming first.  I created a project that runs two plugins, both bound to the same phase, with one specified in the parent and one specified in the project.  The parent-specified plugin does not run first.

-- 
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-1499) Execution order is arbitrary if inheritance is involved

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

    Resolution: Fixed

Applied. Thanks, David.

> Execution order is arbitrary if inheritance is involved
> -------------------------------------------------------
>
>          Key: MNG-1499
>          URL: http://jira.codehaus.org/browse/MNG-1499
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: David Jackman
>     Assignee: John Casey
>      Fix For: 2.0.1
>  Attachments: MNG-1499-b.patch, MNG-1499.patch
>
>
> According to the documentation, "When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first."  I assume that the order of the inherited executions would be in the order specified in the parent POM, but the docs are unclear here.
> However, in practice, it seems the ordering is as documented if there is no inheritance from the parent.  But if there are plugins inherited, then the ordering is completely arbitrary, with the inherited plugins not necessarily coming first.  I created a project that runs two plugins, both bound to the same phase, with one specified in the parent and one specified in the project.  The parent-specified plugin does not run first.

-- 
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] Updated: (MNG-1499) Execution order is arbitrary if inheritance is involved

Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1499?page=all ]

John Casey updated MNG-1499:
----------------------------

    Fix Version: 2.0.1

> Execution order is arbitrary if inheritance is involved
> -------------------------------------------------------
>
>          Key: MNG-1499
>          URL: http://jira.codehaus.org/browse/MNG-1499
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: David Jackman
>     Assignee: John Casey
>      Fix For: 2.0.1
>  Attachments: MNG-1499-b.patch, MNG-1499.patch
>
>
> According to the documentation, "When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first."  I assume that the order of the inherited executions would be in the order specified in the parent POM, but the docs are unclear here.
> However, in practice, it seems the ordering is as documented if there is no inheritance from the parent.  But if there are plugins inherited, then the ordering is completely arbitrary, with the inherited plugins not necessarily coming first.  I created a project that runs two plugins, both bound to the same phase, with one specified in the parent and one specified in the project.  The parent-specified plugin does not run first.

-- 
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] Updated: (MNG-1499) Execution order is arbitrary if inheritance is involved

Posted by "David Jackman (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1499?page=all ]

David Jackman updated MNG-1499:
-------------------------------

    Attachment: MNG-1499-b.patch

After further inspection, I realized that the ModelUtils.mergePluginDefinitions method had the same problem.  The second attached patch fixes the problem there as well.  This patch also adds unit tests to cover these changes.

> Execution order is arbitrary if inheritance is involved
> -------------------------------------------------------
>
>          Key: MNG-1499
>          URL: http://jira.codehaus.org/browse/MNG-1499
>      Project: Maven 2
>         Type: Bug
>   Components: maven-project
>     Reporter: David Jackman
>  Attachments: MNG-1499-b.patch, MNG-1499.patch
>
>
> According to the documentation, "When multiple executions are given that match a particular phase, they are executed in the order specified in the POM, with inherited executions running first."  I assume that the order of the inherited executions would be in the order specified in the parent POM, but the docs are unclear here.
> However, in practice, it seems the ordering is as documented if there is no inheritance from the parent.  But if there are plugins inherited, then the ordering is completely arbitrary, with the inherited plugins not necessarily coming first.  I created a project that runs two plugins, both bound to the same phase, with one specified in the parent and one specified in the project.  The parent-specified plugin does not run first.

-- 
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