WSDL HTTP binding should define "application/xml" as the MIME content type for 
it's messages.  
-----------------------------------------------------------------------------------------------

                 Key: AXIS2-5253
                 URL: https://issues.apache.org/jira/browse/AXIS2-5253
             Project: Axis2
          Issue Type: Bug
          Components: kernel
    Affects Versions: 1.6.1
            Reporter: Sagara Gunathunga 
            Assignee: Sagara Gunathunga 
             Fix For: 1.7.0


Axis2 runtime WSDL generation define "text/xml" as the MIME content type for 
messages.  The default behavior of a client generated from above WSDL ( with 
-ap option) is send SOAP messages instead of pure XML messages and following 
exception when receiving the response message.

org.apache.axis2.AxisFault: org.apache.axis2.databinding.ADBException: 
Unexpected subelement {http://schemas.xmlsoap.org/soap/envelope/}Body
at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430)


Adding following line is a workaround for this issue but it's required to fix 
this properly.  

  Options options = stub._getServiceClient().getOptions();
  options.setProperty(Constants.Configuration.MESSAGE_TYPE, "application/xml");


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to