cancel
Showing results for 
Search instead for 
Did you mean: 

SOAP Sender - Extract Header Values

former_member183910
Participant
0 Kudos

Hello Friends,

I am executing SOAP sender to RFC scenario.

I am sending SOAP request through a test tool. This is the request data which goes to SOAP sender.

POST http://19.49.188.158:50000/XISOAPAdapter/MessageServlet?channel=:DEV:Sender_SOAP_BPSearch&version=3.... HTTP/1.1

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

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

MyCookie: SmgqXkpotv

User-Agent: Jakarta Commons-HttpClient/3.1

Proxy-Connection: Keep-Alive

Content-Length: 323

Authorization: Basic bXNhbmRlZTQ6c2FwX3Npc2w=

Host: 19.49.188.158:50000

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:sap.com">

<soapenv:Header/>

<soapenv:Body>

<urn:BPSearch_MT_Input>

<BP_ID>001</BP_ID>

</urn:BPSearch_MT_Input>

</soapenv:Body>

</soapenv:Envelope>

I am doing graphical mapping. In mapping time I want to extract the value of MyCookie which is set in Header (see above).

I can use "Set Adapter specific Message Attributes" checkbox. but what to do after that?

Any idea how to extract MyCookie this?

Accepted Solutions (0)

Answers (1)

Answers (1)

stefan_grube
Active Contributor
0 Kudos

You check also variable Transport Binding and enter MyCookie as Variable header.

In your message header, you should find the dynamic parameter XHeaderName1 with the content SmgqXkpotv

former_member183910
Participant
0 Kudos

Hi Stefan,

I checked "variable transport binding" and maintained "MyCookie" against Variable Header(XHeaderName1).

I executed complete scenario, but not able to get the value of "MyCookie" in mapping time.

In the link below

http://help.sap.com/saphelp_nw04/helpdata/en/b1/f29e7a56e18a439984a3c6630951d2/frameset.htm

In this it is mentioned that I can retrieve the value of SRemoteUser and SRemoteHost by choosing Variable Transport Binding option. But they have not mentioned "how to retrive header value set by user".

Please help.

Thanks,

Sandeep

stefan_grube
Active Contributor
0 Kudos

Could you check in sxmb_moni, whether the dynamic values are present?

former_member183910
Participant
0 Kudos

Thanks for reply Stefan,

In sxmb_moni, in Inbound SOAP header I can see these values,

a) SServerPort

b) SServerHost

c) SHeaderSOAPACTION

d) SRemoteUser

e) SAuthType

f) SServerName

g) SQueryString

h) SRequestScheme

i) SRemoteHost

j) SRemoteAddr

k) SHeaderUSER-AGENT

but there is no value corresponding to "MyCookie". Is there any adapter module to set extra values (like "MyCookie") while adapter execution?

Thanks,

Sandeep

stefan_grube
Active Contributor
0 Kudos

By the way: What version and SP do you have?

former_member183910
Participant
0 Kudos

Hi Stefan,

PI 7.0 and Service Pack 14.

they have provided more options in newer pack?

stefan_grube
Active Contributor
0 Kudos

The feature that I described is part of SP14, so this should work for you.

Former Member
0 Kudos

Sandeep, Stefan,

I am having a similar problem attempting to use XHeaderName1 set in a Sending Mail adapter and interogated in receiver determination. I am using PI 7.1 and all the 'S'-type context elements are seen in the dynamic configuration - but none of the 'X'-type context variables.

I'd love to know the answer.

Cheers,

Guy

Former Member
0 Kudos

Same problem here. Did you finally find a solution?

Former Member
0 Kudos

As far as i know we can use variable transport binding only for standard HTTP header values like say: authentication, i dont think we use it for custom fields. Is the field that you mentioned a standard HTTP header field?

former_member183910
Participant
0 Kudos

No Solution yet... PI is crap product. Its giving very limited features to consultants.

Former Member
0 Kudos

Hi,

If this is not working, you should open a ticket. It could be an old bug.

Alternatively, you can just use the axis adapter. Its FAQ note 1039369 has a few examples working the HTTP headers.Bes

Best regards, Yza