You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by /U <um...@comcast.net> on 2009/04/19 23:45:28 UTC

"Goal: clean already exists in the plugin descriptor for prefix: ..."

Env:
   Maven 2.1.0
   JDK 1.6.x
   OS: RHEL4

I have written two MOJOs to create some configurations and to clean the
generated configs. I have hence a mojo that implements the :clean" goal
and another MOJO that implements a "bootstrap" goal.

The Mojos are functioning as intended. But when I run 

       mvn javadoc:javadoc site:site site:deploy

at the top level (this is a multi-module project), the build aborts in the
plugin project with a strange error:

  Error extracting plugin descriptor: 
     'Goal: clean already exists in the plugin descriptor for prefix:
my-plugin-framework'

I am flummoxed and have no clue what the problem is. Any help is greatly
appreciated!

Trace is below.

Regards

/U



$ mvn -X javadoc:javadoc site:site site:deploy
+ Error stacktraces are turned on.
Apache Maven 2.1.0 (r755702; 2009-03-18 12:10:27-0700)
Java version: 1.6.0_01
Java home: /opt/jdk1.6.0_01/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux" version: "2.6.9-42.7.elsmp" arch: "i386" Family: "unix"
[DEBUG] Building Maven user-level plugin registry from:
'/home/me/.m2/plugin-registry.xml'
[DEBUG] Building Maven global-level plugin registry from:
'/opt/maven/conf/plugin-registry.xml'
[INFO] Scanning for projects...
[INFO] Reactor build order:

//...

[INFO] Executing tasks
[INFO] Executed tasks
[INFO]
------------------------------------------------------------------------
[INFO] Building My Maven Plugin
[INFO]
------------------------------------------------------------------------
[DEBUG] Adding managed dependencies for
org.apache.maven.plugins:maven-plugin-plugin
[DEBUG]	  org.apache.maven.plugin-tools:maven-plugin-tools-api:jar:2.4.3
[DEBUG]
//...

[DEBUG] Configuring mojo
'org.apache.maven.plugins:maven-plugin-plugin:2.4.3:descriptor' -->
[DEBUG]	  (f) outputDirectory = /src/my-plugin/target/classes/META-INF/maven
[DEBUG]	  (f) project = MavenProject:
x.plugins:my-plugin-framework:1.0-SNAPSHOT @ /src/my-plugin/pom.xml
[DEBUG] -- end configuration --
[INFO] [plugin:descriptor]
[INFO] Using 2 extractors.
[INFO] Applying extractor for language: java
[INFO] Extractor for language: java found 4 mojo descriptors.
[DEBUG] Adding mojo: org.apache.maven.plugin.descriptor.MojoDescriptor
[role: 'org.apache.maven.plugin.Mojo', hint:
'x.plugins:my-plugin-framework:1.0-SNAPSHOT:clean'] to plugin descriptor.
[DEBUG] Adding mojo: org.apache.maven.plugin.descriptor.MojoDescriptor
[role: 'org.apache.maven.plugin.Mojo', hint:
'x.plugins:my-plugin-framework:1.0-SNAPSHOT:clean'] to plugin descriptor.
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ---------------------------------------------------------------------
[INFO] Error extracting plugin descriptor: 'Goal: clean already exists in
the plugin descriptor for prefix: my-plugin-framework
Existing implementation is: x.plugins.MyFrameworkCleanMojo
Conflicting implementation is: x.plugins.MyFrameworkCleanMojo'

[INFO]
------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error extracting
plugin descriptor: 'Goal: clean already exists in the plugin descriptor for
prefix: my-plugin-framework
Existing implementation is: x.plugins.MyFrameworkCleanMojo
Conflicting implementation is: x.plugins.MyFrameworkCleanMojo'
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:703)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:540)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.forkProjectLifecycle(DefaultLifecycleExecutor.java:1168)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.forkLifecycle(DefaultLifecycleExecutor.java:1004)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:647)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:553)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:523)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:371)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:332)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:181)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:356)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:137)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:356)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Error extracting
plugin descriptor: 'Goal: clean already exists in the plugin descriptor for
prefix: my-plugin-framework
Existing implementation is: x.plugins.MyFrameworkCleanMojo
Conflicting implementation is: x.plugins.MyFrameworkCleanMojo'
	at
org.apache.maven.plugin.plugin.AbstractGeneratorMojo.execute(AbstractGeneratorMojo.java:158)
	at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:483)
	at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:678)
	... 20 more
Caused by:
org.apache.maven.plugin.descriptor.DuplicateMojoDescriptorException: Goal:
clean already exists in the plugin descriptor for prefix:
my-plugin-framework
Existing implementation is: x.plugins.MyFrameworkCleanMojo
Conflicting implementation is: x.plugins.MyFrameworkCleanMojo
	at
org.apache.maven.plugin.descriptor.PluginDescriptor.addMojo(PluginDescriptor.java:106)
	at
org.apache.maven.tools.plugin.scanner.DefaultMojoScanner.populatePluginDescriptor(DefaultMojoScanner.java:110)
	at
org.apache.maven.plugin.plugin.AbstractGeneratorMojo.execute(AbstractGeneratorMojo.java:146)
	... 22 more
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 1 minute 1 second
[INFO] Finished at: Sun Apr 19 13:22:19 PDT 2009
[INFO] Final Memory: 53M/96M
[INFO]
------------------------------------------------------------------------
$ 

-- 
View this message in context: http://www.nabble.com/%22Goal%3A-clean-already-exists-in-the-plugin-descriptor-for-prefix%3A-...%22-tp23127658p23127658.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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