ReadFromStream - how can I access the ClientID

I am trying to create a log for processing calls to my service -
I use ReadFromStream - the read the XML that comes in - I do this
using this function because I can track even malformed XML - my
problem right now is - if I later wan to add information to his “call” how
can I identify this dataset within the actual function that is called ?
Is there a way to get access to the ClientID at this point in time ?

Also - is there a way to store temp. session data to a specific call -
may in the message ?



since xml string is usual string, you can add any info (like attribute or new node) to any position.

lets review XML request from the MegaDemo sample (formatting was added manually for better view):

<SOAP-ENV:Envelope xmlns:xsd="" xmlns:xsi="" xmlns:HNS="" xmlns:SOAP-ENC="" xmlns:SOAP-ENV="">
    <HNS:ROClientID SOAP-ENV:mustUnderstand="0">{0A53DC54-AE0A-46BA-957C-916EAB206E5A}</HNS:ROClientID>
  <SOAP-ENV:Body SOAP-ENV:encodingStyle="" xmlns:ro="">
    <NS1:Sum xmlns:NS1="urn:MegaDemoLibrary-MegaDemoService">
      <A xsi:type="xsd:int">1</A>
      <B xsi:type="xsd:int">2</B>

you can get ClientID via cutting data between <HNS:ROClientID> and </HNS:ROClientID> tags with using usual string methods.

the same - you can use usual string methods and replace </SOAP-ENV:Header> with <mytag /></SOAP-ENV:Header>


this does not work - I am getting the XML from SAP PI/PO - the dataset does not contain a “valid” Client-ID - if I understand documentation correctly the ClientID is generated when the XML is parsed ?



Not yet.
it is included into request and into response:

Note: it is valid for Remoting SDK client only.