on 11-05-2014 4:52 PM
Hi All,
SAP PI system : SAP PI 7.4
Interface Scenario : Proxy to File (Asynchronous proxy)
We have requirement where we need to enable sequencing of message coming from SAP system to SAP PI7.4 using asynchronous proxy .Please suggest how can we perform sequencing of message based on any field value in Proxy so that message enter and Process in PI on the same sequence as they have been triggered from SAP .
Here we are using header creation logic in PI mapping - If package ID(field in Proxy ) =1 then only header will create for that message output and in receiver file adapter appending of file is happening to create one final file .
Issue case :
We are sending 3 messages in a go from SAP . say
10000 rows with package ID 1 + 10000 rows with package ID 2 + 250 rows with package ID 3.
When messages are triggered, they are in correct order. Even in SAP sxmb_moni, we get same order.
But as 250 rows is a small packet in message 3 , it reaches PI First. then message 1 and then message 2.
So order 1 2 3 is getting converted to 3 1 2 due to we are getting header in middle of the final appending file. like message 3 without header + message 1 with header and then message 2 without header.
Thanks is advance and appreciate timely help .
Regards,
Rajeshwar Singh
Hi Rajeshwar,
Eng Swee Yeoh is correct.
You can get it from below links
Guaranteeing Exactly Once In Order - Proxy Programming - SAP Library
Regards,
Suhale Shaik.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
You can call a async proxy in a EOIO manner t PI which will maintain sequence in PI as well and at the end once all ur records are send to PI u can make a dummy proxy call (with a flag/indicator) so that PI can understand that the file is completely written (all data appended in a single file) and eventually file can be delivered to end system.
Thanks
Amit Srivastava
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Amit,
Thanks for your quick response.
But in PI 7.4 I am using Soap adapter type with transport protocol : HTTP and message protocol: XI3.0 for proxy sender channel . Here I am not getting any option of Quality of service where i can define EOIO QoS.
Please suggest if anything i am missing here.
Regards,
Rajeshwar Singh
Hello,
You have to define EOIO protocol in the proxy code itself and the same sequence will be followed in PI.
You can break ur scenario in two steps -
1) EOIO Proxy -> PI -> File (NFS) - From the proxy send the file name with each record as well as for the trigger/flag file. PI will create/append data in a file (use DC to create file name). At the end proxy will send an empty message with a trigger flag and the name of the trigger file. So eventually in the staging NFS directory u will have two files - main data file + Trigger file (having same names but with different extension)
2)File (NFS) -> PI -> Target system - In this scenario, search for a trigger file and then pick ur main data file as an attachment. Then using payload swap bean send the attachment as the main document.
Thanks
Amit Srivastava
For making EOIO proxy call from SAP check below blog. In proxy u will set the queue name and the sequence in which message will be send to PI. And the same sequence will be followed while appending the data in file.
For Step 2 - Picking main and trigger file u can refer below help
Specifying Additional Files in the Sender File Adapter - Advanced Adapter Engine - SAP Library
Hi Rajeshwar
Amit is correct that you need to set EOIO from the sender system, and not at the sender SOAP adapter (not available anyway.)
The particular code for setting EOIO in sender program calling the proxy is the SET_SERIALIZATION_CONTEXT() method of the ASYNC_MESSAGING protocol.
Please suggest how can we perform sequencing of message based on any field value
Not too sure about what you mean from your above statement. If the interface always have just one queue, then you can just hardcode the input for the above method.
However, if you need different queues for messages with different field value (i.e. all messages where field1 = 'ABC' goes into queue1, all messages where field1 = 'XYZ' goes to queue 2.) then the queue name should be dynamically constructed as a variable before passing into the method.
Rgds
Eng Swee
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
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.