[mule-user] failed to invoke lifecycle "start" using CXF in JBoss

22 views
Skip to first unread message

Jarle Langbråten

unread,
Sep 15, 2008, 9:18:35 AM9/15/08
to us...@mule.codehaus.org

Hi,

I have a problem running the CXF version of the Mule Echo example in JBoss
(see http://mule.mulesource.org/display/MULE2INTRO/Echo+Example)

Running it in Mule 2.0.2 works fine using JRE1.6.0_07, but when I try to run
the same example using Mule2.0.2 in JBoss4.2.3 I get the following result:

4:26:06,905 INFO [DefaultJavaComponent] Starting:
org.mule.component.DefaultJa
aComponent component for: EchoUMO
4:26:06,905 INFO [CxfConnector] Registering listener: EchoUMO on
endpointUri:
ttp://localhost:65082/services/EchoUMO
4:26:06,921 ERROR [MuleResourceAdapter]
org.mule.api.lifecycle.LifecycleExcepti
n: Failed to invoke lifecycle phase "start" on object: EchoUMO
4:26:06,921 WARN [ServiceController] Problem starting service
jboss.jca:servic
=RARDeployment,name='mule-ear-2.0.2.ear#mule-jca-jboss-2.0.2.rar'
avax.resource.spi.ResourceAdapterInternalException: Failed to start
management
ontext
at
org.mule.module.jca.MuleResourceAdapter.start(MuleResourceAdapter.jav
:125)
at
org.jboss.resource.deployment.RARDeployment.startService(RARDeploymen
.java:109)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanS
pport.java:289)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMB
anSupport.java:245)
at
org.jboss.system.ServiceDynamicMBeanSupport.invoke(ServiceDynamicMBea
Support.java:124)
at
org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:1
4)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
er.java:978)
...

I do also exprience the same problem trying other CXF based applications.
Any ideas on how to run Mule using CXF in JBoss?

Regards,
Jarle
--
View this message in context: http://www.nabble.com/failed-to-invoke-lifecycle-%22start%22-using-CXF-in-JBoss-tp19492803p19492803.html
Sent from the Mule - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


Andrew Perepelytsya

unread,
Sep 17, 2008, 8:39:41 PM9/17/08
to us...@mule.codehaus.org
Jarle,

Could you please post the full error. It got cut at the most important point.

Andrew

Jarle Langbråten

unread,
Sep 19, 2008, 3:35:52 AM9/19/08
to us...@mule.codehaus.org

Thanks Andrew,

Here's a full listing. I'm using the JDK6 version of Jboss 4.2.3-GA and it
uses jbossws-3.0.1-native-2.0.4.GA. I've also tried to install
jbossws-native-3.0.3.GA and jbossws-cxf-3.03.GA without any success.

