I think the problem might be this:
<bean id="jmsTransport"
class="org.codehaus.xfire.transport.jms.JMSTransport"
xmlns="*http://xbean.org/schemas/spring/1.0*<http://xbean.org/schemas/spring/1.0>
">
<constructor-arg ref="xfire"/>
<constructor-arg ref="jmsConnectionFactory"/>
</bean>
Try doing that with xmlns="" instead of the xbean namespace. Or it might
need to be the spring namespace. Not sure offhand :-)
- Dan
On 12/8/06, Chris Mathrusse <[EMAIL PROTECTED]> wrote:
My environment:
Spring 2.0
XFire 1.2.3
I've got my service successfully working using HTTP transport. I want to
add
JMS Transport to the service as well. I've followed the instructions based
upon
the published document: http://xfire.codehaus.org/JMS+Transport
When I attempt to access my service via http I get a NullPointerException
being
thrown. I've chased it down to ObjectServiceFactory.createEndpoint method,
line
570.
getTransportManager().getTransport(binding.getBindingId
()).createChannel
(url);
The call to getTransport is returning null and as a result the NullPointer
is
raised when createChannel() is invoked.
binding.getBindingId() = urn:xfire:transport:jms
As you can see the binding is correct for the JMS transport. I've
registered my
transport per the documentation but it does not appear to be registered.
Looking at the TransportManager I find the folowing transports registerd:
http://www.w3.org/2003/05/soap/bindings/HTTP/
http://www.w3.org/2004/08/wsdl/http
urn:xfire:transport:local
Because the JMS transport, urn:xfire:transport:jms, is not listed in the
variable binding2Transport the transport is not found and a null is
returned,
causing the NullPointerException.
I've registed the JMS transport as outlined in the document so why isn't
is
getting registerd?
Below is my services.xml file.
Thanks for hte help...
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="OrderServiceTarget"
class="com.sybase.it.cosmos.web.services.OrderServiceImpl"
autowire="byName"/>
<xfire>
<transports>
<bean id="jmsTransport"
class="org.codehaus.xfire.transport.jms.JMSTransport"
xmlns="http://xbean.org/schemas/spring/1.0">
<constructor-arg ref="xfire"/>
<constructor-arg ref="jmsConnectionFactory"/>
</bean>
</transports>
</xfire>
<service xmlns="http://xfire.codehaus.org/config/1.0">
<name>OrderService</name>
<namespace>http://it.sybase.com/rosettanet/pip3A4/purchaseorder
</namespace>
<serviceClass>com.sybase.it.cosmos.web.services.OrderService
</serviceClass>
<serviceBean>#OrderServiceTarget</serviceBean>
<style>document</style>
<serviceFactory>org.codehaus.xfire.xmlbeans.XmlBeansServiceFactory
</serviceFacto
ry>
<properties>
<property key="wsdlBuilder.removeAllImports">true</property>
</properties>
<createDefaultBindings>false</createDefaultBindings>
<bindings xmlns:e="
http://it.sybase.com/rosettanet/pip3A4/purchaseorder">
<soap11Binding name="e:OrderServiceHttpBinding"
transport="http://schemas.xmlsoap.org/soap/http"
allowUndefinedEndpoints="true"/>
<soap11Binding name="e:OrderServiceJMSBinding"
transport="urn:xfire:transport:jms">
<endpoints>
<endpoint name="OrderServiceJMSEndpoint"
url="jms://orderRequestQueue" />
</endpoints>
</soap11Binding>
</bindings>
</service>
</beans>
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email
--
Dan Diephouse
Envoi Solutions
http://envoisolutions.com | http://netzooid.com/blog