[ 
https://issues.apache.org/jira/browse/MNG-5666?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16597453#comment-16597453
 ] 

Robert Scholte edited comment on MNG-5666 at 8/30/18 1:41 PM:
--------------------------------------------------------------

Have a look at 
https://github.com/apache/maven/commit/b10f7a8ce21e37e6deef73d9ba70d0c33099c125 

It is not just about the build/default lifecycle, also the site lifecycle can 
benefit from it. I thought about phaseGroups, but that will make it extra hard 
in a reactor to know when a dependent module is finished, so better go pre-, 
main- and postPhases.
Stages/staging might be too confusing as it can also be a part of the release 
(life)cycle.

Keep in mind that users can define their own lifecycle too, so Maven should 
still be able to parse only the {{phases}} list.


was (Author: rfscholte):
Have a look at 
https://github.com/apache/maven/commit/b10f7a8ce21e37e6deef73d9ba70d0c33099c125 

It is not just about the build/default lifecycle, also the site lifecycle can 
benefit from it. I thought about phaseGroups, but that will make it extra hard 
in a reactor to know when a dependent module is finished, so better go pre-, 
main- and postPhases.
Stages/staging might be too confusing as it can also be a part of the release 
(life)cycle.

> Divide lifecycle in prePhases, phases and postPhases
> ----------------------------------------------------
>
>                 Key: MNG-5666
>                 URL: https://issues.apache.org/jira/browse/MNG-5666
>             Project: Maven
>          Issue Type: Sub-task
>          Components: FDPFC, Plugins and Lifecycle
>            Reporter: Robert Scholte
>            Assignee: Jason van Zyl
>            Priority: Major
>             Fix For: 3.x / Backlog
>
>
> Original proposal
> {quote}
> PROPOSAL 1: PerProject and PerPhase Executions
>  
> I've recently introduced the installAtEnd/deployAtEnd as an experimental 
> feature which should improve the behavior of Maven without having to wait for 
> the implementation in Maven Core, which would have a huge impact.
> The reason is that you only want to install and/or deploy only after all 
> modules have been build and verified successfully.
> This feature works for most projects, however there are cases which cannot be 
> solved by the plugin solution and require a change in the handling of 
> lifecycles in Maven Core.
> Up unto the verify-phase you want to execute all phases per project, whereas 
> the install and deploy should be executed per phase.
> Consider a root project with 2 modules, these should be executed like this
>  
> root   : validate ... verify
> module1: validate ... verify
> module2: validate ... verify
> root   : install
> module1: install
> module2: install
> root   : deploy
> module1: deploy
> module2: deploy
> {quote}
> After one of the google hangout session we came up with the following idea: 
> divide the build in pre-build, build and post-build
> First the {{pre-build}} would do a validate of the whole project.
> The {{build}} runs from {{initialize}} up to {{verify}}
> The {{post-build}} would handle the distribution, being {{install}}/{{deploy}}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to