We had a business requirement where the nature of the interface is Request Response kind. However, there would be large volume of data that will be processed in this. So keeping the performance in mind we needed to split the scenario with two Asynchronous message flows instead of a single Synchronous integration. However the challenge is we need to keep track from ECC on which outbound message is for which inbound.
Our issue was to put an Xref entry in Z table in ECC side which keeps track on which outbound message is for which inbound. To do this we need the outbound message Id while calling the proxy itself. However, the message ID is not readily available in ECC.
Basically we used the concept of inheritance to trap the message ID while calling the proxy.
In our case the original proxy outbound class is ZZZCO_IDD0533_CONFIRM_TRANSFER.
We created a child class (ZCL_COM_CALL_PROXY_IDD0533) of this proxy class where our application code will be written.
Note:Proxy class ZZZCO_IDD0533_CONFIRM_TRANSFER is maintained as Super-class.
We have a Z program that calls the outbound proxy. Instead of instantiating the proxy class directly, we instantiate the child class.
Here is the code snippet:
Now let’s have a look at the code inside the method call_proxy of class ZCL_COM_CALL_PROXY_IDD0533.