SAP PI: Synchronous Sender JDBC Adapter

Recently I was working on an interface where users were updating materials in a database, and these changes had to be sent to their SAP backend system (ECC). They wanted to leverage an existing RFC in order to minimise the amount of extra development required, and the response from the RFC call needed to be saved in the database:

Unfortunately SAP PI does not provide a synchronous sender JDBC adapter which is needed for this interface. Although this makes sense from a technical standpoint, it can be limiting when you really need it.

While it’s not possible to have a true synchronous JDBC adapter, it is possible to combine a Sender and Receiver channel in order to get a similar result. Assuming the sender channel has already been set up (asynchronously), the first step is to tell PI that there will be a response message to handle:

Be careful to match up the Module Keys, and note that parameters are case-sensitive.

The second step is to tell PI what to do with the response message. We want to redirect it to a receiver channel which has already been created. The details we need to provide can be found in the receiver channel object:

With this we can fill in the last details:

Using this set-up, we can assign synchronous interfaces to the sender channel, and for the most part there will be no difference. However, there are a couple of things to consider:

  • The sender and receiver channel do not run in the same database session
    Commit and rollback statements should be used correctly in order to avoid locks (especially relevant when the response updates the same record)
  • The channels appear separately in the monitoring tools
    When troubleshooting, you will need to check both channels.

blogger

blogger

Curious to know more about this topic?

Working at i8c

i8c is a system integrator that strives for an informal atmosphere between its employees, who have an average age of approx 30 years old. We invest a lot of effort in the professional development of each individual, through a direct connection between the consultants and the management (no multiple layers of middle management). We are based in Kontich, near Antwerp, but our customers are mainly located in the triangle Ghent-Antwerp-Brussels and belong to the top 500 companies in Belgium (Securex, Electrabel, UCB, etc…).

Quality Assurance

i8c is committed to delivering quality services and providing customer satisfaction. That’s why we invested in the introduction of a Quality Management System, which resulted in our ISO9001:2000 certification. This guarantees that we will meet your expectations, as a reliable, efficient and mature partner for your SOA & integration projects.

i8c - ISO9001-2015

Also worth reading

AWS AppFlow: Streamlining SaaS Integrations with AWS Services

In today’s digital world, organizations are constantly looking for ways to streamline their workflows and improve their data management processes. One of the key challenges that organizations face is integrating their various software as a service (SaaS) applications with their data management systems. This is

Read More »

Apigee Scope Validation using OpenAPI Specification

In API security and management, we often use a lot of different security mechanisms to protect the requested resource behind the API Gateway. One of these mechanisms is the validation of scopes to authorize a client on a specific sub-resource of the API. Most of

Read More »