on 11-01-2010 4:05 AM
Hi all,
I am trying to publish equipment information to multiple systems using ECC 6.0 and PI 7.1
Here are two articles which I have read which were very useful
http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/800e2826-718c-2a10-f680-d6b29f0dce18
http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/a0334534-aa28-2b10-a3a2-9ed4135727ed
High level overview of what I've done is as follows.
PI
- I developed a generic Service Interface called Asset_Sync and mapped this to a non SAP backend system to persist the equipment information (this all works fine).
- I also published the Sender Agreement for Asset_Sync to ESR
ECC 6.0
- I generated a client proxy ZEFI_CO_ASSET_SYNC from the ESR entry for Asset_Sync
- I used transaction SWF_BAM and have created an event linkage for object type EQUI event Changed
Here is where I am stuck
I now need to define the Proxy object to publish the equipment information to PI.
I am not sure if I have to extend the object EQUI to ZZEQUI and whether I need to create a method execute-synchronous.
I am really looking for some sample code of how to create the Proxy object and link it to the event.
Regards,
John
P.S.
I have coded a test program which calls the proxy and sends the information to PI and then to the third party system it looks as follows and works fine, it is just a shell right now once I have finished linking it to the event I will enhance the message interface and pass real values (for now my mapping in PI just hardcodes enough data so the publish to the back end system works). Basically althugh this works I need to execute this automatically from the event being triggered and hence need to move this into a proxy with event linkage.
FORM CREATE_ENTITLEMENT .
DATA: lv_assset_sync_req TYPE ZEFI_ASSET_SYNC_REQUEST,
lv_assset_sync_resp TYPE ZEFI_WSRESPONSE1.
CREATE OBJECT lv_asset_sync_proxy
EXPORTING
LOGICAL_PORT_NAME = 'ASSET_SYNC_DX3'.
*TRY.
*TRY.
CALL METHOD LV_ASSET_SYNC_PROXY->ASSET_SYNC
EXPORTING
OUTPUT = lv_assset_sync_req
IMPORTING
INPUT = lv_assset_sync_resp.
.
Write 😕 'Status : ', lv_assset_sync_resp-WSRESPONSE-STATUS.
WRite 😕 'Code : ', lv_assset_sync_resp-WSRESPONSE-CODE.
Marking this as answered as I have it working.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi all,
I thought I'd give an update.
After reading a number of articles and documentation (see below).
It appears it may be easier to create a new class using SE24 rather than extending the Business Object in SWO1.
I've done the following which works via a user-exit.
a. Create Class ZZEQUI
b. Create an Instance Dependent Object to Publish the Entitlement
c. Leverage User Exit MV50AFZ1 - FORM USEREXIT_SAVE_DOCUMENT_PREPARE
d. Created Include ZSDI_DELIVERY_PUBLISH
i. Loops through serial numbers
ii. Create Object LV_ASSET EXPORTING EQUNR = LV_EQUNR
iii. CALL LV_ASSET->Publish.
If I add the Interface IF_WORKFLOW to my class then I may be able to be trigger it from SWF_BAM.
The solution I have is working, if I decide to go with BAM and have additional questions I'll raise this in either the workflow or ABAP Objects forums.
Regards,
John
Addtional articles and documentation
i. Business Object Macros http://help.sap.com/saphelp_nw04/helpdata/en/c5/e4ad23453d11d189430000e829fbbd/frameset.htm
ii. Integrating Abap Objects with Workflow http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/b0409e6c-d213-2d10-3cb6-c12d417626c1
iii. Why Use ABAP OO with workflow /people/jocelyn.dart/blog/2006/06/19/why-use-abap-oo-with-workflow
iv. ABAPOO for WUG http://wiki.sdn.sap.com/wiki/display/HOME/2.Designand+Development#2.DesignandDevelopment-HowcanIuseABAPOOClassesinWorkflow%3F
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Anyone with any ideas they can offer??
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.