Running on Mule is working fine:
INFO 2008-09-19 09:08:54,361 [WrapperListener_start_runner]
org.mule.component.
DefaultJavaComponent: Starting: org.mule.component.DefaultJavaComponent
componen
t for: EchoUMO
INFO 2008-09-19 09:08:54,376 [WrapperListener_start_runner]
org.mule.transport.
cxf.CxfConnector: Registering listener: EchoUMO on endpointUri:
http://localhost
:65082/services/EchoUMO
19.sep.2008 09:08:54
org.apache.cxf.service.factory.ReflectionServiceFactoryBean
buildServiceFromClass
INFO: Creating Service {http://echo.example.mule.org/}EchoService from class
org
.mule.example.echo.Echo
19.sep.2008 09:08:54 org.apache.cxf.endpoint.ServerImpl initDestination
INFO: Setting the server's publish address to be
http://localhost:65082/services
/EchoUMO
....

But running Mule on JBoss results in:
09:06:55,511 INFO [MuleResourceAdapter] Starting Mule...
09:06:55,511 INFO [CxfConnector] Starting: CxfConnector{this=1e12e2c,
started=f
alse, initialised=true, name='connector.cxf.0', disposed=false,
numberOfConcurre
ntTransactedReceivers=4, createMultipleTransactedReceivers=true,
connected=true,
supportedProtocols=[cxf, cxf:http, cxf:https, cxf:jms, cxf:vm,
cxf:servlet], se
rviceOverrides=null}
09:06:55,527 INFO [CxfConnector] Started: CxfConnector{this=1e12e2c,
started=tr
ue, initialised=true, name='connector.cxf.0', disposed=false,
numberOfConcurrent
TransactedReceivers=4, createMultipleTransactedReceivers=true,
connected=true, s
upportedProtocols=[cxf, cxf:http, cxf:https, cxf:jms, cxf:vm, cxf:servlet],
serv
iceOverrides=null}
09:06:55,527 INFO [CxfConnector] Connected: CxfConnector{this=1e12e2c,
started=
true, initialised=true, name='connector.cxf.0', disposed=false,
numberOfConcurre
ntTransactedReceivers=4, createMultipleTransactedReceivers=true,
connected=true,
supportedProtocols=[cxf, cxf:http, cxf:https, cxf:jms, cxf:vm,
cxf:servlet], se
rviceOverrides=null}
09:06:55,527 INFO [DefaultJavaComponent] Starting:
org.mule.component.DefaultJa
vaComponent component for: EchoUMO
09:06:55,527 INFO [CxfConnector] Registering listener: EchoUMO on
endpointUri:
http://localhost:65082/services/EchoUMO
09:06:55,621 ERROR [STDERR] 19.sep.2008 09:06:55
org.apache.cxf.service.factory.
ReflectionServiceFactoryBean buildServiceFromClass
INFO: Creating Service {http://echo.example.mule.org/}EchoService from class
org
.mule.example.echo.Echo
09:06:55,745 ERROR [MuleResourceAdapter]
org.mule.api.lifecycle.LifecycleExcepti
on: Failed to invoke lifecycle phase "start" on object: EchoUMO
09:06:55,761 WARN [ServiceController] Problem starting service
jboss.jca:servic
e=RARDeployment,name='mule-ear-2.0.2.ear#mule-jca-jboss-2.0.2.rar'
javax.resource.spi.ResourceAdapterInternalException: Failed to start
management
context
at
org.mule.module.jca.MuleResourceAdapter.start(MuleResourceAdapter.jav
a:125)
at
org.jboss.resource.deployment.RARDeployment.startService(RARDeploymen
t.java:109)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanS
upport.java:289)
at
org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMB
eanSupport.java:245)
at
org.jboss.system.ServiceDynamicMBeanSupport.invoke(ServiceDynamicMBea
nSupport.java:124)
at
org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:1
64)


at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at
org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl

ler.java:978)
at $Proxy0.start(Unknown Source)
at
org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy39.start(Unknown Source)
at
org.jboss.deployment.SimpleSubDeployerSupport.startService(SimpleSubD
eployerSupport.java:356)
at
org.jboss.deployment.SimpleSubDeployerSupport.start(SimpleSubDeployer
Support.java:127)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1015)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
at sun.reflect.GeneratedMethodAccessor21.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at
org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercept
or.java:133)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at
org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelM
BeanOperationInterceptor.java:142)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at
org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at
org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy9.deploy(Unknown Source)
at
org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymen
tScanner.java:421)
at
org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentS
canner.java:634)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
doScan(AbstractDeploymentScanner.java:263)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
loop(AbstractDeploymentScanner.java:274)
at
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
run(AbstractDeploymentScanner.java:225)
Caused by: org.mule.api.lifecycle.LifecycleException: Failed to invoke


lifecycle
phase "start" on object: EchoUMO

