cancel
Showing results for 
Search instead for 
Did you mean: 

invalid content type for SOAP: TEXT/HTML

Former Member
0 Kudos

Hi guys,

I’m trying to sending a message via sender soap adapter and I’m receiving this error:

Exception caught by adapter framework: invalid content type for SOAP: TEXT/HTML

I already have read most off all posts about this error in this forum. So, if I understand, this error means that my receiver soap adapter can’t reach the web service provider and an HTTP error notification is sent to calling application. Although, the SOAP adapter doesn’t understand this kind of errors (ex. 404 not found -> SOAP call has no error codes and use the HTTP codes for effect) and this happening because the error is in text/html format and SOAP adapter is waiting a response in text/xml.

This is a simple calculator web service that receives two arguments and returns the sum as a result. (Like Siva Maranani weblog /people/siva.maranani/blog/2005/09/03/invoke-webservices-using-sapxi )

The web service is published on SAP Enterprise Portal and it works fine.

- The login works fine

User: ex30268

Pwd: 12345678

- We don’t have certificates and proxy server.

This is the address in my receiver soap adapter: http://intranetcorpdev.edp.pt:54700/CalculatorWebService/Config1?style=document

I already checked the settings of my receiver soap adapter and did a little test, enabling the parameter Do Not Use SOAP Envelop only in receiver adapter. And the result is an exception during mapping!!! What is means this error?

Does anybody know how to solve this issue?

Thanks in advance.

Cheers,

Ricardo.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi all,

Please forgive me for boring you again with this subject, but I haven’t yet solved this issue, I still receive the following message and I’m getting quite worried…

>>> Invalid content type for SOAP: TEXT/HTML

I’m following Siva Maranani web log (Invoke Webservices using SAPXI) and I will describe the steps that I did:

<b>Integration Repository:</b>

• An Inbound synchronous Message Interface (CalculatorWS_IN_MI) using the message types in external definition (WSDL from web service hat I want to invoke).

• The other necessary data types (Calc_input_DT has 2 parameters>arg1 and arg2. and Calc_out_DT has 1 param> result) and corresponding Message types.

• An Outbound synchronous Message Interface (Calc_OUT_MI) using the message types defined in Integration Directory.

• 2 Message mappings (request and response) and 1 Interface mapping.

<b>Integration Directory:</b>

• A scenario calls WebServices.

• 2 business services (webservice and webservice_calc).

• A Receiver determination with webservice as a sender service (note: this sender is simulated from the WSNavigator from an Enterprise Portal that I have installed locally in my laptop) the interface is (Calc_OUT_MI).

• An Interface determination with webservice_calc as a receiver service and the corresponding mapping interface and SOAP receiver channel.

Configurations of SOAP receiver channel:

Target URL: http://intranetcorpdev.edp.pt:54700/CalculatorWebService/Config1?style=document

User: ex30268

Pwd: 12345678

I have picked only the parameters “Use Encoded Headers” and “Use Query String” activated. I’m not using any kind of certificates or proxy servers.

A call tentative:

Request

POST /XISOAPAdapter/MessageServlet?channel=:WebService:SOAPSenderChannel&version=3.0&Sender.Service=WebService&Interface=http%3A%2F%2Fswitching%2Fxi%5ECalc_OUT_MI HTTP/1.1

Host: ed19dci1f.appl.edinfor.pt:54900

Content-Type: text/xml; charset="UTF-8"

Connection: close

Cookie: <value is hidden>

Cookie: <value is hidden>

Authorization: <value is hidden>

SOAPAction: "http://sap.com/xi/WebService/soap1.1"

Content-Length: 407

Response

HTTP/1.1 500 Internal Server Error

Connection: close

Server: SAP J2EE Engine/6.40

Content-Type: text/xml; charset=utf-8

Date: Fri, 12 May 2006 08:24:18 GMT

<?xml version='1.0'?>

<!-- see the documentation -->

<SOAP:Envelope xmlns:SOAP='http://schemas.xmlsoap.org/soap/envelope/'>

<SOAP:Body>

<SOAP:Fault>

<faultcode>SOAP:Server</faultcode>

<faultstring>Server Error</faultstring>

<detail>

<s:SystemError xmlns:s='http://sap.com/xi/WebService/xi2.0'>

