Hi,
can anyone shed some light on an issue I have encountered. I have used a
tool (Cape Clear) to generate a WSDL file for me. When I use the WSDL2Java
tool provided by apache axis it creates proxies without any issues. When I
use WSDL.exe I get the following:
E:\XML\Schemas\Cape Clear>wsdl /server myEmployeeService.wsdl
Microsoft (R) Web Services Description Language Utility
[Microsoft (R) .NET Framework, Version 1.1.4322.573]
Copyright (C) Microsoft Corporation 1998-2002. All rights reserved.
Error: Unable to import binding 'PortType1Binding' from namespace
'http://com.tony.wsdl.testing/CClear.wsdl'.
- Unable to import operation 'SubmitEmployeeOperation'.
- Specified cast is not valid.
If you would like more help, please type "wsdl /?".
I cannot see anything obvious in the WSDL. Any help greatly appreciated.
WSDL below:
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions
name="SimpleEmployee"
targetNamespace="http://com.tony.wsdl.testing/CClear.wsdl"
xmlns:import1="http://MyFirstMessaging.employee"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://com.tony.wsdl.testing/CClear.wsdl"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:documentation
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Created using Cape Clear
Studio SOA Editor - http://www.capeclear.com</wsdl:documentation>
<wsdl:types>
<xs:schema
targetNamespace="http://MyFirstMessaging.employee"
xmlns="http://MyFirstMessaging.employee"
xmlns:b="http://schemas.microsoft.com/BizTalk/2003"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="Employee">
<xs:annotation>
<xs:appinfo>
<b:properties>
<b:property
distinguished="true"
xpath="/*[local-name()='Employee' and
namespace-uri()='http://MyFirstMessaging.employee']/@*[local-name()='Grade']
"/>
</b:properties>
</xs:appinfo>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element name="Name">
<xs:complexType>
<xs:sequence>
<xs:element name="First"
type="xs:string"/>
<xs:element name="Middle"
type="xs:string"/>
<xs:element name="Last"
type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="Personal">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="SSN"
nillable="true" type="xs:string"/>
<xs:element name="DOB"
type="xs:string"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute name="Grade" type="xs:positiveInteger"
use="required"/>
</xs:complexType>
</xs:element>
</xs:schema>
</wsdl:types>
<wsdl:message name="SubmitEmployeeResponse">
<wsdl:part name="empResponse" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="SubmitEmployee">
<wsdl:documentation
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Employee Submission
Mechanism</wsdl:documentation>
<wsdl:part element="import1:Employee" name="p_Emp"/>
</wsdl:message>
<wsdl:portType name="EmployeePort">
<wsdl:operation name="SubmitEmployeeOperation">
<wsdl:input message="tns:SubmitEmployee"/>
<wsdl:output message="tns:SubmitEmployeeResponse"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="PortType1Binding" type="tns:EmployeePort">
<soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="SubmitEmployeeOperation">
<soap:operation
soapAction="capeconnect::EmployeePort#SubmitEmploy eeOperation"
style="document"/>
<wsdl:input>
<soap:body parts="p_Emp" use="literal"/>
</wsdl:input>
<wsdl:output>
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="MyEmployeeService">
<wsdl:port binding="tns:PortType1Binding" name="Port1">
<soap:address
location="http://localhost:8000/ccx/MyEmployeeService"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>