Skip to Content

The following blog illustrates how we could call a Local Integration Process from the Main Integration Process. i.e. Performing a second Process from the Parent ( First ) Process. The focus is to make use of the Integration Elements without using any Scripting.

Scenario:

Requirement: When a Customer is created or Changed in C4C system, it sends a SOAP Message to ECC. The replication of the Customer to ECC should only happen for Create and all other mutations ( Change/Delete) on the Customer in C4C should not be sent to ECC System.

Sender System: C4C System

Receiver: ERP System

Parent Integration Process: Replicate Customer to ECC

Local Integration Process: Check if the Customer exists in ECC

Parent Process:

Screen Shot 2016-09-30 at 15.58.35.png

Second Process:

Screen Shot 2016-10-03 at 14.33.58.png

The first step that’s executed in the iflow for the incoming request is the Multicast ( Sequential).

There are ideally two types of multicast that you could choose : Parallel multicast or Sequential multicast.

* Parallel multicast initiates message transfer to all the receiver nodes in parallel.

* Sequential multicast provides an option to define the sequence in which the message transfer is initiated to the receiver nodes.

As shown below the first sequence is to check , if the customer already exists in ECC. we achieve using a process call (

Local Integration Process ) which makes a call to the ECC system using a SOAP Query . If the result of the SOAP call returns the Customer then , we terminate the whole process using “Terminate Message” event.

Second Sequence is to replicate the message to ECC. This will only happen, if the Terminate Message event is not triggered in Sequence 1.

Screen Shot 2016-10-03 at 14.37.15.png

Local Integration Process:

Scroll below to the empty space in the Model Configuration Editor. To add a local integration process to the integration flow, choose Others => Local Integration Process from the palette. On the Properties tab, provide a name.


Add elements between the start event and end event of the process. Point to note here is that , a local integration process does not support multicast and splitter elements. In this scenario, I use a request-reply step using SOAP adapter to call query ECC_CustomerERPSimpleByElementsQuery in ECC which returns Customer ID in response.



Screen Shot 2016-10-03 at 15.04.32.png



Request Mapping:


Screen Shot 2016-10-03 at 15.02.53.png


Response Mapping:

Screen Shot 2016-10-03 at 15.01.58.png

The next step is to create a router to determine the message path and define the routing conditions.

Screen Shot 2016-10-03 at 15.06.12.png

The Order in which the Condition is defined in the role plays an important role. E.g. If the outcome of one or more conditions defined in the router is same, then the first condition defined in order is executed first and the rest of the conditions will not be executed.

Screen Shot 2016-10-03 at 15.10.35.png

the xpath expression count(//ID) determines if there are any customers in the response. count(//ID) = 0, implies that the customer is not found on the ECC system and the path is routed back to the parent process.

When the expression count(//ID) = 0 fails, which implies the customer exists in the ECC, the router takes the default route where we define a “Terminate Message” event. which completely stops the processing of the Iflow further.

Before the “Terminate Message”,  we could define Content Modifier and define an error message like the below.

Screen Shot 2016-10-03 at 20.25.33.png

Finally, to the Invoke the local integration process. Select the process call element in integration flow editor which is defined in the Parent Process. In Local Integration Process field, choose Select. In Select Local Integration Process window, select the local integration process (second Process) you want to assign to the process call.

Thus, if the Terminate Message event is not triggered, the process continues with the second sequence defined in the Sequential Multicast.

References:

Developer’s Guide: Managing Integration Content Developing Integration Content Using the Integration Designer P U B L I C © 2016 SAP SE

To report this post you need to login first.

Be the first to leave a comment

You must be Logged on to comment or reply to a post.

Leave a Reply