I am trying to do SOAP over JMS on JBoss AS 5.1 with JBossWS-CXF-3.4.1.GA
Deployment of the receiving @WebService EJB3 bean JAR fails with the
message:
org.apache.cxf.configuration.ConfigurationException: Insufficient
configuration for Destination.
Did you configure a <jms:destination
name="{http://nato/HelloWorld/
}HelloWorldSOAP.jms-destination"> and
set the jndiConnectionFactoryName ?
The JMS queue is specified in my WSDL in the port binding address.
Can anybody give me a hint what I must add to my WSDL to make CXF happy?
Martin.
My WSDL looks like this:
<?xml version="1.0" encoding="UTF-8"
standalone="no"?>
<wsdl:definitions
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://example/HelloWorld/"
xmlns:soapjms="http://www.w3.org/2010/soapjms/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="
http://www.w3.org/2001/XMLSchema"
name="HelloWorld"
targetNamespace="http://example/HelloWorld/">
<wsdl:types>
<xsd:schema targetNamespace="http://example/HelloWorld/">
<xsd:element name="ExampleOperation">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="in" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
</wsdl:types>
<wsdl:message name="ExampleOperationRequest">
<wsdl:part element="tns:ExampleOperation"
name="parameters"/>
</wsdl:message>
<wsdl:portType name="HelloWorld">
<wsdl:operation name="ExampleOperation">
<wsdl:input message="tns:ExampleOperationRequest"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="HelloWorldSOAP" type="tns:HelloWorld">
<soap:binding style="document" transport="
http://www.w3.org/2010/soapjms/"/>
<wsdl:operation name="ExampleOperation">
<soap:operation soapAction="
http://example/HelloWorld/ExampleOperation"/>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="HelloWorld">
<soapjms:jndiConnectionFactoryName>java:/ConnectionFactory</soapjms:jndiConnectionFactoryName>
<wsdl:port binding="tns:HelloWorldSOAP"
name="HelloWorldSOAP">
<soap:address location="jms:queue:queue/ExampleIncoming"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
Here is the relevant part of the stack-trace.
Caused by: org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'XXXReceiver': Invocation of init method failed;
nested exception is javax.xml.ws.WebServiceException:
org.apache.cxf.configuration.ConfigurationException: Insufficient
configuration for Destination. Did you configure a <jms:destination
name="{http://nato/HelloWorld/}HelloWorldSOAP.jms-destination"> and set
the jndiConnectionFactoryName ?
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1412)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
at
org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:574)
at
org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
at
org.jboss.wsf.stack.cxf.configuration.SpringBusHolder.loadAdditionalConfig(SpringBusHolder.java:164)
at
org.jboss.wsf.stack.cxf.configuration.SpringBusHolder.configure(SpringBusHolder.java:128)
at
org.jboss.wsf.stack.cxf.deployment.aspect.BusDeploymentAspect.start(BusDeploymentAspect.java:96)
... 32 more
Caused by: javax.xml.ws.WebServiceException:
org.apache.cxf.configuration.ConfigurationException: Insufficient
configuration for Destination. Did you configure a <jms:destination
name="{http://nato/HelloWorld/}HelloWorldSOAP.jms-destination"> and set
the jndiConnectionFactoryName ?
at
org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:335)
at
org.jboss.wsf.stack.cxf.deployment.EndpointImpl.doPublish(EndpointImpl.java:62)
at
org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:238)
at
org.apache.cxf.jaxws.EndpointImpl.publish(EndpointImpl.java:481)
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.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1536)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1477)
at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1409)
... 44 more
Caused by: org.apache.cxf.configuration.ConfigurationException:
Insufficient configuration for Destination. Did you configure a
<jms:destination name="{http://nato/HelloWorld/
}HelloWorldSOAP.jms-destination"> and set the jndiConnectionFactoryName ?
at
org.apache.cxf.transport.jms.JMSConfiguration.ensureProperlyConfigured(JMSConfiguration.java:105)
at
org.apache.cxf.transport.jms.JMSDestination.activate(JMSDestination.java:110)
at
org.apache.cxf.transport.AbstractObservable.setMessageObserver(AbstractObservable.java:48)
at
org.apache.cxf.binding.AbstractBindingFactory.addListener(AbstractBindingFactory.java:181)
at
org.apache.cxf.binding.soap.SoapBindingFactory.addListener(SoapBindingFactory.java:836)
at org.apache.cxf.endpoint.ServerImpl.start(ServerImpl.java:127)
at
org.apache.cxf.jaxws.EndpointImpl.doPublish(EndpointImpl.java:326)
... 54 more
_____________________________________________________________________________________________________________________
ESG Elektroniksystem- und Logistik-GmbH
Rechtsform/Legal Form: Gesellschaft mit beschränkter Haftung
Sitz/Registered Office: München
Handelsregister/Commercial Register: Registergericht München, HRB 8130
Vorsitzender des Aufsichtsrats/Chairman of the Supervisory Board: Peter
Obermark
Vorsitzender der Geschäftsführung/CEO: Dipl.-Math. Gerhard Schempp,
Geschäftsführer/Managing Director: Dipl.-Kfm. Götz Graichen