SAP Cloud Platform Integration (CPI) || Part 8 || Working with Request Reply
This blog post is a part of a series of blog posts related to SAP Cloud Platform Integration. The blogs so far are:
- My adventure in learning CPI || Part 1 || All about SAP Cloud
- My adventure in learning CPI || Part 2 || Deployment Models
- My adventure in learning CPI || Part 3 || Cloud Security
- SAP Cloud Platform Integration (CPI) || Part 4 || Know your tool
- SAP Cloud Platform Integration (CPI) || Part 5 || Content Modifier
- SAP Cloud Platform Integration (CPI) || Part 6 || Configuring Mail Adapter
- SAP Cloud Platform Integration (CPI) || Part 7 || Maintaining logs by using “Groovy Scripts”, even if the IFlow is not on trace mode
- SAP Cloud Platform Integration (CPI) || Part 9 || SAP Cloud Platform Cockpit || All about Account, Tenant, and User ID
Other CPI blogs:
- SAP Cloud Platform Integration (CPI) || Fetching Report’s data from ECC to C4C via CPI (Alternative for Mashups in C4C/ Integration fo ECC, CPI, and C4C)
—– —– —– —– —– —–
As shown in the screenshot above, you can reach out to Request Reply from Internal Call –> External Call –> Request Reply.
The question is what is this Request Reply, and in which all scenarios, you can use this functionality provided by SAP, by standard, out-of-the-box.
REQUEST REPLY helps you to call an external system (receiver), and get back a response. In certain scenarios, the Integration Flow is expected to communicate with an external service to retrieve, post, delete, update, the data, and further process the data synchronously. In such cases, the external service exposes the data through REST API, and you can use the Request Reply to connect to that service via HTTP/ OData/ SOAP (SOAP 1.x) receiver adapter.
To demonstrate the usage in an instance, I have used the OData receiver adapter, to consumer the data exposed by CPI, via OData Services.
1. Start Timer: Since there is no Sender System in this instance, I have used a Start Timer, which would trigger the message once it is deployed.
2. Request Reply: The Request Reply doesnot have any configurations attached to it. It needs to be connected to a Receiver system via a OData or HTTP or SOAP adapter.
3. OData: In the screenshot below, you can see the configuration i.e. the Connection, and Processing.
*** For the link, go to your C4C Tenant, go to ADMINISTRATOR –> OData SERVICE EXPLORER > *select a SAP OData SERVICES or a CUSTOM OData SERVICES, and click on VIEW.
– – –
Select the required Operation Details [Query (GET), Create (POST), Delete (DELETE), etc, and click on SELECT button.
STEP 1: Connect to System
- Connection Source: Could be Remote/ Local EDMX File. I always prefer Local EDMX File. All the link and credential details you can entered in the “Connection” step, shall flow here.
STEP 2: Select Entity & Define Operation
- Here, select the Entity whose data you want to pull. Sometimes, you won’t be able to see all the Entities. In such a case, just increase the Sub Level on the left from 0 to 4 or 5. Now, select the fields whose values you want the IFlow to call from the external system.
STEP 3: Configure Filter & Sorting
- This step is not mandatory. You can use to set filter parameters. In my case, I am trying to GET data for only 1 record.
- You can also sort the data (Ascending/ Descending), based in the fields of the selected entity.
Now, click on FINISH to generate an .xsd file. You shall understand the use of this file generated in upcoming blogs. Hint: This .xsd file contains the structure of the data coming from the Receiver system. Where and how to use it? Stay tuned with this blog series to know more.
4. Mail: To know how the mail adapter works, click here.
Now, save the IFlow, and hit the Deploy Button.
- IFlow, deployed!
- Message, processed!
- Email, received!
Hope you had a good read.
If you wish to know more, or have any queries on this blog, then please feel free to drop a comment.
Thanks & Regards,