on 08-25-2006 11:40 AM
All,
I used the do not send SOAP envelope option in the SOAP receiver adapter.
Instead of XSLT, I used JAVA mapping to create the entire SOAP message ( Am more comfortable with Java and this is just a trial) , and this is the output of my java mapping with the SOAP envelope created,
<i><?xml version="1.0" encoding="UTF-8"?><soap:Envelope xmlns:soap="http://www.w3.org/2001/12/soap-envelope"soap:encodingStyle="http://www.w3.org/2001/12/soap-encoding"><soap:Header></soap:Header><soap:Body><ns1:GetQuote xmlns:ns1="http://www.webserviceX.NET/"><ns1:symbol>SAP</ns1:symbol></ns1:GetQuote></soap:Body></soap:Envelope></i>
Am using the STOCK Quote for testing purposes and this is the error I am getting when testing my interface,
<i><faultstring>System.Web.Services.Protocols.SoapException: Server found request content type to be '', but expected 'text/xml'. at System.Web.Services.Protocols.SoapServerProtocol.ReadParameters() at System.Web.Services.Protocols.WebServiceHandler.Invoke() at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()</faultstring></i>
Any directions / inputs on how to resolve this issue?
Regards,
Bhavesh
Hi,
Try appending you target url with &nosoap=true in the receiver soap adapter.
This is required when the do not use soap envelope checkbox is selected.
Regards,
Smitha.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Bhavesh,
I'm very pleased to see that your scenario worked! These module parameters always save the day.
I'm sorry for not have responding your message earlier. I had been absent from the forum for a couple of days and missed your message.
But if you still need the information, Soap URL is the actual Http url and Soap Action is passed as a Http header field. Check the Soap specification for more information on this matter:
Soap over HTTP: http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383526
Specifically, for Soap Action, check this:
http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383528
Regards,
Henrique.
Henrique,
My SOAP Url : http://www.webservicex.net/stockquote.asmx
My SOAP action : http://www.webserviceX.NET/GetQuote
I have created the HTTP connection to an external Server with the SOAP url as the path prefix , and tested the connection and it works fine.
My question~~
How should I use the Header Field to point to the SOAP action in the HTTP receiver adapter.
What would be the Name and the value of this field?
I tried using <b>op=GetQuote</b> and the header and value , but no luck . I am getting an error back which states no Action attribute specified.
Its been a big learning curve so far, and this would be the grand finale if you can help me crack this
Thanks a ton,
Regards,
Bhavesh
Henrique,
I actually tried that too.
I used SOAPAction = http://www.webserviceX.NET/GetQuote
and also tried with SOAPAction = GetQuote . But, no luck .
Any other ideas?
Thanks,
Bhavesh
Henrique,
Tried various permutations~~ The only new error / progress seems to be for this,
---
SOAPAction "http://www.webserviceX.NET/GetQuote"
---
This is giving me an error ,
<i>HTTP server code 400 reason Bad Request explanation <h1>Bad Request (Invalid Header Name)</h1></i>
Also, tried by adding the Colon after SOAPAction,
SOAPAction: "http://www.webserviceX.NET/GetQuote"
Same error
Final thing i guess is to make SOAPAction all small as soapaction and check if it works. Will let you know.
Regards,
Bhavesh
Been a long time since i postred this question.
But finally this issue saw the light at the end f the tunnel.
Henrique~ Dont ask me how it worked now when it didnt work earlier I tried another webservice now and was able to use the HTTP adapter to post the Webservice request and get the response back and like you had correctly mentioned the HTTP header filed to be used was SOAPACTION with the corresponding value for the Soap action.
The only difference was that the earlier system was a XI SP 14 one and this one is a PI SP 10 one. Maybe there was some bug in the HTTP header field , but now things work fine.
Anyone need info on how to use the HTTP adapter to post SOAP messages , I can be of help
Regards
Bhavesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bhavesh,
i assume, this is an error message from you mapping, not from the called webservice?!
If i'm right, your mapping programm expects content type "text/xml". The content type is not part of the payload, it belongs to http header.
I think, the responsibility for that error lays at sending application, where you have to configure the content type.
Regards,
Udo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bhavesh,
you should be able to analyse the error in the SXMB-Monitoring, may be increase the trace to 3. The error appears either at "Mapping of Request Message" or "Call of an Adapter". To be shure put a division to zero (int i = 1 / 0;) at the end of the program. If the error changes, your program is ok, but the receiver does not accept the content type. My suspect is the mapping.
Try to send the request by XMLSpy or, very easy, by <a href="http://www.robweb.de/wfetch.zip">wfetch</a>.
Regards,
Udo
The problem is that the content type is not part of the payload nor of the soap envelope, but it's rather part of the HTTP request header.
I'm just guessing here, but why don't you try to use Soap Adapter-Specific Attribute Header Field?
Set XHeaderName1 attribute to "Content-Type" (without the quotes) and use Dynamic Configuration to set xHeaderName1 attribute to "text/xml".
Regards,
Henrique.
Hi Henrique,
<i>Set XHeaderName1 attribute to "Content-Type" (without the quotes) and use Dynamic Configuration to set xHeaderName1 attribute to "text/xml".</i>
When I select the Adapter Specific Identifiers, I do not get an option / input screen where I can enter these fields.. Any idea as to where an how I should do this?
Regards,
Bhavesh
Bhavesh,
I guess Soap Adapter doesn't behave in real life like it should, as described in the specification. 😕
http://help.sap.com/saphelp_nw2004s/helpdata/en/29/5bd93f130f9215e10000000a155106/content.htm
As I said, I've never done this before, it was just a guess.
Anyway, since you're generating Soap Envelope in your mapping, why don't you try to use plain HTTP adapter?
I think that Header edition for HTTP adapter is working OK.
Regards,
Henrique.
Henrique,
Actually foun the reson for the non availablityt of ADAPTER SPECIFIC IDENTIFIERS ~~ it is applicable only from sp 17 and am on Sp 16.
I am just developing this scenario as a learning experience of trying to configure a SOAP adapter in the non SOAP mode , and so am not giving up that easily
Regards,
Bhavesh
Bhavesh,
I think there's another issue, because I'm on PI 7.0 SP8 and I can see only Variable Transport Biding option.
I've read someone complaining about Soap adapter being bugged on Adapter-specific attributes. I guess this is it.
And about assembling soap communication from scratch, I guess it's one more reason for you to use plain HTTP Adapter, since SOAP is nothing else but HTTP+XML. 🐵
Regards,
Henrique.
Henrique,
Great info once again.. and thanks for the interest and support on this thread.
A quick question.. if i were to use a HTTP adapter instead of a SOAP adapter, how and what should I do in the following?
1. Mapping~~ What should the Target out of the request mapping be? Currenty it is the SOAP message with the SOAP envelope , header and body. Is that sufficient?
2. In the Receiver HTTP adapter, what is the details I am supposed to enter against,
TARGET HOST , SERVICE NUMBER and PATH.
How is the SOAP url and SOAP action to be used here.
Have not configured a receiver HTTP adapter and hence these elmentary questions
Regards,
Bhavesh
User | Count |
---|---|
89 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.