cancel
Showing results for 
Search instead for 
Did you mean: 

how to ADD content type="application/xop+xml" to SOAP Message

Former Member
0 Kudos

Hi All

Can you please help us change the below value in our message to the partner in which we are sending the attachment - everything seems to be coming through fine on the message - except the part where the below type need to replaced from type="text/xml to type="application/xop+xml";



Content-Type: multipart/related; boundary=SAP_5474z111-1b85-155c6-99d7-09825351e94b6_END; type="text/xml"; start="<soap-721456787D5F1GLK5493F0ADEEE7749123E8@sap.com>"


NEED to REPLACE type="text/xml

with type="application/xop+xml";


CAN THIS BE ACHIEVED IN THE ADAPTER MODULE - OR WAT IS THE BEST POSSIBLE SOLUTION.


We thank you for your valuable timely inpts


Thank you,

Shravya

Accepted Solutions (1)

Accepted Solutions (1)

nitindeshpande
Active Contributor
0 Kudos

Hello Shravya,

Yes, this can be done using the MessageTransformBean. Please use this module parameter as below -

localejbs/AF_Modules/MessageTransformBean  Local Enterprise Bean  1

1         Transform.ContentType    application/xop+xml


SOAP adapter adds, text/xml by default, hence please check "Do Not use SOAP Envelope" in SOAP channel.


Regards,

Nitin

Former Member
0 Kudos

Hi Nithin

We have added below as per your suggestions:

  • localejbs/AF_Modules/MessageTransformBean
  • Transform.ContentType - application/xop+xml

Also, this has been ADDED only the receiver SOAP adapter.

However, we are getting the below error:

<?xml version="1.0" encoding="UTF-8" standalone="true"?>

<!-- Inbound Message -->

-<SAP:Error xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SAP="http://sap.com/xi/XI/Message/30" SOAP:mustUnderstand="1">

<SAP:Category>XIAdapterFramework</SAP:Category>

<SAP:Code area="MESSAGE">GENERAL</SAP:Code>

<SAP:P1/>

<SAP:P2/>

<SAP:P3/>

<SAP:P4/>


<SAP:AdditionalText>com.sap.engine.interfaces.messaging.api.exception.MessagingException: SOAP: Response message contains an errorXIAdapter/HTTP/ADAPTER.HTTP_EXCEPTION - HTTP 500 Internal Server Error</SAP:AdditionalText>

<SAP:Stack/>

<SAP:Retry>M</SAP:Retry>

</SAP:Error>

Can you please let us know wat could be the issue - for the above error.

Thanks again for your timely help! Nithin

Thank you,

Shravya

bhavesh_kantilal
Active Contributor
0 Kudos

Can you share a screen shot of your module configuration?

Also did the message reach the receiver SOAP Adapter, what do the logs on the Receiver SOAP Adapter show?

Regards

Bhavesh

nitindeshpande
Active Contributor
0 Kudos

Hi Shravya,

Have you checked the check box "Do not Use SOAP Envelope" in your SOAP receiver channel? From the response of web-service i understand, the request is not understood by your web-service. Are you sure, the web-service understands application/xop+xml? Because i feel this is not a standard content type.


Also please test with SOAPUI with application/xop+xml as content type, if we get a response, then the web-service accepts this content type. Please verify this first.


Regards,

Nitin

iaki_vila
Active Contributor
0 Kudos

Hi Sharvya,

If you work with for example MTOM you need more that only to change the content type, i mean in MTOM the attachment is a link reference in the payload for example (SOAP Message Transmission Optimization Mechanism (MTOM) - Enterprise Services Repository - SAP Libra...).

I used the receiver SOAP Axis adapter to work with MTOM.

Regards.

Answers (0)