cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple BAPI calls from single message

Former Member
0 Kudos

Please assist, I've been struggling with this for the past few days & cannot get it right.

My scenario:

Async message received on JMS adapter which send to integration process (IP/BPM). IP sends synchronously to multiple receivers (in my case 4), each receiver executes a SAP standard BAPI (BAPI_USER_CHANGE). BAPI responses should then be concatenated into 1 message to go back to sender through another JMS adapter.

BPM design (using Multicast pattern):

Async receive step (request message) --> Container (extract request correlation) --> Receiver determination (get receivers) --> Block (ForEach) with Synchronous Send --> Transformation (map request correlation to response message) --> Async send step (response message)

I need help with:

1. A constant time-out when BPM executes the RFC call. I've removed all but 1 receiver from receiver determination & it still gives a time-out. When I replace the Block with only a synchronous send step to the same receiver it then works.

2. How would I concatenate all the synchronous responses?

3. Any other design that might accomplish the scenario objective?

4. Can the RFC be called asynchronously & return at least a confirm message & how would I configure XI to receive this message? I've tried the Advanced options on the RFC receiver adapter but XI does not automatically receive the confirm message.

Accepted Solutions (1)

Accepted Solutions (1)

VijayKonam
Active Contributor
0 Kudos

You can make this little bit easier.

You need to create as many sender and receiver interfaces for your 4 receivng systems and required Receiver Dets, Interface Dets and Receiver Agreements need to be created.

In the BPM,

Receive->Block->4 branches with 4 send steps-> Container to club 4 responses in to one->close Block->Transform 4 to 1->Send Async

VJ

Former Member
0 Kudos

Thank you VJ, assistance appreciated.

I cannot create a "Branch" for a Block though; only options available are u201CException branchu201D and u201CDeadline branchu201D.

What I've done so far, to get it working:

Receive async --> Container (extract request correlation) --> Fork --> 4 branches with 4 Send sync steps (each within an own block because of exception handling) --> Close fork --> Transformation (map request correlation & 4 responses into one response message) --> Send async

Just need a little more help with the following please.

I'm currently puzzled by one of the send sync steps as it returns a BAPI application exception.

The following is returned:

<rfc:BAPI_USER_CHANGE.Exception xmlns:rfc="urn:sap-com:document:sap:rfc:functions">

<Name>RFC_ERROR_SYSTEM_FAILURE</Name>

<Text>User XIAPPLUSER has no RFC authorization for function group SU_USER .</Text>

<Message>

<ID>RFC_ERROR_SYSTEM_FAILURE</ID>

<Number>null</Number>

</Message>

</rfc:BAPI_USER_CHANGE.Exception>

Now XI does not recognise this BAPI Exception (BAPI "Fault" is empty) and the BAPI does not even contain a defined Exception in the function module (SE37). Where does it then come from?

How would I handle this then as I cannot link the BAPI Exception to the interface mapping? (All I do currently to continue processing is throw an alert BUT I would prefer passing this on to the user as well)

Edited by: Marius de Wet on Aug 28, 2008 4:07 PM

VijayKonam
Active Contributor
0 Kudos

This exception is not coming from the BAPI. Even before the BAPI gets executed. It is as access violation and would not happen at runtime if the XIAPPLUSER is given required accesses. Provide the access it should work. Any other exceptions returned from BAPI would be filled with XI fault message.

VJ

Former Member
0 Kudos

I understand. Again, thank you very much for the assistance. Greatly appreciated.

Answers (0)