Thanks for the prompt reply.
I'm using Axis2 Eclipse Codegen plugin for creating a web service from a
WSDL.
Initially, I tried to create server side components. So, this is what I did:
Step 1: File -> New -> Other ->Axis2 Wizards -> Axis2 Code Generator.
Clicked Next.
Step 2: Selected "Generate Java source code from a WSDL file". Clicked Next.
Step 3: Selected the WSDL file location and clicked Next.
Step 4: Selected "Codegen Option" as "custom" and selected the checkbox
"Generate server side code" and "Generate a default services.xml". Clicked
Next.
Step 5: Selected the radio option "Browse and select a project on current
eclipse workspace" and specified the project. I even selected the checkbox
"Add the Axis2 codegen jars to the codegen resulted project".
Step 6: Clicked Finish. Not a happy ending. It threw me an
InterruptedException.
Here is the WSDL that I used to generate the java code:
The <part> element inside <message> seems to be the culprit. When I comment
both the request and response <part> elements I won't get any error.
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions targetNamespace="urn:login.safe.two.us"
xmlns:apachesoap="http://xml.apache.org/xml-soap"
xmlns:impl="urn:login.safe.two.us"
xmlns:intf="urn:login.safe.two.us"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:types>
<schema elementFormDefault="qualified"
targetNamespace="urn:login.safe.two.us"
xmlns="http://www.w3.org/2001/XMLSchema">
<complexType name="TestLoginType">
<sequence>
<element name="eid" maxOccurs="1"
minOccurs="1" type="xsd:string" />
<element name="key" nillable="true"
type="xsd:string" />
</sequence>
</complexType>
<complexType name="TestLoginResponse">
<sequence>
<element name="failedReason"
nillable="true" type="xsd:string" />
<element name="status"
type="xsd:boolean" />
</sequence>
</complexType>
</schema>
</wsdl:types>
<wsdl:message name="testLoginRequest">
<wsdl:part name="testLoginRequestAttributes"
type="impl:TestLoginType"/>
</wsdl:message>
<wsdl:message name="testLoginResponse">
<wsdl:part name="testLoginResponseAttributes"
type="impl:TestLoginResponse"/>
</wsdl:message>
<wsdl:portType name="LoginServicePortType">
<wsdl:operation name="testLogin">
<wsdl:input message="impl:testLoginRequest"
name="testLoginRequest" />
<wsdl:output message="impl:testLoginResponse"
name="testLoginResponse" />
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="LoginServiceSoapBinding"
type="impl:LoginServicePortType">
<wsdlsoap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
<wsdl:operation name="testLogin">
<wsdlsoap:operation soapAction="" />
<wsdl:input name="testLoginRequest">
<wsdlsoap:body use="literal" />
</wsdl:input>
<wsdl:output name="testLoginResponse">
<wsdlsoap:body use="literal" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="LoginService">
<wsdl:port binding="impl:LoginServiceSoapBinding"
name="LoginService">
<wsdlsoap:address
location="http://localhost:8080/axis2/services/login"
/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
This is what the exception raised:
An error occurred while completing process -
java.lang.reflect.InvocationException
No element type is defined for the message testLoginRequest
Any help is really appreciated.
Thanks.
--
View this message in context:
http://www.nabble.com/IWAB0497E-Error-in-writing-WSDL-file-null-tp19529642p19537249.html
Sent from the Axis - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]