on 03-07-2008 8:45 PM
Hi all,...................xMII 11.5.3 b66
I am attempting to consume a BLS transaction as a web service from a J2EE app.
When I test it with http://naholldo31020/Lighthammer/SOAPRunner/Amy/GetListOfPlants I am getting an error message from the browser. The BLS transaction works fine when called from a Query template. What am I missing?
The XML page cannot be displayed
Cannot view XML input using style sheet.
Please correct the error and then click the Refresh button, or try again later.
--------------------------------------------------------------------------------
XML document must have a top level element. Error processing
resource 'http://naholldo31020/Lighthammer/SOAPRunner/Amy/GetL...
-
WSDL from WSDLGen...
<?xml version="1.0" encoding="UTF-8" ?>
- <definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:s="http://www.w3.org/2001/XMLSchema"
xmlns:s0="http://www.sap.com/xMII"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" targetNamespace="http://www.sap.com/xMII">
- <!-- Types
-->
- <types>
- <s:schema elementFormDefault="qualified" targetNamespace="http://www.sap.com/xMII">
- <s:complexType name="InputParams">
- <s:sequence id="InputSequence">
<s:element maxOccurs="1" minOccurs="0" name="RequestXML" type="s:Xml" />
<s:element maxOccurs="1" minOccurs="0" name="RowCount" type="s:long" />
<s:element maxOccurs="1" minOccurs="0" name="RowSkips" type="s:long" />
<s:element maxOccurs="1" minOccurs="0" name="Table" type="s:string" />
</s:sequence>
</s:complexType>
- <s:element name="XacuteRequest">
- <s:complexType>
- <s:sequence>
<s:element maxOccurs="1" minOccurs="0" name="LoginName" type="s:string" />
<s:element maxOccurs="1" minOccurs="0" name="LoginPassword" type="s:string" />
<s:element maxOccurs="1" minOccurs="0" name="InputParams" type="s0:InputParams" />
</s:sequence>
</s:complexType>
</s:element>
- <s:complexType name="Rowset">
- <s:sequence>
<s:element maxOccurs="unbounded" minOccurs="0" name="Row" type="s0:Row" />
</s:sequence>
<s:attribute name="Message" type="s:string" />
</s:complexType>
- <s:complexType name="Row">
- <s:sequence id="RowSequence">
<s:element maxOccurs="1" minOccurs="1" name="ErrorMessage" type="s:string" />
<s:element maxOccurs="1" minOccurs="1" name="OutputXML" type="s:string" />
</s:sequence>
</s:complexType>
- <s:element name="XacuteResponse">
- <s:complexType>
- <s:sequence>
<s:element maxOccurs="1" minOccurs="0" name="Rowset" type="s0:Rowset" />
</s:sequence>
</s:complexType>
</s:element>
</s:schema>
</types>
- <!-- Messages
-->
- <message name="XacuteSoapIn">
<part element="s0:XacuteRequest" name="parameters" />
</message>
- <message name="XacuteSoapOut">
<part element="s0:XacuteResponse" name="parameters" />
</message>
- <!-- Ports
-->
- <portType name="XacuteWSSoap">
- <operation name="Xacute">
<input message="s0:XacuteSoapIn" />
<output message="s0:XacuteSoapOut" />
</operation>
</portType>
- <!-- Bindings
-->
- <binding name="XacuteWSSoap" type="s0:XacuteWSSoap">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" />
- <operation name="Xacute">
<soap:operation soapAction="http://www.sap.com/xMII" style="document" />
- <input>
<soap:body use="literal" />
</input>
- <output>
<soap:body use="literal" />
</output>
</operation>
</binding>
- <!-- Service mapping
-->
- <service name="XacuteWS">
- <port binding="s0:XacuteWSSoap" name="XacuteWSSoap">
<soap:address location="http://naholldo31020/Lighthammer/SOAPRunner/Amy/GetListOfPlants" />
</port>
</service>
</definitions>
Hi Amy,
here is an example how you can call a WS via http GET:
Please note you do not need to use credentials in case you calling localhost.
I think in your case this should be the right url:
Please change parameters for
- XacuteLoginName
- XacuteLoginPassword
- outputparameter (you can specify * or one of your transaction output parameter)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello, Ottavio.
While that URL technique does indeed invoke the same BLS transaction, it uses a somewhat different mechanism to do so (not SOAP-based).
Personally, I think the "Runner" mechanism is optimal, as it allows maximum flexibility in output data structures, output content types, and is generally much higher performance (one less layer to deal with).
However, many client applications can only consume SOAP-style web services.
Rick
You can't (generally) test SOAP services directly from a browser. Otherwise, you won't be "posting" the appropriate XML SOAP input message to the service.
Rick
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
11 | |
6 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.