cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aleksandar Valchev <aleksandar.valc...@gmail.com>
Subject Error parsing message sent by TIBCO BusinessWorks
Date Wed, 27 Oct 2010 10:24:33 GMT
Hi,

I'm tying SOAP over JMS beetween CXF and TIBCO BusinessWorks, where CXF is
service provider. The message that is sent by TIBCO to the SOAP queue is
(thanks to LogginInInterceptor):

ID: 1
Encoding: UTF-8
Content-Type: application/xop+xml
Headers: {malformed.requesturi=[true], JMSMessageType=[byte],
SOAPJMS_contentType=[application/xop+xml], Mime_Version=[1.0],
SoapAction=["/MTOM/TestDataHandler"], SOAPJMS_requestURI=[queue:test.q],
Content_Type=[multipart/related; type="application/xop+xml";
startinfo="application/soap+xml"; start-info="application/soap+xml";
boundary=_NextPart_000_0002_01C3E1CC.3BB37320; start="<TIBCO_START_PART>";
charset="utf-8"]}
Payload:
--_NextPart_000_0002_01C3E1CC.3BB37320
Content-transfer-encoding: binary
Content-type: application/xop+xml; type="application/soap+xml";
charset=utf-8
Content-id: <TIBCO_START_PART>

<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:SOAP-ENV="
http://www.w3.org/2003/05/soap-envelope"><SOAP-ENV:Body><ns0:TestDataHandlerRequest
xmlns:ns0="http://lombard.lu/CDM"><ns0:name>soap.txt</ns0:name><ns0:attachinfo><ns1:Include
xmlns:ns1="http://www.w3.org/2004/08/xop/include" href="
cid:1288173309729@example.org <cid%3A1288173309729@example.org>
"/></ns0:attachinfo></ns0:TestDataHandlerRequest></SOAP-ENV:Body></SOAP-ENV:Envelope>
--_NextPart_000_0002_01C3E1CC.3BB37320
Content-transfer-encoding: binary
Content-type: application/octet-stream
Content-id: <1288173309729@example.org>

testasd adasjkd?lkjad?lajksd?lkasd
asd?adjf werwpqeriuweior 1223123 nas?ldkjnas
--_NextPart_000_0002_01C3E1CC.3BB37320--

The exception that I face is the following:

Oct 27, 2010 12:21:43 PM org.apache.cxf.phase.PhaseInterceptorChain
doDefaultLogging
WARNING: Interceptor for {http://lombard.lu/mtom}MTOMService has thrown
exception, unwinding now
org.apache.cxf.binding.soap.SoapFault: Error reading XMLStreamReader.
    at
org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage(ReadHeadersInterceptor.java:222)
    at
org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage(ReadHeadersInterceptor.java:60)
    at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:247)
    at
org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:113)
    at
org.apache.cxf.transport.jms.JMSDestination.onMessage(JMSDestination.java:220)
    at
org.springframework.jms.listener.AbstractMessageListenerContainer.doInvokeListener(AbstractMessageListenerContainer.java:535)
    at
org.springframework.jms.listener.AbstractMessageListenerContainer.invokeListener(AbstractMessageListenerContainer.java:495)
    at
org.springframework.jms.listener.AbstractMessageListenerContainer.doExecuteListener(AbstractMessageListenerContainer.java:467)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.doReceiveAndExecute(AbstractPollingMessageListenerContainer.java:323)
    at
org.springframework.jms.listener.AbstractPollingMessageListenerContainer.receiveAndExecute(AbstractPollingMessageListenerContainer.java:261)
    at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.invokeListener(DefaultMessageListenerContainer.java:1056)
    at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.executeOngoingLoop(DefaultMessageListenerContainer.java:1048)
    at
org.springframework.jms.listener.DefaultMessageListenerContainer$AsyncMessageListenerInvoker.run(DefaultMessageListenerContainer.java:947)
    at java.lang.Thread.run(Thread.java:729)
Caused by: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected
character '-' (code 45) in prolog; expected '<'
 at [row,col {unknown-source}]: [2,1]
    at
com.ctc.wstx.sr.StreamScanner.throwUnexpectedChar(StreamScanner.java:644)
    at
com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2003)
    at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1100)
    at
com.ctc.wstx.sr.BasicStreamReader.nextTag(BasicStreamReader.java:1123)
    at
org.apache.cxf.binding.soap.interceptor.ReadHeadersInterceptor.handleMessage(ReadHeadersInterceptor.java:122)
    ... 13 more
Oct 27, 2010 12:21:43 PM
org.apache.cxf.binding.soap.interceptor.Soap12FaultOutInterceptor$Soap12FaultOutInterceptorInternal
handleMessage
INFO: class
org.apache.cxf.binding.soap.interceptor.Soap12FaultOutInterceptor$Soap12FaultOutInterceptorInternalapplication/soap+xml


After a quick look in the code of ReadHeadersInterceptor, I found that the
error is thrown by XMLStreamReader:

xmlReader.nextTag() == XMLStreamConstants.START_ELEMENT

Do you have any idea how ti fix this. I just want to mention that when I'm
using SOAP over HTTP (instead of JMS) the example works perfectly. The error
occurs if I change the transport to JMS.

Thanks.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message