cancel
Showing results for 
Search instead for 
Did you mean: 

Response from BAPI to XI asynchronously

Former Member
0 Kudos

Hi

I have a scenario where the customer would send a huge file ( aorund 2 million records), our file adapter picks up the file and maps it BAPI_PO_CREATE and creates a purchase order and get the responses back from BAPI with the PO number created and send them back to the customer.

As far as I understand, since the number of records are huge we usually use asynchronous mode to call the BAPI, My question is now how do we get the PO order numbers created?.

I have the following options

1. Call ABAP Proxy (Wrapper function module) asynchronously, which inturn calls the BAPI Synchronously and use the same ABAP Proxy to return the response to XI asynchronously.

2. Call the BAPI asynchrously through RFC Adapter and then use ABAP Proxy to return the response back to XI. ( Not sure how this can be implemented)

Any help on this would be appreciated.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Rakesh,

In our project facing the same problems, we do just like these:

1. Using ABAP server proxy(asynchronous) trans to R3 and store the info into the tables created just before.

2. Schedule a job in R3 calling the BAPIs,and store the PO numbers to another table.

3. Call a ABAP client proxy(asynchronous) trans the respones.

BTW, Maybe, Using a flag column sign the process creating POs successful or not is useful. You can rehandle these error records automatic next time. Also, you can using a column record why error occur.

Regards

Terry

Former Member
0 Kudos

Hi Terry

Thanks for your response.

Can you please let us know how is the ABAP Client Proxt ( asynchronous) triggered to transfer the response back to XI

Is it scheduled as in point 2? If yes, on what interval, any screenshots on this would be very helpful.

Thanks

Rakesh

Former Member
0 Kudos

Terry Qin

Maybe there is a reason. But I consider it is heavyweight. Why not to call BAPI dicrectly from ABAP Server proxy and later to call client Proxy for response without job scheduling?

Or do you use this mechaninsm in order to reprocess failed POs?

Former Member
0 Kudos

Hi Rakesh,

I am sorry, the step 2 and step 3 just in one report program. At the end of loop the table calling BAPIs, Call the ABAP Client Proxy to send the PO numbers that crearted just before.

Hi Sergey,

Probably, your choice will be running very well deal with a small message.But for dealing with a huge message with many many PO records, I don't think it is a wise choice. I make my choice focus on performance in R3.

Just you say, call BAPI dicrectly from ABAP Server proxy, if the message is very large, it will be take long times processing. Only once one record in message has error occurs calling the BAPIs, This message will be set to application error. So you have to restart these error message frequently, that likely cause deadlock because of calling BAPIs will consume resources. Also that maybe make the inbound queue block up.

We have make a flag sign the failed POs in the table, it will be rehandle next time.

Regards

Terry

gajendra_bhakuni
Active Participant
0 Kudos

Hi,

Check the following blog:

<a href="/people/arpit.seth/blog/2005/06/27/rfc-scenario-using-bpm--starter-kit to RFC</a>

Hope this helps.

Regards,

Gajendra.

Former Member
0 Kudos

Gjendra,

I worked on this scenario.

Just i'm thinking whether this BPM would be suggestable appraoch for 2 million records per hour message process.

Thi guy is looking for handling huge volume and best practice to send responce back.in understood.

intresting.

thanks,

venu

Former Member
0 Kudos

Hi Venu and Gajendra

Gajendra -- Even I have worked on this scenario but i do not think it is advisable for processing huge data file.

Venu - I understand we need to call BAPI Asynchronously and if u think SAP is going to store the PO Numbers created on a table, do u think we need use User-Exits to trigger any response to send back the data to XI.

Let me know if my question is unclear.

Thanks

Rakesh

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

>>>>I understand we need to call BAPI Asynchronously and if u think SAP is going to store the PO Numbers created on a table

AFAIK there is no bapi for creating multiple POs

do as you've proposed:

- call ABAP server proxy

- call BAPIs in a loop and store the PO numbers

- call another asyn client proxy with a response

Regards,

michal

-


<a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

Former Member
0 Kudos

thanks Michal for validating my response to his query.

but according to him I understood, client want to map the source records to single BAPI ie BAPI_PO_CREATE which will post at once for all records to SAP.

In this case can we suggest him to use proxy only..for performace reasons or someother if any...

thanks,

venu.

Former Member
0 Kudos

Hi Rakesh,

Since the number of records is huge, I can suggest use asynchronous process, in this case SAP side after posting all the transactions there should be a mechanism to log the PO number and success message in a file or any Data base Table.(Just create file with the message in application server , XI will process asynchronously to send this success message to sender side) or ( Just store information in Table and send the data to source through client proxy)

Case 1

If you are directly mapping to BAPI no need to go for Proxy,

If not mapping directly use server proxy to send the data to SAP abap format. And post the data to BAPI.

In either case I suggest asynchronous only.

Case 2.

It is not clear, hope I explained in case 1, if I could understand correctly.

Note: Welcome Debate on this process.

Cheers,

venu