Ah.

I think I know why this is happening. I believe that the commons-config module is not available to "external" plugins. This should be easy to fix. Sorry!

I've created the following JIRA to track the issue:
https://issues.jboss.org/browse/FORGE-413

~Lincoln

On Tue, Dec 20, 2011 at 5:41 AM, Pablo Palazon <pablo.palazon@gmail.com> wrote:
Hi everybody!!,

My name is Pablo Palazón, and I want to contribute with you in forge project. For me it's fantastic, and you're doing a excellent work. At the moment, I'm working on #FORGE-198 (https://issues.jboss.org/browse/FORGE-198).

I'm having problems with forge dist execution. When I run test unit, I haven't this problem about LinkageError. I'm programming in Linux workstation

I try to get User configuration with

@Inject Configuration config;
config.getScopedConfiguration(ConfigurationScope.USER); (in @PostConstruct method)

and this is the error:

***ERROR*** [mark add] WELD-000049 Unable to invoke [method] @PostConstruct public org.jboss.forge.shell.resources.cache.GlobalBookmarksCache.initialization() on org.jboss.forge.shell.resources.cache.GlobalBookmarksCache@2dffb
org.jboss.forge.shell.exceptions.CommandExecutionException: WELD-000049 Unable to invoke [method] @PostConstruct public org.jboss.forge.shell.resources.cache.GlobalBookmarksCache.initialization() on org.jboss.forge.shell.resources.cache.GlobalBookmarksCache@2dffb
    at org.jboss.forge.shell.command.Execution.perform(Execution.java:153)
    at org.jboss.forge.shell.command.fshparser.FSHRuntime.run(FSHRuntime.java:125)
    at org.jboss.forge.shell.command.fshparser.FSHRuntime.run(FSHRuntime.java:63)
    at org.jboss.forge.shell.ShellImpl$ExecutorThread.run(ShellImpl.java:811)
    at org.jboss.forge.shell.ShellImpl.execute(ShellImpl.java:834)
    at org.jboss.forge.shell.ShellImpl.doShell(ShellImpl.java:624)
    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.jboss.weld.bean.proxy.AbstractBeanInstance.invoke(AbstractBeanInstance.java:48)
    at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:125)
    at org.jboss.forge.shell.ShellImpl$Proxy$_$$_WeldClientProxy.doShell(ShellImpl$Proxy$_$$_WeldClientProxy.java)
    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.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:305)
    at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
    at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
    at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:299)
    at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:188)
    at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:59)
    at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:198)
    at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:282)
    at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:265)
    at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:234)
    at org.jboss.weld.manager.BeanManagerImpl.notifyObservers(BeanManagerImpl.java:635)
    at org.jboss.weld.manager.BeanManagerImpl.fireEvent(BeanManagerImpl.java:622)
    at org.jboss.weld.manager.BeanManagerImpl.fireEvent(BeanManagerImpl.java:616)
    at org.jboss.forge.shell.Bootstrap$1.run(Bootstrap.java:107)
    at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.reflect.InvocationTargetException
    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.jboss.forge.shell.command.Execution.perform(Execution.java:149)
    ... 31 more
Caused by: org.jboss.weld.exceptions.WeldException: WELD-000049 Unable to invoke [method] @PostConstruct public org.jboss.forge.shell.resources.cache.GlobalBookmarksCache.initialization() on org.jboss.forge.shell.resources.cache.GlobalBookmarksCache@2dffb
    at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:595)
    at org.jboss.weld.bean.ManagedBean$ManagedBeanInjectionTarget.postConstruct(ManagedBean.java:200)
    at org.jboss.weld.bean.ManagedBean.create(ManagedBean.java:340)
    at org.jboss.weld.context.AbstractContext.get(AbstractContext.java:122)
    at org.jboss.weld.bean.proxy.ContextBeanInstance.getInstance(ContextBeanInstance.java:99)
    at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:87)
    at org.jboss.forge.shell.resources.cache.GlobalBookmarksCache$Proxy$_$$_WeldClientProxy.addBookmark(GlobalBookmarksCache$Proxy$_$$_WeldClientProxy.java)
    at org.jboss.forge.shell.plugins.builtin.MarkPlugin.addMark(MarkPlugin.java:52)
    ... 36 more
Caused by: java.lang.reflect.InvocationTargetException
    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.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:305)
    at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
    at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
    at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:299)
    at org.jboss.weld.introspector.jlr.WeldMethodImpl.invoke(WeldMethodImpl.java:193)
    at org.jboss.weld.bean.AbstractClassBean.defaultPostConstruct(AbstractClassBean.java:591)
    ... 43 more
Caused by: java.lang.reflect.InvocationTargetException
    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.jboss.solder.unwraps.UnwrapsInvocationHandler.invoke(UnwrapsInvocationHandler.java:81)
    at org.javassist.tmp.java.lang.Object_$$_javassist_0.getScopedConfiguration(Object_$$_javassist_0.java)
    at org.jboss.forge.shell.resources.cache.GlobalBookmarksCache.initialization(GlobalBookmarksCache.java:25)
    ... 53 more
Caused by: java.lang.LinkageError: org/apache/commons/configuration/XMLConfiguration
    at org.jboss.forge.shell.env.ConfigurationImpl.getUserConfig(ConfigurationImpl.java:96)
    at org.jboss.forge.shell.env.ConfigurationImpl.getConfiguration(ConfigurationImpl.java:87)
    at org.jboss.forge.shell.env.ConfigurationImpl$Proxy$_$$_WeldClientProxy.getConfiguration(ConfigurationImpl$Proxy$_$$_WeldClientProxy.java)
    ... 60 more


_______________________________________________
forge-dev mailing list
forge-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/forge-dev




--
Lincoln Baxter, III
http://ocpsoft.com
http://scrumshark.com
"Keep it Simple"