<context>XIAdapter</context>

<code>DeliveryException</code>

<text><![CDATA[

com.sap.aii.af.ra.ms.api.DeliveryException: XIAdapterFramework:GENERAL:com.sap.aii.af.ra.ms.api.DeliveryException: invalid content type for SOAP: TEXT/HTML

at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:451)

at com.sap.aii.af.ra.ms.impl.core.queue.CallConsumer.onMessage(CallConsumer.java:125)

at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:831)

at com.sap.engine.frame.core.thread.Task.run(Task.java(Compiled Code))

at com.sap.engine.core.thread.impl5.SingleThread.execute(SingleThread.java(Compiled Code))

at com.sap.engine.core.thread.impl5.SingleThread.run(SingleThread.java(Compiled Code))

]]></text>

</s:SystemError>

</detail>

</SOAP:Fault>

</SOAP:Body>

</SOAP:Envelope>

I think that I have tried everything and read almost of posts, web logs, SDN community contribution and the info in help.sap.com, but I’m feeling unable to solve this kind of issue. I’m afraid that I was missed something. So that’s the reason to describe here all the steps that I have done.

I hope somebody knows how to solve this issue or give me something that can help me find the end of this road…

Thanks for all.

Cheers,

Ricardo.

Former Member
0 Kudos

Hi Ricardo,

I have the same problem for 2 weeks.

I don´t konw what to do ?

I hope this forum can help me too.

sincerely,

Silvio

Former Member
0 Kudos

Hi guys,

The issue is solved!!!

The address in soap address location from main.wsdl was wrong! I tried opening this address in a web browser and the page that I see is info with the webservice published and a link to the webservice wsdl. Using this wsdl link in my receiver soap adapter works!!!

So, the web service address that we must type in target URL of receiver soap adapter is the address to the WSDL. To be sure types this address in a browser and you must see a WSDL code of the webservice that you want invoke.

Tanks a lot for all 🐵

Cheers,

Ricardo.

moorthy
Active Contributor
0 Kudos

Hi Ricardo,

it is very nice to hear that it is worked.

Did u see the pdf document , mentioned in my earlier post for the same solution. Target Url should be wsdl URL. and it is shown in the Blue color.

Thanks for the update.

Regards,

Moorthy

Former Member
0 Kudos

Hi Moorthy,

Yes!!! The PDF document that you mentioned in your earlier post, it was the answer of my problem… sorry for forgetting to mention your help

Thanks again Moorthy, your tips and guidelines have been a great aid for me… and I didn’t forget your reward points ;o)

At the moment I’m dealing with another problem on this same scenario, but I will post it in a new thread and close this one.

Cheers,

Ricardo.

Former Member
0 Kudos

Can anybody provide me some clues on these doubts?

This is the right address that I need to put on my receiver soap adapter? (You can test in your browser if you want) This address was copied from soap address location from a main.wsdl file downloaded from WSNavigator do WAS 6.40 after Netweaver develop studio deployed to there.

http://intranetcorpdev.edp.pt:54700/CalculatorWebService/Config1?style=document

User: ex30268

Pwd: 12345678

What parameters I should activate?

Not use SOAP Envelope

Keep attachments

Keep Headers

Encoded Headers

Use query string

In soap action I need to put the name of the method that I want to invoke?

Thanks all

Cheers,

Ricardo.

Message was edited by: Ricardo Quintino

moorthy
Active Contributor
moorthy
Active Contributor
0 Kudos

Hi Ricardo,

Check this thread-

SAP Note No: 856597

Hope this helps

Regards,

Moorthy

Former Member
0 Kudos

Hi Moorthy,

Thanks for your quick reply, but I already have read this post and doesn't help me...

What is SAP Note No: 856597, is it about SOAP?

Cheers,

Ricardo.

moorthy
Active Contributor
0 Kudos

<i>What is SAP Note No: 856597, is it about SOAP</i>

Yes, SOAP FAQ

Thanks,

Moorthy

Former Member
0 Kudos

I already read this SOAP FAQ too...

I don’t know what's happening! I believe it that isn't a login problem. If you use the address that I post you will see that it is working!!! Just try and confirm it to me please.

I'm getting quite desperate :s

Cheers,

Ricardo.