Axis2 fails to parse "Multipart/Related"-Messages from SAAJ-Webservice ----------------------------------------------------------------------
Key: AXIS2-3373 URL: https://issues.apache.org/jira/browse/AXIS2-3373 Project: Axis 2.0 (Axis2) Issue Type: Bug Components: kernel Affects Versions: 1.3, 1.4 Environment: Axis2 1.3 Client Spring-WS (SAAJ 1.3) Webservice Reporter: Herbert Gerngroß Axis2 fails to parse a "Multipart/Related"-MTOM-Message sent from Spring-WS-Webservice (SAAJ 1.3). The AxisConfigBuilder-Class in package org.apache.axis2.deployment registers a MIMEBuilder-Instance for contentType "multipart/related". When the client parses an incoming message it uses org.apache.axis2.builder.BuilderUtil.getBuilderFromSelector(String type, MessageContext msgContext) to find a adequate builder for the message. Because this lookup is case-sensitive no MIMEBuilder is found. The result is the following error stacktrace: org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '-' (code 45) in prolog; expected '<' at [row,col {unknown-source}]: [1,1] at org.apache.axis2.AxisFault.makeFault(AxisFault.java:417) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:89) at org.apache.axis2.description.OutInAxisOperationClient.handleResponse(OutInAxisOperation.java:326) at org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:389) at org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211) at org.apache.axis2.client.OperationClient.execute(OperationClient.java:163) at at.gv.brz.springplz.webservice.plz.PLZSucheServiceStub.GetAllPLZObjectsAsPdf(PLZSucheServiceStub.java:1509) at at.gv.brz.springplz.webservice.client.PLZSucheTestCase.test6PLZSucheGetAllPLZObjectsAsPdf(PLZSucheTestCase.java:237) 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:324) at junit.framework.TestCase.runTest(TestCase.java:154) at junit.framework.TestCase.runBare(TestCase.java:127) at junit.framework.TestResult$1.protect(TestResult.java:106) at junit.framework.TestResult.runProtected(TestResult.java:124) at junit.framework.TestResult.run(TestResult.java:109) at junit.framework.TestCase.run(TestCase.java:118) at junit.framework.TestSuite.runTest(TestSuite.java:208) at junit.framework.TestSuite.run(TestSuite.java:203) at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:128) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196) Caused by: org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '-' (code 45) in prolog; expected '<' at [row,col {unknown-source}]: [1,1] at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:239) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.getSOAPEnvelope(StAXSOAPModelBuilder.java:161) at org.apache.axiom.soap.impl.builder.StAXSOAPModelBuilder.<init>(StAXSOAPModelBuilder.java:110) at org.apache.axis2.builder.BuilderUtil.getSOAPBuilder(BuilderUtil.java:610) at org.apache.axis2.transport.TransportUtils.createDocumentElement(TransportUtils.java:178) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:111) at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:87) ... 24 more Caused by: com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '-' (code 45) in prolog; expected '<' at [row,col {unknown-source}]: [1,1] at com.ctc.wstx.sr.StreamScanner.throwUnexpectedChar(StreamScanner.java:623) at com.ctc.wstx.sr.BasicStreamReader.nextFromProlog(BasicStreamReader.java:2047) at com.ctc.wstx.sr.BasicStreamReader.next(BasicStreamReader.java:1069) at org.apache.axiom.om.impl.builder.StAXOMBuilder.next(StAXOMBuilder.java:153) ... 30 more -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]