Re: Removing: jar from forked lifecycle, to prevent recursive invocation

2010-01-21 Thread mfs

Hi Guys,

Though I see this warning (while using javadoc plugin), but so far its not
been a worry for me and everything is working fine. Still I had some
questions for the maven experts here to get a better understanding of
this...


Stephen mentioned in this thread, that it would be dangerous if the
plugin:mojo is NOT removed from the forked lifecycle, since the mojo could
cause yet another forked lifecycle and hence result in a recursive
invocation. 

QUESTION 1 - Isn't the above statement only true, IF the forked-lifecyle
(caused by the mojo execution) passes through (or reaches) the PARTICULARLY
phase where the plugin was injected or configured to execute at the first
place. For example, I know the javadoc:javadoc mojo forks a new lifecycle
till the generate-sources phase before executing the javadoc mojo itself,
now lets say If I had injected the javadoc mojo to the install phase,
there is NO danger of recursive invocation, since the new forked-lifecyle
initiated by the javadoc mojo never reaches the install phase. Yes, If
instead I had hooked the javadoc:javadoc mojo to the generate-sources (or
any of the earlier) phase , then certainly I see the execution getting stuck
in a recursive loop.. Please comment...

QUESTION 2 - I see the Removing [mojo] from forked lifecycle, to prevent
recursive invocation warning only if i inject the mojo (e.g. javadoc) to
the build cycle phases (be it clean, default or even site lifecyle phase)
using the build section. If Instead I move the same definition to
reporting section, which in other word means the plugin/mojo would only
execute in the site lifecyle (if i am not wrong) then I don't see the
warning at all. I wonder why is that ? Isn't the danger of recursive
invocation still there (ignoring my first question) ?

Thanks in advance,

Farhan.




Stephen Connolly-2 wrote:
 
 It'd be dangerous is it didn't remove the jar mojo from the forked
 lifecycle, as the jar mojo is the mojo that forked the lifecycle in
 the first place... and if it didn't remove the plugin from the forked
 lifecycle, the forked lifecycle would fork again... and again and
 again
 
 2009/2/18 Romain Gilles romain.gil...@thomsonreuters.com:
 Is it a dangerous for my build ?
 If yes, how can I find where the problem comes from ?

 Thanks,

 Romain.


 -Original Message-
 From: Brian E. Fox [mailto:bri...@reply.infinity.nu]
 Sent: 18 February 2009 01:31
 To: Maven Users List
 Subject: RE: Removing: jar from forked lifecycle, to prevent recursive
 invocation

 This means the plugin that caused the fork to occur is removed from that
 forked lifecycle so it doesn't fork again.

 -Original Message-
 From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com]
 Sent: Tuesday, February 17, 2009 5:08 AM
 To: Maven Users List
 Subject: Removing: jar from forked lifecycle, to prevent recursive
 invocation


 Hi all,
 I have this message during my build process but I don't understand it:

 Removing: jar from forked lifecycle, to prevent recursive invocation

 It does not provide the name of the Jar, is there anybody that can help
 me, please?

 Romain.

 This email was sent to you by Thomson Reuters, the global news and
 information company.
 Any views expressed in this message are those of the individual sender,
 except where the sender specifically states them to be the views of
 Thomson Reuters.



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


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



 This email was sent to you by Thomson Reuters, the global news and
 information company.
 Any views expressed in this message are those of the individual sender,
 except where the sender specifically states them to be the views of
 Thomson Reuters.



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


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

-- 
View this message in context: 
http://old.nabble.com/Removing%3A-jar-from-forked-lifecycle%2C-to-prevent-recursive-invocation-tp22054923p27264347.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



RE: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-08-05 Thread Chris McMillan

  Removing: jar from forked lifecycle, to prevent recursive invocation

I don't know if you are still looking for an answer to how to fix this
problem but what I found to fix the problem for me was to change the
maven-source-plugin goal from jar to jar-no-fork. I also had to add
version2.1/version as well. You may also need to change test-jar to
test-jar-no-fork. 

The information was not immediately obvious to me but 
http://maven.apache.org/plugins/maven-source-plugin/ Maven Source Plugin
Help  was where I found the information.

Chris McMillan


-- 
View this message in context: 
http://www.nabble.com/Removing%3A-jar-from-forked-lifecycle%2C-to-prevent-recursive-invocation-tp22054923p24831242.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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



RE: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-02-20 Thread Todd Thiessen
bump... Is anyone able provide some insite here? It would be really nice
to remove warnings such as this from my build ;-).

