Maven: Lifecycle vs. Phase vs. Plugin vs. Goal -


A relatively new developer here, though I've been using it for a while, hoping to strengthen my maven Fundamental things One part of my problem is that I have a no experience with ant, from where many explanations reveal. I am reading and watching the tutorial, and I keep hearing the same terms:

  • Lifecycle
  • Step
  • Plugin
  • Target

What I have learned is that lifecycle is the largest part of the bunch, and is composed of steps (steps), plugins and / or targets. / P>

Question : Can you provide any information about the most common examples related to these terms?

More clear and basic, better!

Its not perfect in its fulfillment.

Specifically:

Each of these steps can be the goal of running a step after the pre- or post- For example:

Pre-install - ...
Post-package - ...

If you want you can see the targets as additional "inserted" steps .

[Wrong stereotypes of myths.]

A Maven life cycle one (abstract) The concept is that all the steps (or better: the Maven designers have decided to support all the steps) is included in the project's development life expectancy. These steps (or steps) are in the Maven terminology in phase .

A Maven plugin is a target / container. The code implemented in the targets is real workhorse (). The goals of each plugin can be assigned to any lifecycle phase.

mvn & lt; Step & gt; Maven passes all the steps (each time) and executes all targets (provided by plugins) which is bound to any step < / Strong> If the given step is not a goal in which there is no goal, then nothing is done. But still the phase has passed.

I.e You can not insert additional steps into one of Maven's underlying lifestyles. They can not already exist! You can develop your own life cycle with your stages, but it is beyond just using Maven.

"pre-installed" or "post-package" is not present.

Reference:


  • If you ever wondered how Maven knows that there is a link at the end of the POM bounded with no target, Code> & lt; Your Maven Installation & gt; Located in /lib/maven-core-xyzjar/META-INF/plexus/default-bindings.xml
    .


Comments

Popular posts from this blog

java - Can't add JTree to JPanel of a JInternalFrame -

javascript - data.match(var) not working it seems -

javascript - How can I pause a jQuery .each() loop, while waiting for user input? -