cancel
Showing results for 
Search instead for 
Did you mean: 

Using inbound service to produce data for outbound interface

Former Member
0 Kudos

Hi,

with SAP Enterprise services, we have lots of functionnality provided by SAP which we can use to easily get information

without having too much custom development done in the backend.

In our cas for example, we want to use an erecruiting enterprise service to extract data and send it to an external provider in an xml file.

here are the constraints

1) Reduce development as much as possible

2) Use PI to interface with external systems.

3) External system canot initiate the process.

It would be nice to reuse SAP content (Enterprise services) in order to extract the data and replicate it to the external system.

One way to do this would be to have a program which calls the method of the proxy that implements the enterprise service.

Then the program can just call PI to create a file with the contents returned by the method.

This is not an elegant solution ... , I would have liked PI to initiate the call at a specific time and with the response of the call send the xml file to the provider... this seems to be the reverse of what PI does...

I'm sure there are other solutions... any ideas ?

This is more of an extract and transfer scenario with PI...

Thanks.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Thierry,

The best thing would be extract at the specified time in the source system only and then send to pi and further. The other way round is not worth is my suggestion.

Regards,

---Satish

VijayKonam
Active Contributor
0 Kudos

Being said that initiating from PI is not a good solution, if you still want to do it from PI, this is one way of doing it (not really suggested though).

Create a file to RFC async interface. This RFC should should call the HR enterprise service (believe it is also asynchronous). This would trigger the 2nd async scenario in PI and create your XML file and send it to the 3rd party. Now coming to the scheduling part - have a dummy file with literally one field or so and keep the adapter in test mode (not to delete or archive the file). Schdule the adapter timing to run at a peirod that you want. Everytime, it would find the file, call the RFC, RFC would intern invoke the ES and the XML file is generated.

VJ

Answers (6)

Answers (6)

Former Member
0 Kudos

Hi,

1) Reduce development as much as possible-If you do enhancements and workarounds ,

effort may increase due to copying of ES/one to one mappings etc..

2) Use PI to interface with external systems-I agree that always PI should interact with

external system for security reasons but Eenterprise Services approach is best suited

for connecting using SOAMANAGER which reduces the effort drasticaly,you just need to

create endpoints.Try if you enable security features using SOAMANAGER approach

,instead of using PI. This will definitely help you for Point 1 above.

3) External system canot initiate the process- We should ask them to trigger,as they are

the consumers. or if they can'nt , easy way is to copy the ES service , make the SI as outbound

. In backend reuse the standard code (copy ) for outbound proxy. create a report which triggers

the proxy at specified intervals.Create a SAP(proxy asyn)- PI-(soap/file) enternal partry ,

Regards,

&rinivas

Former Member
0 Kudos

Hi Thierry,

we want to use an erecruiting enterprise service to extract data and send it to an external
 provider in an xml file

Please consider that the Auto generated proxies in Enterprise services are mostly Inbound( to SAP)

and have request and response structure.

When you are bringing PI into picture then you will need to create outbound structures, which you need

to copy.You will face issues with work around as suggested above , the proxies are not editable

and to make it editable you will end up creating a copy which will add more work then reuse.

Also think if the customer wants to enhance few field in the Req/Resp strucutures

(we need to consider this for sure)enhancing the structure is possible using dependencies

but it required costom changes.If you are expecting enhancements then better don't use enterprise services.

As SAP standard is designed to accept request and send response , its always correct to

request third party (consumer) to ask/trigger for data,unlike trying to put PI as triggering agent.

Conclusion:

Regards,

$rinivas

Edited by: Srinivas on Aug 12, 2010 7:27 AM

Edited by: Srinivas on Aug 12, 2010 7:37 AM

Former Member
0 Kudos

Thierry,

I would have liked PI to initiate the call at a specific time and with the response of the call send the xml file to the provider... this seems to be the reverse of what PI does...

Do scheduling in SAP R3, which will send the request via PI and in response of the call, send out XML file.

So, the design will be :-

SAP R3 (Scheduler proxy, async) -> PI -> WS / Proxy (request-response, sync) -> PI -> External provider (async).

We have implemented this approach for many web services scenarios where we want PI to initiate the call and where scheduling is not possible at the web service side.

I am assuming that you can do a synchronous call for request and response. If not, then still this should work for async, with little change in approach.

Hope this helps.

Regards,

Neetesh

Former Member
0 Kudos

Hi Babu,

to fetch data, you need to use a receiver cc right...

Also , scheduling the cc will not trigger the interface unless there's a way I don't know of...

In the runtime workbench , scheduling the cc availability dosn't really start the interface, it just makes the chanel available to be called...

Perhaps you could elaborate on how you would do this ?

Thanks.

Former Member
0 Kudos

Hi Thierry,

It's kind of defeating the purpose of a 'Service' or 'SOA' but I can understand that you don't want to re-invent the wheel so making use of out-of-the-box funtionality makes more sense.

I personally feel that the task is relatively easy but the scheduling should be done on the ECC side. So you create your custom program to initiate the method/operation of the Service that you need & pass it the parameters required & then pass on the result to XI/PI in a manner that suits you best (HTTP, RFC, File etc.) & then let PI do the relevant routing. Then you schedule your custom program to run at suitable intervals. If you choose file scenario then you'll need to have you sender file adapter polling at suitable intervals too. It's not as pretty as SOA but it will work ok.

Regards, Trevor

Former Member
0 Kudos

Hi,

I would have liked PI to initiate the call at a specific time and with the response of the call send the xml file to the provider

why cannot u schedule the sender CC, so that it will run periodically and fetch the data from source and transfer the same to

target...

Babu

former_member200962
Active Contributor
0 Kudos
I would have liked PI to initiate the call at a specific time and with the response of the call send the xml file to the provider

XI/ PI cannot initiate/ trigger an interface on its own......it has to get data from some sender and then only it will do the further processing.

To run the scenario at a specified time you can use Availability Time Planning....but even in this case the data has to come from some source.

Regards,

Abhishek.