Are you fiddling with SAP help to find out what exactly term correlation mean in ccBPM? I will depict the usage of correlation in real time and explain the runtime behaviour here.
Scenario
I have to collect PO6 Idocs(Custom Metering Idoc) and push the Idocs which contains the FILE_TYPE field with value ‘TST’ into one file and with value ‘PRD’ as separate file.XI Solution
I designed a ccBPM in XI, which waits for 3 minutes to collect Idocs and push the Idocs into appropriate file based on correlation FILE_TYPE as shown below.
Design time instance in IR :
Logical Flow:
1.Block Step –Collects PO6 Idocs based on correlation, which raises the timeout exception once 3 minutes is elapsed.
2.Loop Step-It executes infinitely and exits only when time out condition occurs.
3.Receive Step-Receives PO6 Idocs based on correlation File_type as shown in the below window.
4.Container Step-Appends the PO6 Idocs into a multiline container.
5.Transform Step-Transforms n PO6 Idoc into a single file structure.
6.Send Step-Sends the PO6 file appropriately to the receivers configured in the ID.
Runtime instance in IE :
Now let us check the runtime behavior. I tried to send 3 Idocs continuously using transaction WE19 as shown below.
Idoc 1 with FILE_TYPE 'TST' :
Idoc 2 with FILE_TYPE 'TST' :
Idoc 3 with FILE_TYPE 'PRD' :
We can see 3 entries as shown below in the SXMB_MONI once all the required configurations are done for Idoc to File scenario.
By clicking the PE link in SXMB_MONI we can see the workflow technical details as shown below.
Workflow Instance for Idoc 1 with FILE_TYPE 'TST' :
Workflow Instance for Idoc 2 with FILE_TYPE 'TST' :
Workflow Instance for Idoc 3 with FILE_TYPE 'PRD' :
We can see that 2 workflow instances spawned for the given scenario. Idocs(2) with same FILE_TYPE has the same instance number and a new process instance is spawned as soon as the different FILE_TYPE is triggered. Since there are 2 instances spawned, PO6 Idocs with ‘TST’ are collected together, transformed and sent as a single file. PO6 Idoc with FILE_TYPE ‘PRD’ is transformed and sent as separate file. Once the above context is clear we can define correlation as ”the relation between a message and its process instance”. I assume that blog is useful to correlate “Correlation in ccBPM”..:)
No comments:
Post a Comment