on 11-15-2016 8:37 AM
Hi experts.
I heard that it is not recommended to implement lookup in java mapping if something is written to a receiver system during lookup. They say it is not guaranteed that mapping will be run only once during message processing.
If it is really true then I would like to see the source of these recommendations from SAP. Could you please suggest something?
Best regards,
Andrey
Hi Andrey!
I couldn't find recommendations from SAP itself, but I read the blogs describing these constraints.
Let's imagine, that we have asynchronous scenario with message mapping at receiver side in which some kind of lookup is used. And this lookup changes some data in a sided target system. During message processing something went wrong while delivering to receiver (connection issue, for example) and message failed. But your message mapping has been successfuly proccessed and data was changed in target system by lookup. What PI is gonna do? Yes, it tries to process that failed message again (as it's in asynchronous mode) and all the steps are repeated including message mapping execution. Thus, you get second data change by lookup.
Even if you use synchronous communication and it fails somewhere after processing message mapping step you'll get the same result. When sender sends request again (as previous was unsuccessful) data in target system is changed again.
Of course, if you're quite sure that this repeating data change won't affect target system data consistency(for example, it will just update existing data with the same values), you can proceed with such lookup functionality, but it's definitely not a good practice.
Regards, Evgeniy.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
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.