cancel
Showing results for 
Search instead for 
Did you mean: 

WSDL Import for External Definiton

Former Member
0 Kudos

Hi,

I'm trying to import a wsdl document in order to create an external definition for a WS I am wishing to envoke from XI.

However I get the following error:

Cause: Unable to recognize the loaded document as valid WSDL The value "xsd:schema" is not permitted for the attribute "ref" of the "QName" type in the "/schema/element("Browse_DataSetResponse")/complexType/sequence/element("Browse_DataSetResult")/complexType/sequence/element("http://www.w3.org/2001/XMLSchema:schema")" element

followed by more errors relating to the value xsd:schema being used.

However I have successfully used this wsdl before and it is from a commercial service so syntactically should be correct.

Can anybody help please.

Thanks in advance

John

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi John,

We too faced a similar situation and we did a work around.

XI is having problems to import WSDLs which contains the line:

<i> <s:element <b>ref="s:schema"</b> /></i>

We have replaced "s:schema" with "s:string" and the import worked fine. Activated too. I dont think we can do like that, but our operation do not refer to any messages which has this declaration - so it was no issue.

In your case too, 'ByPostCode' function uses Messages which do not have this declaration. Only operations with 'DataSet' uses this.

As a workaround, you could do the same and definitely it works. I tested on SP12 with your WSDL for this workaround and it is activated.

regards,

Pops V

Answers (4)

Answers (4)

STALANKI
Active Contributor
0 Kudos

Iam on support pack 12 but successfully loaded the wsdl.

Former Member
0 Kudos

Thanks Sravya,

Unfortunately my system is down at the moment so I can't check.

I could load the wsdl ok but when it came to activating I got the error, have you successfully activated?

Thanks

John

Former Member
0 Kudos

Hi John,

you are right. This is indeed an error. It will be fixed in one of the next SPs.

Greetings Stephan

STALANKI
Active Contributor
0 Kudos

The problem is not with the support pack.Please check the category in the external definition as "WSDL".

Former Member
0 Kudos

Hi John,

could you post a link to the WSDL file in question. This might be helpful when trying to find out what the problem is.

Greetings Stephan

Former Member
0 Kudos

Hi,

Here is a link to the WSDL in question

http://services.postcodeanywhere.co.uk/uk/lookup.asmx?WSDL

I would like to call the BYPOSTCODE function.

Thanks in advance

John

Former Member
0 Kudos

Hi John,

I imported the WSDL into an SP13 repository and it works fine. On the Message-tab I see a whole bunch of Messages (e.g. ByPostcodeSoapOut).

However, I recognized that this document uses the soapenc:Array. This is not supported by the Integration Repository. Hence, when using the External Message (e.g. in the Mapping Tool) you may possibly see a 'truncated' message.

See also http://www.ws-i.org/Profiles/BasicProfile-1.0-2004-04-16.html#refinement16556272 for best practices in (not) using soapenc:Array.

Greetings Stephan

Former Member
0 Kudos

Thanks Stephan,

I'm on SP12 so will upgrade to SP13 and retry.

Thanks very much for your help

John

Former Member
0 Kudos

Hi Jhon,

There are two ways of defining an XSD (or WSDL). Depending the complexity, while importing an WSDL file, XI will not recognise the file as valid and throws errors. It might look a vague answer, but true, because I have faced similar problem in the past. There is a work around as follows. From your description I could understand, your WSDL is equivalent to File 1. Redefine your WSDL so that it doesn't contain any refernce types.

The File 1 & 2 below defines the same XML content but they way do is different. The first one uses a 'Type and Refence Linkage' where as the second one uses 'Direct Linkage'. Redefine your file as in 2 and import, it would work.

File 1:

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

<xsd:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">

<xsd:element name="Root">

<xsd:complexType>

<xsd:sequence>

<xsd:element name="Child" maxOccurs="unbounded">

<xsd:complexType>

<xsd:sequence>

<xsd:attribute name="Name" type="xsd:string"/>

<xsd:attribute name="Mobile" type="xsd:string"/>

</xsd:sequence>

</xsd:complexType>

</xsd:element>

</xsd:sequence>

</xsd:complexType>

</xsd:elemet>

</xsd:schema>

File 2:

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

<xsd:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">

<xsd:element name="Root">

<xsd:complexType>

<xsd:sequence>

<xsd:element name="Child" type="Type" maxOccurs="unbounded"/>

</xsd:sequence>

</xsd:complexType>

</xsd:element>

<xsd:complexType name="Type">

<xsd:attribute name="Name" type="xs:string"/>

<xsd:attribute name="Mobile" type="xs:string"/>

</xsd:complexType >

</xsd:schema>

Hope it would help you.

Regards, Sreenivas.