cancel
Showing results for 
Search instead for 
Did you mean: 

Java developer need help...

Former Member
0 Kudos

Hello people,

I am 100% new comer to SAP - and I only have intermediate task - to implement web services on SAP. I think I have found out how to create ws endpoint and I have found out how to create ws client - package->create->Enterprise service/Web Service->proxy object. Then I have fed my wsdl file and finally I have got fault. Here are my WSDL:

Code:

<?xml version="1.0" encoding="UTF-8"?>

<definitions name="MyTestService" targetNamespace="http://www.openuri.org/2008/05/HelloWorld" xmlns:tns="http://www.openuri.org/2008/05/HelloWorld" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns="http://schemas.xmlsoap.org/wsdl/">

<types>

<xs:schema targetNamespace="http://www.openuri.org/2008/05/HelloWorld" version="1.0" xmlns:tns="http://www.openuri.org/2008/05/HelloWorld" xmlns:xs="http://www.w3.org/2001/XMLSchema">

<xs:element name="MessageDeliverException" type="tns:MessageDeliverException"/>

<xs:element name="URISyntaxException" type="tns:URISyntaxException"/>

<xs:complexType name="URISyntaxException">

<xs:sequence>

<xs:element name="index" type="xs:int"/>

<xs:element minOccurs="0" name="input" type="xs:string"/>

<xs:element minOccurs="0" name="message" type="xs:string"/>

<xs:element minOccurs="0" name="reason" type="xs:string"/>

</xs:sequence>

</xs:complexType>

<xs:complexType name="MessageDeliverException">

<xs:sequence>

<xs:element minOccurs="0" name="message" type="xs:string"/>

</xs:sequence>

</xs:complexType>

</xs:schema>

</types>

<message name="WSTestBean_getEmployeeName">

<part name="id" type="xsd:string">

</part>

</message>

<message name="MessageDeliverException">

<part name="MessageDeliverException" element="tns:MessageDeliverException">

</part>

</message>

<message name="WSTestBean_getEmployeeNameResponse">

<part name="return" type="xsd:string">

</part>

</message>

<message name="URISyntaxException">

<part name="URISyntaxException" element="tns:URISyntaxException">

</part>

</message>

<portType name="WSTestBean">

<operation name="getEmployeeName" parameterOrder="id">

<input message="tns:WSTestBean_getEmployeeName">

</input>

<output message="tns:WSTestBean_getEmployeeNameResponse">

</output>

<fault name="MessageDeliverException" message="tns:MessageDeliverException">

</fault>

<fault name="URISyntaxException" message="tns:URISyntaxException">

</fault>

</operation>

</portType>

<binding name="WSTestBeanBinding" type="tns:WSTestBean">

<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>

<operation name="getEmployeeName">

<soap:operation soapAction=""/>

<input>

<soap:body use="literal" namespace="http://www.openuri.org/2008/05/HelloWorld"/>

</input>

<output>

<soap:body use="literal" namespace="http://www.openuri.org/2008/05/HelloWorld"/>

</output>

<fault name="MessageDeliverException">

<soap:fault name="MessageDeliverException" use="literal"/>

</fault>

<fault name="URISyntaxException">

<soap:fault name="URISyntaxException" use="literal"/>

</fault>

</operation>

</binding>

<service name="MyTestService">

<port name="WSTestBeanPort" binding="tns:WSTestBeanBinding">

<soap:address location="http://127.0.0.1:8080/WebServiceProject/WSTestBean"/>

</port>

</service>

</definitions>

and fault message:

Code:

Cannot generate proxy (object missing in WSDL, see long text)

Message no. SPRX084

Background

During proxy generation, an interface description in WSDL format is fetched from the Integration Builder or from another source and interpreted. This WSDL document must describe the whole interface correctly.

==> Display Query

==> Display WSDL Document

Diagnosis

In the WSDL document, the object

"<message name="WSTestBean_getEmployeeName"> <pa..."

from the namespace

"http://www.openuri.org/2008/05/HelloWorld"

links to the object

""

from the namespace

""

However, this last object does not exist in the WSDL document.

System Response

ABAP proxy generation expects that all directly and indirectly referenced objects are in the WSDL document. Therefore, no proxy can be generated for this WSDL and the system displays an error message.

Procedure

This situation can have different causes:

Object "" not been defined

Object "" saved in the wrong namespace

In the reference to object "", the wrong name was specified

In the reference to object "", the wrong namespace "" was specified

Internal error in the service that constructs the WSDL document

Internal error in ABAP proxy generation

I have SAP ECC 6.0 without NetWeaver (if I understand it rightly).

I appreciate any help. Thanx a lot.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

I appreciate your help, thanks. I have not still fixed my problem - could someone do me a favour and publish wsdl for SAP to compare with mine...

Thanks in advance.

Former Member
0 Kudos

Hi Andrey,

If you are looking for SAP delivered sample WSDLs, you can refer to ES workplace in SDN. Just dig deep there you can get familiar with the service interfaces and corresponding WSDLs.

Some of the schemas are not supported, as is the case with other applications (technologies).

If you have any questions, please do post.

Hope this helps,

- anto.

Former Member
0 Kudos

Hi again,

I have found this blog: /people/thomas.jung3/blog/2004/11/17/bsp-a-developers-journal-part-xiv--consuming-webservices-with-abap and the thread in the discussion after text with name missing object in WSDL. I am in the same situation - I have wsdl originally generated by JBoss. Is there any possibility to find out if this bug fixed or not...

Thanx a lot.

Former Member
0 Kudos

There is always chances that some XML shema elements are not supported, moreso for non-SAP system.

For technical reasons, proxy generation and the respective editors in the ES Builder do not support the entire language range of XML schema and WSDL. An overview of which language elements are supported is available in SAP Developer Network (SDN) at https://www.sdn.sap.com/irj/sdn ® SOA Middleware ® Repository-Based Modeling and Design. In the Knowledge Center on the Repository-Based Modeling and Design page, choose Enterprise Services Repository & Registry and on the subsequent page select the Supported XML Schema and WSDL document.

Please check at http://help.sap.com/saphelp_nwpi71/helpdata/en/26/9e97b0f525d743882936c2d6f375c7/frameset.htm.

Perhaps it doesnt support underscore here

<message name="WSTestBean_getEmployeeName">

Hope it helps.

- julius