---
Todd Thiessen
 

 -Original Message-
 From: Thiessen, Todd (BVW:9T16) 
 Sent: Wednesday, February 18, 2009 9:05 AM
 To: 'Maven Users List'
 Subject: RE: Removing: jar from forked lifecycle, to prevent 
 recursive invocation
 
 I am wondering if Brian, or any other Maven expert our there, 
 could explain how this warning could be avoided entirely. I 
 have looked into this at length when adding, for example, 
 source jars to my distribution. However, the warning always occurs.
 
 I have a pretty good understanding of why the warning occurs. 
 If you look at the documentation for the source plugin here:
 
 http://maven.apache.org/plugins/maven-source-plugin/jar-mojo.html
 
 You will notice in the fourth bullet it says:
 
 * Invokes the execution of the lifecycle phase 
 generate-sources prior to executing itself.
 
 Thus, if you attach this goal to your build, then if you 
 execute any phase at or above package (if you use the default 
 phase binding of package) then this plugin effectively runs 
 the lifecycle twice; once up to generate-sources when it 
 executes the goal, then again for your actual build. The 
 warning is just letting you know that running the lifecycle 
 twice isn't necessary since the generate-sources phase will 
 get executed via the execution of the package phase.
 
 I also understand that the goal is purposefully designed this 
 way so it can be called from the command line and still 
 behave as expected without having to explicitly generate 
 sources if any sources need to be generated.
 
 So I believe I understand the warning, but I would love to 
 properly configure the plugin such that it does not emmit 
 this warning when attaching the goal to your build.  Or 
 perhaps this warning should simply be suppressed entirely 
 since Maven already seems to be aware of plugins which fork 
 their own lifecycle when bound to a phase of the lifecycle 
 and properly remove the extra fork. The warning seems to 
 cause more confusion than anything else.
 
 My best guess is that for now, this is just part of Maven's 
 core architecture and hasn't been important enough to change. 
 Some of this may be fixed in the 3.0 release but I can't be 
 sure of that.  Hopefully some of the experts could comment further.
 
 ---
 Todd Thiessen
  
 
  -Original Message-
  From: Brian E. Fox [mailto:bri...@reply.infinity.nu]
  Sent: Tuesday, February 17, 2009 7:31 PM
  To: Maven Users List
  Subject: RE: Removing: jar from forked lifecycle, to 
 prevent recursive 
  invocation
  
  This means the plugin that caused the fork to occur is removed from 
  that forked lifecycle so it doesn't fork again.
  
  -Original Message-
  From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com]
  Sent: Tuesday, February 17, 2009 5:08 AM
  To: Maven Users List
  Subject: Removing: jar from forked lifecycle, to prevent recursive 
  invocation
  
  
  Hi all,
  I have this message during my build process but I don't 
 understand it:
  
  Removing: jar from forked lifecycle, to prevent recursive 
 invocation
  
  It does not provide the name of the Jar, is there anybody that can 
  help me, please?
  
  Romain.
  
  This email was sent to you by Thomson Reuters, the global news and 
  information company.
  Any views expressed in this message are those of the individual 
  sender, except where the sender specifically states them to be the 
  views of Thomson Reuters.
  
  
  
  
 -
  To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
  For additional commands, e-mail: users-h...@maven.apache.org
  
  
  
 -
  To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
  For additional commands, e-mail: users-h...@maven.apache.org
  
  
 

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



Re: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-02-18 Thread Stephen Connolly
It'd be dangerous is it didn't remove the jar mojo from the forked
lifecycle, as the jar mojo is the mojo that forked the lifecycle in
the first place... and if it didn't remove the plugin from the forked
lifecycle, the forked lifecycle would fork again... and again and
again

2009/2/18 Romain Gilles romain.gil...@thomsonreuters.com:
 Is it a dangerous for my build ?
 If yes, how can I find where the problem comes from ?

 Thanks,

 Romain.


 -Original Message-
 From: Brian E. Fox [mailto:bri...@reply.infinity.nu]
 Sent: 18 February 2009 01:31
 To: Maven Users List
 Subject: RE: Removing: jar from forked lifecycle, to prevent recursive
 invocation

 This means the plugin that caused the fork to occur is removed from that
 forked lifecycle so it doesn't fork again.

 -Original Message-
 From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com]
 Sent: Tuesday, February 17, 2009 5:08 AM
 To: Maven Users List
 Subject: Removing: jar from forked lifecycle, to prevent recursive
 invocation


 Hi all,
 I have this message during my build process but I don't understand it:

 Removing: jar from forked lifecycle, to prevent recursive invocation

 It does not provide the name of the Jar, is there anybody that can help
 me, please?

 Romain.

 This email was sent to you by Thomson Reuters, the global news and
 information company.
 Any views expressed in this message are those of the individual sender,
 except where the sender specifically states them to be the views of
 Thomson Reuters.



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


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



 This email was sent to you by Thomson Reuters, the global news and 
 information company.
 Any views expressed in this message are those of the individual sender, 
 except where the sender specifically states them to be the views of Thomson 
 Reuters.



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



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



