cancel
Showing results for 
Search instead for 
Did you mean: 

SAP => XI => WebService synchronous communication and SPROXY

former_member737583
Participant
0 Kudos

I've *.wsdl which is describing my WebService (rpc style). I've imported it into XI (I see it in Exported Definision). I've definined also an message interface using imported entries form *.wsdl for defining input and output messages. So far, so good. Next after activation I've created PROXY using SPROXY. But when I try to run test I'm not able to receive right response from my WebService. I though that is a problem of original *.wsdl definition but it is not. I'm able to get right response form WebService using Altova XML Spy. So problems seems to be on XI or SPROXY side.

Any ideas what should I do?

Below you will find a original *.wsdl file (it is not *.wsdl file generated by XI!)


<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2008 sp1 (http://www.altova.com)>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://new.webservice.namespace" xmlns:ns="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" targetNamespace="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl">
	<wsdl:types>
		<xs:schema targetNamespace="http://new.webservice.namespace" elementFormDefault="qualified"/>
	</wsdl:types>
	<wsdl:message name="Sd2Ids_SzfExport">
		<wsdl:part name="arg1" type="xs:string"/>
		<wsdl:part name="arg2" type="xs:string"/>
	</wsdl:message>
	<wsdl:message name="Result">
		<wsdl:part name="Function" type="xs:string"/>
		<wsdl:part name="r" type="xs:string"/>
	</wsdl:message>
	<wsdl:portType name="SD2Port">
		<wsdl:operation name="Sd2Ids_SzfExport">
			<wsdl:input message="ns:Sd2Ids_SzfExport"/>
			<wsdl:output message="ns:Result"/>
		</wsdl:operation>
	</wsdl:portType>
	<wsdl:binding name="SD2binding" type="ns:SD2Port">
		<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
		<wsdl:operation name="Sd2Ids_SzfExport">
			<soap:operation soapAction="urn:Sd2Ids_SzfExport"/>
			<wsdl:input>
				<soap:body use="encoded" namespace="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl"/>
			</wsdl:input>
			<wsdl:output>
				<soap:body use="encoded" namespace="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl"/>
			</wsdl:output>
		</wsdl:operation>
	</wsdl:binding>
	<wsdl:service name="SD2Service">
		<wsdl:port name="SD2Service" binding="ns:SD2binding">
			<soap:address location="http://localhost:56791/"/>
		</wsdl:port>
	</wsdl:service>
</wsdl:definitions>

I'm guessing that problem is with soap:address, because of localhost definition (but my server is really running on my localhost). I'm not sure where I can pass information to XI to use those localhost adress and port.

I will reward all helping answers with points

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member737583
Participant
0 Kudos

First of all some small parts of XI sender and receiver configuration were missing. Second thing was a problem which was related with connection which I solved thanks to tips from other topic.

sumesh_k2
Participant
0 Kudos

HI,

So scenario you are working on is Synchronous Outbound proxy -> web service..

please check the following

1. You have created the outbound proxy and filled in all required mandatory parameters in request of webservice.

2. You need to define a receiver soap adapter with URL and logon credentials to the web service.

sumesh_k2
Participant
0 Kudos

Hi,

Please explain entire scenario you are exactly looking at.

If you need to call a websevice then you can use SOAP adapter and the URL mentioned in the original wsdl needs to specified in the receiver soap adapter.

former_member737583
Participant
0 Kudos

I've installed on my laptop an application which is running as a WebService. From SAP via SPROXY I'm sending request to XI and XI to WebService. Communication is synchronous. I've an WSDL file which is describing interface of WebService.

What I've already done:

- I've imported to XI WSDL file

- I've created Message Interface (Inbound, Synchronous) with Import and Export Messages form imported *.wsdl

- in transacion SPROXY I've created proxy

- when I'm checking proxy I got error message which I posted one post before

prateek
Active Contributor
0 Kudos

In the address section, use the IP address of the machine where the webservice is hosted

Regards,

Prateek

former_member737583
Participant
0 Kudos

What do you meen saying "in the address section". In imported *.wsdl file? Second thing. When I'm comparing original *.wsdl file and *.wsdl file which I can preview from SPROXY transaction I see some differences. A specially I do not see in *.wsdl file from SPROXY any information about soap:adress. Any idea why?

*.wsdl from SPROXY


  <?xml version="1.0" encoding="utf-8" ?> 
- <wsdl:definitions name="Sd2Ids_SzfExport" targetNamespace="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" xmlns:p1="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
- <wsdl:types>
- <xsd:schema targetNamespace="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" xmlns="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <xsd:element name="Result" type="Result" xmlns="" /> 
  <xsd:element name="Sd2Ids_SzfExport" type="Sd2Ids_SzfExport" xmlns="" /> 
  </xsd:schema>
- <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <xsd:complexType name="Sd2Ids_SzfExport">
- <xsd:sequence>
  <xsd:element name="arg1" type="xsd:string" /> 
  <xsd:element name="arg2" type="xsd:string" /> 
  </xsd:sequence>
  </xsd:complexType>
- <xsd:complexType name="Result">
- <xsd:sequence>
  <xsd:element name="Function" type="xsd:string" /> 
  <xsd:element name="r" type="xsd:string" /> 
  </xsd:sequence>
  </xsd:complexType>
  </xsd:schema>
  </wsdl:types>
- <wsdl:message name="p1.Sd2Ids_SzfExport">
  <wsdl:part name="Sd2Ids_SzfExport" type="Sd2Ids_SzfExport" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" /> 
  </wsdl:message>
- <wsdl:message name="p1.Result">
  <wsdl:part name="Result" type="Result" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" /> 
  </wsdl:message>
- <wsdl:portType name="Sd2Ids_SzfExport">
- <wsdl:operation name="Sd2Ids_SzfExport">
  <wsdl:input message="p1:p1.Sd2Ids_SzfExport" /> 
  <wsdl:output message="p1:p1.Result" /> 
  </wsdl:operation>
  </wsdl:portType>
- <ifr:properties xmlns:ifr="urn:com-sap:ifr:v2:wsdl">
  <ifr:category>ifmmessif</ifr:category> 
- <ifr:methods>
- <ifr:method name="Sd2Ids_SzfExport">
  <ifr:isSynchron>true</ifr:isSynchron> 
  <ifr:isInbound>true</ifr:isInbound> 
  <ifr:interfaceCategory>inbound</ifr:interfaceCategory> 
  </ifr:method>
  </ifr:methods>
- <ifr:messages>
- <ifr:message name="p1.Sd2Ids_SzfExport">
  <ifr:messType>ifmextmes</ifr:messType> 
  <ifr:technicalNamespace><a href="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" TARGET="test_blank">http://www.dat.de/sdii/ids/Sd2SOAP.wsdl</a></ifr:technicalNamespace> 
  </ifr:message>
- <ifr:message name="p1.Result">
  <ifr:messType>ifmextmes</ifr:messType> 
  <ifr:technicalNamespace><a href="http://www.dat.de/sdii/ids/Sd2SOAP.wsdl" TARGET="test_blank">http://www.dat.de/sdii/ids/Sd2SOAP.wsdl</a></ifr:technicalNamespace> 
  </ifr:message>
  </ifr:messages>
  </ifr:properties>
  </wsdl:definitions>

prateek
Active Contributor
0 Kudos

What do you meen saying "in the address section". In imported *.wsdl file?

Yes. Change it manually and reimport it

I do not see in *.wsdl file from SPROXY any information about soap:adress. Any idea why?

That information is retrieved from the Soap communication channel at runtime. So should not worry about that

Regards,

Prateek

former_member737583
Participant
0 Kudos

I didn't define any communication chanel (and no communication channel were created during *.wsdl import - I think it shouldn't to be created automatically).

Second think which makes me unhappy is a message which I got from SPROXY when I checked Message Inboud Interface in SPROXY.

I got an error message


Proxy generation internal error: Object <type> Result Sd2Ids_SzfExport(http://www.dat.de/ not found

But the strangest thing is when I run test I do not get any error message (additional thing is that I do not get response to).

prateek
Active Contributor
0 Kudos

I didn't define any communication chanel

U have to create the SOAP receiver communication channel manually. This will be utilized at runtime to call the webservice

message which I got from SPROXY when I checked Message Inboud Interface in SPROXY

In SPROXY, u should only concentrate on the Outbound message interface bcoz ur scenario has SAP R3 sender.

Regards,

Prateek