cancel
Showing results for 
Search instead for 
Did you mean: 

Async RFC -> File - EOIO

Former Member
0 Kudos

I have the following XI Scenario:

Async RFC (R/3) -> XML File (Filesystem)

I want to achieve a QoS of EOIO. I know that the RFC Adapter doesn't support this but I would like to see if there is another way of achieving this:

Assumptions:

- XI is SP16

- No ABAP proxies because R/3 is 4.6D.

- XI receives the data in the correct order because we've implemented qRFC outbound queues in R/3.

- The QOS in XI ends up being EO because the RFC Adapter doesn't support qRFC (inbound queues).

Questions:

1) Is there a way to "force" EOIO on these incoming messages without using BPM? They are already being received in the correct order. The issue is that XI can process them in any order because the QOS is EO.

2) Is it possible to use BPM to do this? Here's one idea similar to what I use to collect IDocs.

There's no collecting in this case, but by using a receive step in a loop to handle multiple calls, it guarantees that only one instance of the BPM will be running at a given time.

Loop

- Checks a counter < 100 which allows us to set a maximum # of calls that the BPM will handle. This is so the workflow log doesn't get to big to view.

Inside the Loop is a Block:

- Contains deadline branch - 1 minute from 'Creating the Step'.

- If the call sits in the block for more than a minute (aka if we haven't received anything in a minute) call the deadline branch

- In the deadline branch throw an exception

- In the exception branch quit the BPM

Inside the Block is:

- Receive Step

- Increment Counter

- Send Step with EOIO (SP16)

3) Will the calls be sent to this BPM in the order that they were received or will they be sent to the BPM in any order since they are EO?

Any ideas or comments on this approach will be appreciated. Points will be awarded.

Thanks,

Jesse

Accepted Solutions (1)

Accepted Solutions (1)

moorthy
Active Contributor
0 Kudos

Hi J,

<i>3) Will the calls be sent to this BPM in the order that they were received or will they be sent to the BPM in any order since they are EO?</i>

>>Yes.. this depends on , how and which order XI is receiving the message..

Now my question is , what is the idea behind to achieve the EOIO here? How is the RFC triggered here? Is it scheduled ? Whatever, at a time only one message will be sent right from R/3.. So what is the purpose/possibility of the multiple messages will be coming from the R/3..

And with respect to BPM design, logic is clear, but is it will not become a overhead here? Just send step inside the Loop???

this is just my views

Regards,

Moorthy

Former Member
0 Kudos

Krishna,

> <i>3) Will the calls be sent to this BPM in the order

> that they were received or will they be sent to the

> BPM in any order since they are EO?</i>

> >>Yes.. this depends on , how and which order XI is

> receiving the message..

The IE receives the messages in the correct order because we make the RFC call asynchronously (tRFC) and use a qRFC outbound queue.

> Now my question is , what is the idea behind to

> achieve the EOIO here? How is the RFC triggered here?

> Is it scheduled ? Whatever, at a time only one

> message will be sent right from R/3.. So what is the

> purpose/possibility of the multiple messages will be

> coming from the R/3..

We need EOIO because the RFC calls contain changes to R/3 records. If the calls are processed out of order, the data will get out-of-synch in the receiving system.

The RFC is triggered nightly and real-time on demand. There are typically multiple RFC calls (each with 1000 records) coming from R/3 within a few seconds (configurable) of each other. Even if there weren't multiple calls, if XI is down or a message fails, the IE could process them out of order when it comes back up because they're EO.

Essentially, I can get the messages to the IE in the correct order. I just need to process them in the correct order from that point forward.

Are you saying that the BPM (with a loop) will definitely pick up (receive) messages in the order that they are sent to the IE? I think this is critical to this approach working.

Alternatively, is there anyway to change (hack) the SOAP header using an adapter module to switch it from EO to EOIO?

Thanks,

Jesse

Former Member
0 Kudos

Hi -

I found out that you can actually get EOIO with the RFC Sender adapter using the following method:

1) R/3 - Call the RFC Asynchronously and use a qRFC Outbound queue. This guarantees that R/3 sends it to XI in the correct order.

2) XI - Write an adapter module to change the message's Quality of Service to EOIO and to set the EOIO Queue Name:

msg.setDeliverySemantics(DeliverySemantics.ExactlyOnceInOrder);

msg.setConversationId(queueName);

If anyone wants more details, let me know.

Thanks,

Jesse

Former Member
0 Kudos

Wolff,

Could u please post more details.

Please go through the blog named, "RFC adapter - EJB".

Could u please give me a brief explanation of EJB. Can EJB be compared to BAPI or not.

Another question is:

<i>R/3 - Call the RFC Asynchronously and <b>use a qRFC Outbound queue</b></i>.....How to do this.

Thx in adv,

-Naveen.

Former Member
0 Kudos

Hi Naveen,

To make an Asynchronous RFC call from SAP using a qRFC Outbound Queue (for in-order delivery):

