on 04-06-2011 4:42 AM
Hi,
I'm going to consume SAP PI with third party webservice because i've scenarioo which there are changes data in a program in SAP, i need to send the data to the third party application using their webservice.
SAP --> PI --> third-party webservice -->third party APP.
It is helpful if there any tutorial / on-line revision regarding this topic. tq.
Hi,
Please check with SAP Note : 1235267
Hope this helps to you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Basically you need to setup scenario from SAP to Webservice via PI. On the sender side you can use Proxy or Idoc or whatever your requirement. On the receiver side use SOAP Receiver Adapter.
Following tips:
Import third party WSDL as external definition in the ESR or Integration repository. You dont need to create data types for target side. you just use WSDL messages as external type.
Create Data type for sender. Message type for sender, Message type for receiver(pull the external definition message here).
Create standard sender and receiver interface.
Mapping your sender to target WSDL message.
Operation mapping: Use sender interface as source and receiver interface as target.
Pretty much same procedure.
In Integration directory:
same procedure.
Receiver adapter: Soap communication channel
Target URL: specify wsdl url. you can find it inside the wsdl itself. search for soap: address location.
Soap Action: if you dont see in the WSDL. Leave as blank.
Before tesing, import web service WSDL in SOAPUI or XMLSPY and test the webservice. Also find out WSDL URL and use that URL in the soap reciever adapter cc.
Refer these links
http://www.riyaz.net/blog/xipi-a-guide-to-using-sap-xi-soap-adapter/technology/sap/113/
http://help.sap.com/saphelp_nw04/helpdata/en/29/5bd93f130f9215e10000000a155106/content.htm
>>Do you mean i need to set at SAP PI Integration Directory. under Business Service, configured as Receiver SOAP adapter?
Yes.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi Baskar Gopal,
i manage to mport third party WSDL as external definition in the ESR or Integration repository. but i faced error on Mapping sender to the external WSDL and error msg "java.lang.NullPointerException"
#8 16:59:36 [AWT-EventQueue-0] ERROR com.sap.aii.utilxi.swing.toolkit.ExceptionDialog: Throwable
Thrown:
MESSAGE ID: com.sap.aii.utilxi.misc.api.BaseException
com.sap.aii.utilxi.misc.api.BaseException: java.lang.NullPointerException
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdSchemaTextable.setSchema(XsdSchemaTextable.java:86)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.setSchema(XsdContainerTextView.java:46)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.<init>(XsdContainerTextView.java:36)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.makeFromTreeDoc(MultiViewEditor.java:216)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.<init>(MultiViewEditor.java:64)
at com.sap.aii.mappingtool.mf.TransformationPanel.createTargetView(TransformationPanel.java:264)
at com.sap.aii.mappingtool.mf.TransformationPanel.<init>(TransformationPanel.java:100)
at com.sap.aii.mappingtool.mf.MappingTool.<init>(MappingTool.java:32)
at com.sap.aii.mappingtool.api.MappingToolFactory.getInstance(MappingToolFactory.java:96)
at com.sap.aii.mappingtool.fwutil.util.ToolUtil.restartTool(ToolUtil.java:315)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView.loadIfrSchema(XiTransformationView.java:274)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiMappingView.searchForRepositoryObject(XiMappingView.java:260)
at com.sap.aii.ibrep.gui.mapping.xitrafo.RepObjSearchHelpAction.actionPerformed(RepObjSearchHelpAction.java:90)
at com.sap.aii.utilxi.swing.framework.mtaction.MTActionGroup.actionPerformed(MTActionGroup.java:44)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.performDefaultAction(IBToolButton.java:326)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.fire(IBToolButton.java:220)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.access$200(IBToolButton.java:49)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton$4.actionPerformed(IBToolButton.java:340)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Root cause:
java.lang.NullPointerException: null
at com.sap.aii.utilxi.xsd.api.XsdHandler.saveSchemaToDocument(XsdHandler.java:61)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdSchemaTextable.setSchema(XsdSchemaTextable.java:82)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.setSchema(XsdContainerTextView.java:46)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.<init>(XsdContainerTextView.java:36)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.makeFromTreeDoc(MultiViewEditor.java:216)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.<init>(MultiViewEditor.java:64)
at com.sap.aii.mappingtool.mf.TransformationPanel.createTargetView(TransformationPanel.java:264)
at com.sap.aii.mappingtool.mf.TransformationPanel.<init>(TransformationPanel.java:100)
at com.sap.aii.mappingtool.mf.MappingTool.<init>(MappingTool.java:32)
at com.sap.aii.mappingtool.api.MappingToolFactory.getInstance(MappingToolFactory.java:96)
at com.sap.aii.mappingtool.fwutil.util.ToolUtil.restartTool(ToolUtil.java:315)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView.loadIfrSchema(XiTransformationView.java:274)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiMappingView.searchForRepositoryObject(XiMappingView.java:260)
at com.sap.aii.ibrep.gui.mapping.xitrafo.RepObjSearchHelpAction.actionPerformed(RepObjSearchHelpAction.java:90)
at com.sap.aii.utilxi.swing.framework.mtaction.MTActionGroup.actionPerformed(MTActionGroup.java:44)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.performDefaultAction(IBToolButton.java:326)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.fire(IBToolButton.java:220)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.access$200(IBToolButton.java:49)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton$4.actionPerformed(IBToolButton.java:340)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
#7 16:59:36 [AWT-EventQueue-0] FINE AutoLog.created.com.sap.aii.utilxi.misc.api.BaseException: com.sap.aii.utilxi.misc.api.BaseException: java.lang.NullPointerException
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdSchemaTextable.setSchema(XsdSchemaTextable.java:86)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.setSchema(XsdContainerTextView.java:46)
at com.sap.aii.ib.gui.xmleditor.docview.views.XsdContainerTextView.<init>(XsdContainerTextView.java:36)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.makeFromTreeDoc(MultiViewEditor.java:216)
at com.sap.aii.ib.gui.xmleditor.docview.MultiViewEditor.<init>(MultiViewEditor.java:64)
at com.sap.aii.mappingtool.mf.TransformationPanel.createTargetView(TransformationPanel.java:264)
at com.sap.aii.mappingtool.mf.TransformationPanel.<init>(TransformationPanel.java:100)
at com.sap.aii.mappingtool.mf.MappingTool.<init>(MappingTool.java:32)
at com.sap.aii.mappingtool.api.MappingToolFactory.getInstance(MappingToolFactory.java:96)
at com.sap.aii.mappingtool.fwutil.util.ToolUtil.restartTool(ToolUtil.java:315)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiTransformationView.loadIfrSchema(XiTransformationView.java:274)
at com.sap.aii.ibrep.gui.mapping.xitrafo.XiMappingView.searchForRepositoryObject(XiMappingView.java:260)
at com.sap.aii.ibrep.gui.mapping.xitrafo.RepObjSearchHelpAction.actionPerformed(RepObjSearchHelpAction.java:90)
at com.sap.aii.utilxi.swing.framework.mtaction.MTActionGroup.actionPerformed(MTActionGroup.java:44)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.performDefaultAction(IBToolButton.java:326)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.fire(IBToolButton.java:220)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton.access$200(IBToolButton.java:49)
at com.sap.aii.utilxi.swing.framework.mtaction.IBToolButton$4.actionPerformed(IBToolButton.java:340)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
:
:
:
#2 16:54:05 [
#0 16:54:04 [AWT-EventQueue-0] DEBUG AutoLog.created.com.sap.aii.ib.core.service.TypeNotRegisteredException: Type "versConflList" is not registered in service class Type Service - Type Information
Edited by: firdaus hashim on Apr 29, 2011 10:22 AM
Your errors tells me that you are running issue in the mapping side. Your mesg not even reaching the third party. Basically you are accessing field which has no value found. Thats why you get Null Pointer Exception. Go through your source and target structure and see your mapping fields one after another and check the values you are passing. Also try to test the same values in message mapping screen .
hi Baskar Gopal,
tq for ur quick reply, attached is the screen shot of my situasion:
here are the screen shot for the:
1) [External Definition|http://3.bp.blogspot.com/-NMpn0cH_4Xg/Tb9kJwqsPTI/AAAAAAAABrc/QckdtYudCzY/s1600/externaldef.JPG]
2)[Mapping Objects|http://4.bp.blogspot.com/-KjWXHDqdGH0/Tb9kJQvFzeI/AAAAAAAABrY/iucV4RBjhJo/s1600/mappingObjects.JPG]
from the screen shot, it there any problem if in External Definition the WSDL have External References? for ur information this WSDL is from out vendor, i just compared with our previous project the WSL do not have the external references. tq.
Hii Baskar Gopal,
i'm testing the webservice located at public host outside.
URL: [http://aspspider.ws/bitsoftware/TestService.svc|http://aspspider.ws/bitsoftware/TestService.svc]
WSDL: [http://aspspider.ws/bitsoftware/TestService.svc?wsdl|http://aspspider.ws/bitsoftware/TestService.svc?wsdl]
Below is the details of the service.
Using Soap version: 1.1
URI for the WSDL: http://aspspider.ws/bitsoftware/TestService.svc?wsdl
Envelope sample:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header>
<Action s:mustUnderstand="1"
xmlns="http://schemas.microsoft.com/ws/2005/05/addressing/none">http://tempuri.org/ITestService/NotifyETenaga</Action>
</s:Header>
<s:Body>
<NotifyETenaga xmlns="http://tempuri.org/">
<NotifyMessage>New Document Updated</NotifyMessage>
</NotifyETenaga>
</s:Body>
</s:Envelope>
Response Envelope sample:
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Header />
<s:Body>
<NotifyETenagaResponse xmlns="http://tempuri.org/">
<NotifyETenagaResult>Notify Received: New Document Updated</NotifyETenagaResult>
</NotifyETenagaResponse>
</s:Body>
</s:Envelope>
the expected result shoud be creating the abap program from Abap Proxy and manage to input and get respond from the abap screen. what i have done was:
PI Respository
1) Data type for sender & receiver. Message type for sender & receiver ,
2) sender interface (sender& receiver) and receiver interface(for external definition).
3) Mapping sender & receiver to external definition WSDL message.
4) mapping: Use sender interface as source and receiver interface as target with externel definition.
PI Directory
1) Receiver adapter: Soap communication channel. target URL: http://aspspider.ws/bitsoftware/TestService.svc
soap action : http://tempuri.org/ITestService/NotifyETenaga
activate the abap proxy. but i failed with this error:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
- <!-- Inbound Message
-->
- <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
<SAP:Category>XIAdapterFramework</SAP:Category>
<SAP:Code area="MESSAGE">GENERAL</SAP:Code>
<SAP:P1 />
<SAP:P2 />
<SAP:P3 />
<SAP:P4 />
<SAP:AdditionalText>com.sap.aii.af.ra.ms.api.DeliveryException: aspspider.ws</SAP:AdditionalText>
<SAP:ApplicationFaultMessage namespace="" />
<SAP:Stack />
<SAP:Retry>M</SAP:Retry>
</SAP:Error>
Hi Firdaus,
This is a link to a step by step guide that could be useful for you:
Regards,
José Raúl López
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi José Raúl López,
i think the tutorial link you given the webservice is from SAP and the purpose is to Interface ABAP Web Service to Web Service communication using SAP PI.
RFC-->Abap Webservice-->create WSDL--> import WSDL into SAP PI
my previous exprience, i usually directly import the RFC into SAP PI instead created the RFC I)
SAP --rfc--> SAP PI --soap communication--> Third-party
what i'm looking for is to used third-party webservice to consume with SAP PI. anyway tq for your reply.
Yes you can... use SOAP receiver Adapter..
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.