cancel
Showing results for 
Search instead for 
Did you mean: 

RFC Adapter as Sender

Former Member
0 Kudos

Hi Experts,

We have a business scenario wherein I have to execute the RFC function(async) from an ABAP in R/3 and update the data in DB2 tables(async).

I am using RFC as sender(async) and JDBC as receiver(async). I configured/registered the RFC connection in SM59 and used the same program id in RFC sender adapter. I tested the connection in standalone mode, it is working.

The RFC function when I imported will have a request and a response. The data that I require to send to JDBC adapter is in the response. So I tried to use RFC response and created a message interface. Then I used that in my interface mapping and in the sender & receiver agreements. In the message mapping I used response that was imported.

I get an error message saying sender agreement not found. The as per OSS note 730870 I changed the sender agreement to use RFC function as sender interface, I cannot use this function module for my mapping, as it does not contain the response.

Am I doing something wrong. Can somebody show me some direction.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Srinivas,

If you want to update a database table using the contents of an RFC response, you have to configure an RFC reciever adapter, make a synchronous RFC call from XI , which will get you the response , now you map this response data to the JDBC data structure and update the database.

You can use ccBPM , where in you have a sync Send step which will get you the response , now call transformation step , map the response to JDBC data structure , execute an Async call using JDBc receiver adapter and you are done.

Now , if you want to trigger this from SAP , you can configrue an RFC sender adapter , which will send a dummy trigger message, recieve this dummy trigger in ccBPM, now proceed with the sync RFC call like i mentioned above.

My 2 cents.

Thanks

Saravana

Former Member
0 Kudos

Hi Saravana,

In my businessscenario I need an user interface before calling the RFC function. So I wrote a wrapper around the RFC which will provide me with user interface, then I would like to send the response data to XI using RFC sender.

We are on XI3.0 SP13. I have to use the response(of RFC) in the message mapping and should be able to send the data to JDBC Adapter.

Thanks.

Srini

Former Member
0 Kudos

If I use the RFC response in message mapping, and use RFC function in sender agrement but use the O/B interface created based on RFC response in receiver agreement. I pass the error of "No sender Agreement", but will have an error in receiver determination.

"call to messaging system failed: com.sap.aii.af.ra.ms.api.DeliveryException:" when I execute my RFC in R/3.

Former Member
0 Kudos

Hi Srinivas ,

If you want to capture the response of an RFC execution in XI and then map this response to another structure(In ur case a JDBC structure) inside XI message mapping , then you will have to use the RFC reciever adapter of XI and NOT the RFC sender adapter.If you use the RFC sender adapter, it means that your SAP system is acting as an RFC CLIENT, what happens is the REQUEST structure in your RFC destination will be converted to RFC-XML by the RFC sender adapter of XI and is available for furthur processing.

But then, If you want to send the RESPONSE structure of an RFC to XI , one way is to execute the RFC in SAP(without passing this thru XI), now you have to pass the result of this RFC execution to XI by assigning it to a request structure of another RFC in your ABAP code and pass it to XI using RFC sender adapter.

If not , you can use a dummy RFC in SAP to send a trigger to XI , execute the actual RFC in XI using RFC reciever adapter , capture the response , map it to ur JDBC structure and you are done.

May be you can give a try on these lines. As for the error , you can chk these threads and see if it helps

Thanks

Saravana

Former Member
0 Kudos

Hi Saravana,

Now I understood how the sender RFC works in XI. Its a bit tricky. So may be somebody need to write a blog in detail describing the limitations of sender RFC and when/how it should be used.

Thanks for your help.

Srini Vaidyam

Former Member
0 Kudos

Hi Srinivas,

I hope you could help me with this. I am also using RFC sender adapter to receive the response from a RFC function module. I am doing no mapping sending the whole RFC as interface. I don't know what triggers the RFC to send the data to XI in R/3.

When we use the sender RFC adapter, is it automatically gets the response from the RFC, when the RFC executes in R/3?

Looks like you have used the sender RFC in your scenario, can you please help me in this regard?

Thanks

Kalyan

Former Member
0 Kudos

Srinivas, could you please come up with the steps(step by step) thats been involved for your scenario.

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Experts,

i'm tring to make a simple scenario where rfc send data to an sql server.

i made all the mappings interfaces etc, necesary but the rfc function when i execute make a dump "Server repository could not create a function template"

thanks

Former Member
0 Kudos

I guess you haven't defined the appropriate server settings for "RFC Metadata Repository" in the RFC Sender Adapter settings. It must point to a server where the function is defined. The sender adapter accesses the rfc meta data at runtime.

Former Member
0 Kudos

Thank you very much Roland, it was that.

Former Member
0 Kudos

Hi Roland,

i have another problem now, i make the scenario

RFC -- (RFC Adapter sync) -- XI -- (JDBC adapter sync) DB

i execute some rfc function and then execute a Store Prcedure that insert on the DB and response with the new ID. The scenario is working find, is making the call, inserting the records, but i cant get the ID back to backend as a reponse. When i see the sxmb_moni i even not see the message going into the DB only se something on the end to end monitoring.

could you please give some help?

thanks

Former Member
0 Kudos

hello,

a hint to your sxmb_moni issue. the integration server by default desn't persist synch messges. if you want to see your successful sync messages you will have to switch on the sync logging expicitly. use sxmb_adm there the "Integration Ending Configuration" there category RUNTIME and "Specific Configuration". Set the paramter LOGGING_SYNC to 1 (default 0). Don't on your production engine, it slows down.

concerning jdbc receiver adapter i'd be curious of your solution. i guess you havent forgotten to set the isOutput="true" for your output paramters yust like in

http://help.sap.com/saphelp_nw04/helpdata/en/2e/96fd3f2d14e869e10000000a155106/content.htm

i suspect you will have to provide a mapping back from the output structre of the store procedure call to the rfc xml importing structure.

regards

roland

Former Member
0 Kudos

Just to let you know that I deleted the sender/receiver agrements and receiver/interface determination. Then I started creating new interface determination I cannot find the interface mapping as the interface mapping user response and I users the RFC(request) in sender agreement and receiver determination.