on 10-11-2010 3:48 PM
Hi there,
I am trying to configure the MessageIDExtractor Axis handler (java:com.sap.aii.axis.soap.MessageIDExtractor) in a SOAP Sender CC. However, the sample provided in de Axis FAQ is not enough to complete the configuration.
I want to take the value of a SOAP Header element in the payload, and reuse that as PI Message ID.
The path to the ID will be somthing like; "anamespace:A_SOAP_Header/AId"
Many thanks,
Roberto
Hi Roberto,
The instruction in the FAQ note is actually straightforward if you are familiar with the xpath notation.
If it's not working, can you provide how you set these parameters and how your SOAP envelope exactly looks?
Regards, yza
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
>
> ....
> The instruction in the FAQ note is actually straightforward if you are familiar with the xpath notation.
>
> If it's not working, can you provide how you set these parameters and how your SOAP envelope exactly looks?
>
+
# Can I extract some ID value from the SOAP envelope and use it as the message ID?+
You can use the com.sap.aii.axis.soap.MessageIDExtrator handler to extract some ID value from the SOAP envelope and use it as the message ID. This handler can extract an ID string value (i.e., the 36-character GUID string) from the SOAP envelope and set it to the request or response message ID property in the message context. The ID string must be contained within some XML element. See a configuration for extracting the ID from WS-Addressing's MessageID element. {quote)
Hi,
Thanks for your reply;
I'm familiar with xpath however the FAQ does not mention the use of xpath anywhere. Please see above an extract of the FAQ regarding the MessageIDExtractor;
The provided example of the module configuration looks like this:
Module Key | Parameter Name | Parameter Value
id | handler.type | java.com.sap.aii.axis.soap.MessageIDExtractor
xireq | handler.type | java.com.sap.aii.axis.xi.XI30InboundHandler
sap | module.pivot | true
xires | handler.type | java.com.sap.aii.axis.xi.XI30InboundHandler
When you observe this configuration you notice that there's only one entry for the MessageIDExtractor. How will the handler know which XML field to pick from the incoming SOAP envelope? I think the example is missing some additional parameters where you can provide the xpath query.
Can you clarify?
Many thanks,
Roberto
Edited by: Roberto Viana on Nov 5, 2010 9:00 AM
Edited by: Roberto Viana on Nov 5, 2010 9:06 AM
Hi Roberto,
Sorry. You are right. I was mixed up with the HeaderExtractionHandler.
MessageIDExtractor does not seem use the xpath notation at all but uses only the namespace name and element name.
If your "AId" element contains the ID value and if this element has namespace, say "urn:tmp", you can use
namespace = urn:tmp
name = AId
If this doesn't work, you should open a ticket and ask for clarification.
Alternatively, you might want to use the HeaderExtractionHandler to extract the ID value and set it to the request.id context property.
Regards, yza
Hi Yza, please see below a sample of the soap envelope.
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:sap-com:document:sap:rfc:functions">
<soapenv:Header xmlns:xyz="http://www.xyz.com/log/EventObj">
<xyz:E2EHeader>
<CorrelationID>a83ac57ab4b437ca81ca6bf718b82abc</CorrelationID>
<MessageID>781ac72600000124dd4fc99cffff802d</MessageID>
<ExternalID>TR7777</ExternalID>
<MessageType>Z_HR</MessageType>
<ServiceName>HR_CAFETARIA</ServiceName>
<Operation>GET</Operation>
<Timestamp>2009-11-12T15:50:14.090+01:00</Timestamp>
<Activity>RECEIVE</Activity>
<Status>OK</Status>
<Direction>REQUEST</Direction>
<SourceSystem>SOAPUI</SourceSystem>
<TargetSystem>SAPPI</TargetSystem>
<ComponentID>none</ComponentID>
</xyz:E2EHeader>
</soapenv:Header>
<soapenv:Body>
.....
.....
</soapenv:Body>
</soapenv:Envelope>
I am trying to use the field correlation id as PI message id.
Tnx, Roberto
Edited by: Roberto Viana on Nov 10, 2010 8:45 AM
Edited by: Roberto Viana on Nov 10, 2010 2:04 PM
Hi Roberto,
Okay. Your ID field "CorrelationID" has no namespace, so you must set parameter namespace to an empty string and parameter name to CorrelationID,
This will pick the CorrelationID value. However, you may hit an error complaining about the syntax of the ID string because your ID value is a plain 32-character string instead of a hyphenated standard 36-character GUID string. In this case, you will need to get a more recent SP version or ask for the patch availability for your SP.
Regards, Yza
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.