1. Create the RFC which defines the structure of the data to be sent to XI. Leave the source code blank since the RFC is implemented by XI.

2. Create an RFC Destination in R/3 for the XI RFC Sender Adapter (transaction SM59). It needs to be of type TCPIP and use Registration mode. Specify a unique, case-sensitive Program ID.

3. In your ABAP report, call the following function module to specify the qRFC outbound queue. The queue name should be unique to the interface:

call function ‘TRFC_SET_QUEUE_NAME’

exporting

qname = <Queue Name>

<additional parameters>.

4. In your ABAP report, call the RFC Asynchronously:

call function <RFC Name>

in background task

destination <RFC Destination>

as separate unit

<additional parameters>.

5. In your ABAP report, specify the following command to send the data:

commit work.

Thanks,

Jesse

Former Member
0 Kudos

Hi Wolfe,

I am also need to have EOIO service with RFC sender adapter. I am using BPM for my interface.

Your posting is very clear on ABAP programming side. Do I need to do something in XI to have the messages in EOIO?

We are at SP14.

Pls suggest.

Thanks

Kalyan

Former Member
0 Kudos

Hi Kalyana,

On the XI side you'll need to:

1) XI - Write an adapter module to change the message's Quality of Service to EOIO and to set the EOIO Queue Name:

msg.setDeliverySemantics(DeliverySemantics.ExactlyOnceInOrder);

msg.setConversationId(queueName);

I get queueName from an adapter module parameter that I set in the communication channel.

2) Add the adapter module to the beginning of the module chain in your RFC Sender Communication Channel.

If you need more details about how to create an adapter module, see the document 'Step by step guide to develop a

module for reading file name in a

sender file adapter' which is found under 'XI Code Samples' on the main XI SDN page.

If you would like a copy of the code I used, please leave your email address.

Thanks,

Jesse

Former Member
0 Kudos

Jesse,

Thats a great help!!!

Please send your code to kveerapaneni@gmail.com.

Is this the same for Receiver HTTP adapter I am using also? Please clarify.

Thanks

Kalyan

Former Member
0 Kudos

Hi Kalyan,

I emailed out the code.

QoS is set in sender adapters only. It carries through to the receiver adapter only if the receiver adapter supports the specified QoS.

In your scenario, RFC -> File, if you set the QoS to EOIO in the RFC Sender adapter (using the module), it will carry through to the File Receiver adapter because the File Receiver adapter supports EOIO.

Thanks,

Jesse

Former Member
0 Kudos

jesse,

thanks for the last post. Little correction is that I am using http receiver adapter, not the file adapter. But your post did answer my question.

Thanks

Kalyan

Former Member
0 Kudos

Hello J and Kalyana,

If some off you have the code rows I happy to receive it.

I looking for adapter module that make the RFC sender EOIO

Thank you

Elad

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

A very interesting thread.

But , Instead of setting the QOS as EOIO in the module another alternative would have been to select the <b>Maintain Order at RunTime</b> in the Interface determination.

This would have ensured that the messages receievd Sequentially from R3 will also reach XI sequentially and when XI processes it will also process it sequentially.

But, the concept of changing the QOS inside the Module is also interesing and it would be very helpful if you can post a blog on this ( inclduing how to call the RFC the ABAP report in EOIO ).

Regards

Bhavesh

Former Member
0 Kudos

Hi,

The problem with parameter "Maintain Order at Runtime" in the Interface Deter. is, that you have to ensure, that the messages were already in the right order in the Adapter Framework.

The problem is, that the RFC adapter does not support (in the standard) EOIO. Even throuhg the RFCs are send out by qRFC. Who ensures that the messages will arrive in the right order in the Pipeline of the Integration Server?

The parameter "Maintain Order at Runtime" is only an option if you send multiple Intefaces to one receiver. If you have only one intercace to one receiver and you selevct this parameter no EOIO Queues are created in the pipeline.

The option with the module might me a good solution.

regards,

michele

Former Member
0 Kudos

Can you please post this Code?

Regards

Former Member
0 Kudos

Hi Jesse,

Send me code to

doppalapudi.nagaraju@gmail.com

former_member192851
Active Participant
0 Kudos

thanks.

It Works:

msg.setDeliverySemantics(DeliverySemantics.ExactlyOnceInOrder);

msg.setSequenceId(QueueName);;

Answers (2)

Answers (2)

former_member185846
Active Participant
0 Kudos

Hi All,

Could any of you send me that module's source code?.. My mail ID is <b>its.joe.s@gmail.com</b>

Thanks in advance.

Rgds,

Joe.

Former Member
0 Kudos

I understand that this can be done on the sender adapter, but can we do the same on the receiver File adapter?

Best Regards,

Duke

Former Member
0 Kudos

Could you please post the code of the adapter module

Regards

henrique_pinto
Active Contributor
0 Kudos

Hey J Wolff,

could I get that module's source code?

Thanks and regards,

Henrique.