Hi I am trying to forward a message (XML-file from SFTP) to a JMS destination. But this results in a NullPointerException at DefaultJmsMarshaler.java:92. I know the SFTP pickup works because with a file-endpoint everything is fine. The Exception occurs on the following line in the method DefaultJmsMarshaler.toJMS(SoapMessage message, Session session)
TextMessage msg = session.createTextMessage(); I guess that there is no JSM-session passed to this method. However I turned all Log to DEBUG level and could not find out why there is no JMS-session. Below you find more information. Any help is very welcome. Thank you! This is the configuration I use: <?xml version="1.0"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:proj="http://servicemix.org/demo/" xmlns:file="http://servicemix.apache.org/file/1.0" xmlns:jms="http://servicemix.apache.org/jms/1.0" xmlns:vfs="http://servicemix.apache.org/vfs/1.0" 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 http://servicemix.apache.org/file/1.0 http://servicemix.apache.org/schema/servicemix-file-3.1.2.xsd http://servicemix.apache.org/jms/1.0 http://servicemix.apache.org/schema/servicemix-jms-2009.01.xsd http://servicemix.apache.org/vfs/1.0 http://servicemix.apache.org/schema/servicemix-vfs-2009.01.xsd"> <jms:endpoint service="proj:fileSender" endpoint="endpoint" role="provider" destinationStyle="queue" jmsProviderDestinationName="com.inbox.newfiles" jndiConnectionFactoryName="ConnectionFactory" /> <vfs:poller service="proj:filePoller" endpoint="poller" path="sftp://user:[email protected]/HOME/OUT" targetService="proj:fileSender" period="10000" deleteFile="true" recursive="false"> </vfs:poller> <bean class="org.apache.servicemix.common.osgi.EndpointExporter" /> <manifest> Bundle-Version = 1.0.0 Bundle-Name = AAA-Test :: SFTP-JSM Test Bundle-SymbolicName = com.test.channel Bundle-Description = File transfer test Bundle-Vendor = [email protected] Require-Bundle = servicemix-file, servicemix-vfs </manifest> </beans> This is the full Exception. 22:07:51,452 | DEBUG | ix-jms-thread-88 | NMR | .servicemix.nmr.core.ChannelImpl 198 | Channel org.apache.servicemix.nmr.core.channeli...@182535af delivering exchange: [ id: 928ad0ca-a8a4-4613-99a1-05fc03184e58 mep: InOnly status: Error role: Provider target: PropertyMatchingReference[{SERVICE_NAME={http://servicemix.org/demo/}fileSender}] properties: [ javax.jbi.servicedesc.ServiceEndpoint = org.apache.servicemix.jbi.runtime.impl.endpointi...@4c9c7934 org.apache.servicemix.senderEndpoint = {http://servicemix.org/demo/}filePoller:poller javax.jbi.messaging.MessageExchange = org.apache.servicemix.jbi.runtime.impl.inonlyi...@28db0fd7 javax.jbi.messaging.sendSync = <null> javax.jbi.InterfaceName = <null> javax.jbi.ServiceEndpoint = org.apache.servicemix.jbi.runtime.impl.serviceendpointi...@746eba19 javax.jbi.transaction.jta = <null> org.apache.servicemix.correlationId = 928ad0ca-a8a4-4613-99a1-05fc03184e58 javax.jbi.ServiceName = {http://servicemix.org/demo/}fileSender ] In: [ content: javax.xml.transform.stream.streamsou...@45ed0135 properties: [ org.apache.servicemix.file.path = sftp://user:[email protected]/HOME/OUT/hello.xml org.apache.servicemix.file.name = hello.xml org.apache.servicemix.vfs = sftp://user:[email protected]/HOME/OUT/hello.xml ] ] error: [ java.lang.NullPointerException at org.apache.servicemix.jms.DefaultJmsMarshaler.toJMS(DefaultJmsMarshaler.java:92) at org.apache.servicemix.jms.DefaultJmsMarshaler.toJMS(DefaultJmsMarshaler.java:116) at org.apache.servicemix.jms.AbstractJmsProcessor.fromNMS(AbstractJmsProcessor.java:216) at org.apache.servicemix.jms.AbstractJmsProcessor.createMessageFromExchange(AbstractJmsProcessor.java:263) at org.apache.servicemix.jms.multiplexing.MultiplexingProviderProcessor.process(MultiplexingProviderProcessor.java:129) at org.apache.servicemix.soap.SoapEndpoint.process(SoapEndpoint.java:400) at org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:627) at org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:581) at org.apache.servicemix.common.AsyncBaseLifeCycle.processExchangeInTx(AsyncBaseLifeCycle.java:478) at org.apache.servicemix.common.AsyncBaseLifeCycle$2.run(AsyncBaseLifeCycle.java:347) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) ] ] -- View this message in context: http://old.nabble.com/Problem-forwarding-message-from-vsf-%28SFTP%29-to-JMS-%28ServiceMix-4.2%2C-servicemix-jms-2010.01%29-tp28772675p28772675.html Sent from the ServiceMix - User mailing list archive at Nabble.com.