RE: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-02-18 Thread Todd Thiessen
I am wondering if Brian, or any other Maven expert our there, could
explain how this warning could be avoided entirely. I have looked into
this at length when adding, for example, source jars to my distribution.
However, the warning always occurs.

I have a pretty good understanding of why the warning occurs. If you
look at the documentation for the source plugin here:

http://maven.apache.org/plugins/maven-source-plugin/jar-mojo.html

You will notice in the fourth bullet it says:

* Invokes the execution of the lifecycle phase generate-sources prior to
executing itself.

Thus, if you attach this goal to your build, then if you execute any
phase at or above package (if you use the default phase binding of
package) then this plugin effectively runs the lifecycle twice; once up
to generate-sources when it executes the goal, then again for your
actual build. The warning is just letting you know that running the
lifecycle twice isn't necessary since the generate-sources phase will
get executed via the execution of the package phase.

I also understand that the goal is purposefully designed this way so it
can be called from the command line and still behave as expected without
having to explicitly generate sources if any sources need to be
generated.

So I believe I understand the warning, but I would love to properly
configure the plugin such that it does not emmit this warning when
attaching the goal to your build.  Or perhaps this warning should simply
be suppressed entirely since Maven already seems to be aware of plugins
which fork their own lifecycle when bound to a phase of the lifecycle
and properly remove the extra fork. The warning seems to cause more
confusion than anything else.

My best guess is that for now, this is just part of Maven's core
architecture and hasn't been important enough to change. Some of this
may be fixed in the 3.0 release but I can't be sure of that.
Hopefully some of the experts could comment further.

---
Todd Thiessen
 

 -Original Message-
 From: Brian E. Fox [mailto:bri...@reply.infinity.nu] 
 Sent: Tuesday, February 17, 2009 7:31 PM
 To: Maven Users List
 Subject: RE: Removing: jar from forked lifecycle, to prevent 
 recursive invocation
 
 This means the plugin that caused the fork to occur is 
 removed from that forked lifecycle so it doesn't fork again.
 
 -Original Message-
 From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com]
 Sent: Tuesday, February 17, 2009 5:08 AM
 To: Maven Users List
 Subject: Removing: jar from forked lifecycle, to prevent 
 recursive invocation
 
 
 Hi all,
 I have this message during my build process but I don't understand it:
 
 Removing: jar from forked lifecycle, to prevent recursive invocation
 
 It does not provide the name of the Jar, is there anybody 
 that can help
 me, please?
 
 Romain.
 
 This email was sent to you by Thomson Reuters, the global news and
 information company.
 Any views expressed in this message are those of the 
 individual sender,
 except where the sender specifically states them to be the views of
 Thomson Reuters.
 
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
 For additional commands, e-mail: users-h...@maven.apache.org
 
 

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



RE: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-02-17 Thread Brian E. Fox
This means the plugin that caused the fork to occur is removed from that
forked lifecycle so it doesn't fork again.

-Original Message-
From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com] 
Sent: Tuesday, February 17, 2009 5:08 AM
To: Maven Users List
Subject: Removing: jar from forked lifecycle, to prevent recursive
invocation


Hi all,
I have this message during my build process but I don't understand it:

Removing: jar from forked lifecycle, to prevent recursive invocation

It does not provide the name of the Jar, is there anybody that can help
me, please?

Romain.

This email was sent to you by Thomson Reuters, the global news and
information company.
Any views expressed in this message are those of the individual sender,
except where the sender specifically states them to be the views of
Thomson Reuters.



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


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



RE: Removing: jar from forked lifecycle, to prevent recursive invocation

2009-02-17 Thread Romain Gilles
Is it a dangerous for my build ?
If yes, how can I find where the problem comes from ?

Thanks,

Romain.


-Original Message-
From: Brian E. Fox [mailto:bri...@reply.infinity.nu] 
Sent: 18 February 2009 01:31
To: Maven Users List
Subject: RE: Removing: jar from forked lifecycle, to prevent recursive
invocation

This means the plugin that caused the fork to occur is removed from that
forked lifecycle so it doesn't fork again.

-Original Message-
From: Romain Gilles [mailto:romain.gil...@thomsonreuters.com] 
Sent: Tuesday, February 17, 2009 5:08 AM
To: Maven Users List
Subject: Removing: jar from forked lifecycle, to prevent recursive
invocation


Hi all,
I have this message during my build process but I don't understand it:

Removing: jar from forked lifecycle, to prevent recursive invocation

It does not provide the name of the Jar, is there anybody that can help
me, please?

Romain.

This email was sent to you by Thomson Reuters, the global news and
information company.
Any views expressed in this message are those of the individual sender,
except where the sender specifically states them to be the views of
Thomson Reuters.



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


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



This email was sent to you by Thomson Reuters, the global news and information 
company.
Any views expressed in this message are those of the individual sender, except 
where the sender specifically states them to be the views of Thomson Reuters.



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