on 09-11-2006 1:25 PM
Hi,
is there a way to access the XI message header information in user defined Java mapping functions or custom mapping programs? I know how to access the dynamic configuration but not the other or self added header parts.
Kind regards,
Heiko
Hi,
if you want to get values from the dynamic configuration
you can use the code from my weblog:
/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14
you can use it in both: user defined functions
in message mapping and in java mappings
Regards,
michal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If you are talking specifically in terms of the SOAP adapter , select the option KEEP HEADER in the Sender SOAP adapter and this will pass the SOAP header also as a part of the payload and then you can access this using the Mapping ( Java Mapping). AM not sure if there is a standrad class to do this.
Regards,
Bhavesh
For the sender SOAP adapter, try checking use adapter specific message atributes, variable binding, and then set XHeaderName1 with the name of the header you're expecting.
You can later read this header with regular dynamic configuration methods.
Check out this link: http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/5ad93f130f9215e10000000a155106/content.htm
Regards,
Henrique.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Not actually. If you just want to access the attribute value (since you are writing the header value in a specific attribute) just use .get method for dynamic configuration object, like in this example:
http://help.sap.com/saphelp_nw2004s/helpdata/en/43/03612cdecc6e76e10000000a422035/frameset.htm
The difference is that for your case the namespace will be http://sap.com/xi/XI/System/SOAP and the technical name will be XHeaderName1.
Regards,
Henrique.
Hi Heiko,
here a sample for accessing the message-id:
********************************************
String msgid;
java.util.Map map;
map = container.getTransformationParameters();
msgid = (String) map.get(StreamTransformationConstants.MESSAGE_ID);
return msgid;
********************************************
See also:
http://help.sap.com/saphelp_nw04/helpdata/en/e2/e13fcd80fe47768df001a558ed10b6/content.htm
Regards Mario
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
94 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.