Hi ,
I did relevant updates to m2 sources on local and updated m2 install for
plexus-container-default verison 1.0-alpha-10-SNAPSHOT. But still running into a
ClassNotFound error. Looks like its coming from Classworld libs.
I have posted the stacktrace at:
http://www.rafb.net/paste/results/tke4hi45.html
Could this be a Realm related issue with Classworlds (sorry, not very
well-versed with Classworlds). I am sure that implementation class I am
specifying is available via dependencies in project's pom.xml. Am I missing
something here or could this be a bug?
Cheers for any help!
Rahul
----- Original Message -----
From: "Brett Porter" <[EMAIL PROTECTED]>
To: "Maven Developers List" <dev@maven.apache.org>
Sent: Tuesday, January 03, 2006 10:46 AM
Subject: Re: Mapping complex object in Mojo Configuration
There is no plexus converter for String -> Class. We should probably
have one, so I'll add it now.
You'll need to use a String and do the forName yourself in the mean time.
- Brett
Rahul Thakur wrote:
Hi,
I am following the mini guide to set up a complex mapping for a Mojo.
http://maven.apache.org/guides/mini/guide-configuring-plugins.html
The POJO that models the complex type for Mojo configuration has a field
'implementation' of type java.lang.Class.
When I run the Mojo, I get an error:
Cause: Cannot assign configuration entry 'implementation' to 'class
java.lang.Class' from 'com.effacy.sample.EffacyTomcatConfiguration',
which is of type class java.lang.String
The Plugin configuration for my Mojo is as follows:
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<configuration>
<wait>true</wait>
<configuration>
<implementation>com.effacy.sample.EffacyTomcatConfiguration</implementation>
<dir>${project.build.directory}/tomcat5x/container</dir>
<type>standalone</type>
</configuration>
</configuration>
</plugin>
I am not sure what's wrong here?? I am reproducing the stacktrace below
and would appreciate any pointers.
Thanks in advance,
Rahul
<snip>
Cause: Cannot assign configuration entry 'implementation' to 'class
java.lang.Class' from 'com.effacy.sample.EffacyTomcatConfiguration',
which is of type class java.lang.String
[INFO]
----------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error
configuring: org.codehaus.cargo:cargo-maven2-plugin. Reason: Unable to
parse the created DOM for plugin configuration
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:485)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:455)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:303)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:270)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:139)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:249)
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:589)
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.PluginConfigurationException: Error
configuring: org.codehaus.cargo:cargo-maven2-plugin. Reason: Unable to
parse the created DOM for plugin configuration
at
org.apache.maven.plugin.DefaultPluginManager.populatePluginFields(DefaultPluginManager.java:1056)
at
org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:596)
at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:410)
at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:530)
... 16 more
Caused by:
org.codehaus.plexus.component.configurator.ComponentConfigurationException:
Cannot assign configuration entry 'implementation' to 'class
java.lang.Class' from 'com.effacy.sample.EffacyTomcatConfiguration',
which is of type class java.lang.String
at
org.codehaus.plexus.component.configurator.converters.AbstractConfigurationConverter.fromExpression(AbstractConfigurationConverter.java:149)
at
org.codehaus.plexus.component.configurator.converters.composite.ObjectWithFieldsConverter.fromConfiguration(ObjectWithFieldsConverter.java:80)
at
org.codehaus.plexus.component.configurator.converters.ComponentValueSetter.configure(ComponentValueSetter.java:207)
at
org.codehaus.plexus.component.configurator.converters.composite.ObjectWithFieldsConverter.processConfiguration(ObjectWithFieldsConverter.java:137)
at
org.codehaus.plexus.component.configurator.converters.composite.ObjectWithFieldsConverter.fromConfiguration(ObjectWithFieldsConverter.java:90)
at
org.codehaus.plexus.component.configurator.converters.ComponentValueSetter.configure(ComponentValueSetter.java:247)
at
org.codehaus.plexus.component.configurator.converters.composite.ObjectWithFieldsConverter.processConfiguration(ObjectWithFieldsConverter.java:137)
at
org.codehaus.plexus.component.configurator.BasicComponentConfigurator.configureComponent(BasicComponentConfigurator.java:56)
at
org.apache.maven.plugin.DefaultPluginManager.populatePluginFields(DefaultPluginManager.java:1050)
... 19 more
</snip>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]