cancel
Showing results for 
Search instead for 
Did you mean: 

Message wait in PI

former_member223432
Participant
0 Kudos

Hi Experts,

I have a scenario..JDBC-->PI-->ECC.

we are sending the material related data to ECC(proxy) via PI...

we have 2 different materail activities..."Active" and "setup".

Active message should come first and then Set up...only then Proxy works fine at the ECC side...

But sometime, if Setup message is coming first , then this message fails in ECC(proxy) because Active message is not existing..

How do we put a check in PI to hold or wait till the "Active" message comes and process Active first and then "Setup"...these are 2 different message and not sure the time stamp between these 2 messages..they can come anytime...

please advise.

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

I agree, this could be done with ccBPM which could get resource intensive. Perhaps it could be done at the source to be less error prone (collect and only send them in correct order).

Maybe another approach purely in PI...

Are your messages keyed together somehow? Can you add a lookup in the mapping of your Setup message to see if the corresponding Active had gone through successfully in destination system? Write the result to a queuing table with "Active bit" field. You could have another JDBC sender poll that table on an interval, only looking for materials that were confirmed to be active in a prior lookup.

JDBC > PI > ECC for Active messages

JDBC > PI (RFC Lookup to ECC) > JDBC looking for setup materials which need to be confirmed, on some reasonable polling interval.

JDBC > PI > ECC  for Setup messages

iaki_vila
Active Contributor
0 Kudos

Hi Smith,

As Sunnil says there is no standard way in PI to resolve this. However, you can control this situation in the ECC endpoint, you can develop a z table where you can store the messages which the "Setup" status were getting in first. In the "Active" ECC code can read this z table in order to delete this Sertup meesagge and process later, or throwing an exception, wahtever you want.

Regards.

nabendu_sen
Active Contributor
0 Kudos

Hi Smith,

First of all, I will not suggest to handle this type of dependency within PI. You will need BPM to handle this. You will need to use correlation to handle this. (http://saptechnical.com/Tutorials/XI/BPM/Fork1.htm).

If you also handle this at Sender Side, suppose 'Active' is sent first and then 'Setup', for many reasons order can get messed up.

It would be best, if you merge (also may be separate just like now) 'Active' and 'Setup' from Sender side and write custom code at ECC side to handle this.

For each 'Active', BPM will open a thread and wait until 'Setup' comes within the BPM. I am not sure whether the messages will be coming in bulk / about each message size, which could create issues with BPM.

smavachee
Active Contributor
0 Kudos

If these are two separate interfaces, you can schedule them accordingly. But it will not be guaranteed sequential delivery from SAP PI end in case of failure of either interface.

Else use BPM with required steps.

Regards,

Sunil