on 06-29-2009 2:52 PM
Hi,
I'm using two chained message mapppings (one after another in the operation mapping / interface mapping).
How could I pass information from the first message mapping (graphical or Java, I don't mind) to the next one without modifying the payload?
I'm thinking if it could be possible to set some custom header parameters in the header of the message, but I think that only works in adapter module development.
Thanks!
Hi Jorge,
Try this...
UDF in first Message Mapping - setDynamicVariable(String name, String value)
DynamicConfiguration dc = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
if (dc == null)
return "Works with Interface Mapping test only. Not Message Mapping test.";
DynamicConfigurationKey key = DynamicConfigurationKey.create( "http://my.test.com/custom", name);
dc.put(key, value);
return value;
UDF in second Message Mapping: getDynamicVariable(String name)
DynamicConfiguration dc = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
if (dc == null)
return "Works with Interface Mapping only. Not Message Mapping.";
DynamicConfigurationKey key = DynamicConfigurationKey.create( "http://my.test.com/custom", name);
return dc.get(key);
Thanks,
-Russ
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Lopez,
I think your question is incomplete. If I understand correctly you have two message mappings for example and for mapping1 output should be the input of mapping2. If yes then simply take the target of mapping1 and give it as source1 of mapping2. Please see this help for more information:
/people/michal.krawczyk2/blog/2005/11/01/xi-xml-node-into-a-string-with-graphical-mapping
He is doing xsl mapping in his example. In your case change your mapping accordingly.
Regards,
---Satish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
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.