at
org.mule.lifecycle.DefaultLifecyclePhase.applyLifecycle(DefaultLifecy
clePhase.java:267)
at
org.mule.lifecycle.DefaultLifecyclePhase.fireLifecycle(DefaultLifecyc
lePhase.java:119)
at
org.mule.lifecycle.GenericLifecycleManager.firePhase(GenericLifecycle
Manager.java:79)
at org.mule.DefaultMuleContext.start(DefaultMuleContext.java:140)
at
org.mule.module.jca.MuleResourceAdapter.start(MuleResourceAdapter.jav
a:120)
... 43 more
Caused by: java.lang.LinkageError: loader constraint violation: when
resolving f
ield "DATETIME" the class loader (instance of
org/jboss/mx/loading/UnifiedClassL
oader3) of the referring class, javax/xml/datatype/DatatypeConstants, and
the cl
ass loader (instance of <bootloader>) for the field's resolved type,
javax/xml/n
amespace/QName, have different Class objects for that type
at
com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl.<clinit>(Ru
ntimeBuiltinLeafInfoImpl.java:186)
at
com.sun.xml.bind.v2.model.impl.RuntimeTypeInfoSetImpl.<init>(RuntimeT
ypeInfoSetImpl.java:25)
at
com.sun.xml.bind.v2.model.impl.RuntimeModelBuilder.createTypeInfoSet(
RuntimeModelBuilder.java:84)
at
com.sun.xml.bind.v2.model.impl.RuntimeModelBuilder.createTypeInfoSet(
RuntimeModelBuilder.java:41)
at
com.sun.xml.bind.v2.model.impl.ModelBuilder.<init>(ModelBuilder.java:
104)
at
com.sun.xml.bind.v2.model.impl.RuntimeModelBuilder.<init>(RuntimeMode
lBuilder.java:49)
at
com.sun.xml.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(JAXBContex
tImpl.java:372)
at
com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.ja
va:236)
at
com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:
76)
at
com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:
55)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:210)
at javax.xml.bind.ContextFinder.find(ContextFinder.java:368)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:574)
at
org.apache.cxf.jaxb.JAXBDataBinding.createJAXBContext(JAXBDataBinding
.java:510)
at
org.apache.cxf.jaxb.JAXBDataBinding.initialize(JAXBDataBinding.java:2
68)
at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServ
iceFromClass(ReflectionServiceFactoryBean.java:319)
at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializ
eServiceModel(ReflectionServiceFactoryBean.java:370)
at
org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(Re
flectionServiceFactoryBean.java:162)
at
org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean.create(JaxWsServ
iceFactoryBean.java:97)
at
org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoi
nt(AbstractWSDLBasedEndpointFactory.java:74)
at
org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.ja
va:114)
at
org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactory
Bean.java:160)
at
org.mule.transport.cxf.CxfMessageReceiver.doInitialise(CxfMessageRece
iver.java:257)
at
org.mule.transport.AbstractMessageReceiver.initialise(AbstractMessage
Receiver.java:159)
at
org.mule.transport.AbstractConnector.registerListener(AbstractConnect
or.java:1021)
at
org.mule.service.AbstractService.registerListeners(AbstractService.ja
va:608)
at org.mule.service.AbstractService.start(AbstractService.java:316)
at org.mule.service.AbstractService.start(AbstractService.java:293)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.mule.lifecycle.DefaultLifecyclePhase.applyLifecycle(DefaultLifecy
clePhase.java:263)
... 47 more
09:06:55,808 INFO [EARDeployer] Started J2EE application:
file:/C:/jBoss/jboss-
4.2.3.GA/server/default/deploy/mule-ear-2.0.2.ear


Jarle

--
View this message in context: http://www.nabble.com/failed-to-invoke-lifecycle-%22start%22-using-CXF-in-JBoss-tp19492803p19567561.html

Jarle Langbråten

unread,
Sep 30, 2008, 5:55:10 AM9/30/08
to us...@mule.codehaus.org

Hi,
I solved the problem at last.
The mule-jca-jboss-2.0.2 contains two files which causes linkage errors with
the rt.jar (in both Java 1.5 and Java 6). I had to remove
javax/xml/namespace/QName.class from both stax-api-1.0.1.jar and
axis-jaxrpc-1.4.jar to be able to load CXF-webservices into Mule running in
JBoss. I also had to remove /javax/xml/namespace/NamespaceContext.class from
axis-jaxrpc-1.4.jar to avoid linkage error when accessing the wsdl.

Jarle

--
View this message in context: http://www.nabble.com/failed-to-invoke-lifecycle-%22start%22-using-CXF-in-JBoss-tp19492803p19739183.html

Reply all
Reply to author
Forward
0 new messages