|
|
Re: Help with WSDL validation error [message #202689 is a reply to message #202678] |
Fri, 19 October 2007 14:39 |
Eclipse User |
|
|
|
Originally posted by: mauro.molinari.cardinis.com
Valentin ha scritto:
> It's a bit hard to be sure without seeing the entire file: the error is
> trying to say that the complex type FailedConfigurationException is
> extending a type from perhaps another (inline?) schema and that schema is
> not imported in the schema that declares FailedConfigurationException.
Hi Valentin,
thank you for your help!
I'm attaching the whole content of the WSDL file. This file has been
generated from a Java class using Axis 1.3 Eclipse plugin, so it should
not (I think...) depend on any other schema.
So, I have to guess that this WSDL is not completely self-defined?
(sorry if my questions are stupid, but I'm not experienced with WSDL and
complex XML...).
These are the signatures of the two methods of AccessServices class file
I want to expose as a web service:
1) public String loginByUsernamePassword(String username, String
password) throws FailedConfigurationException, InvalidArgumentException,
GenericTicketingException{
2) public void logout(String ticket) throws
FailedConfigurationException, InvalidArgumentException,
GenericTicketingException {
Please note that all those three exceptions are custom exceptions that
extend java.lang.Exception.
Here's the complete WSDL:
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:axis2="http://access.webservice.cardinis.cardinis.com"
xmlns:ns1="http://access.webservice.cardinis.cardinis.com/xsd"
xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:ns0="http://ticketFramework.webservice.cardinis.com/xsd"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
targetNamespace="http://access.webservice.cardinis.cardinis.com">
<wsdl:types>
<xs:schema
xmlns:ax21="http://ticketFramework.webservice.cardinis.com/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://ticketFramework.webservice.cardinis.com/xsd">
<xs:complexType name="FailedConfigurationException">
<xs:complexContent>
<xs:extension base="ns1:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="InvalidArgumentException">
<xs:complexContent>
<xs:extension base="ns1:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:complexType name="GenericTicketingException">
<xs:complexContent>
<xs:extension base="ns1:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:schema>
<xs:schema
xmlns:xsd="http://access.webservice.cardinis.cardinis.com/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://access.webservice.cardinis.cardinis.com/xsd">
<xs:complexType name="Exception">
<xs:sequence>
<xs:element minOccurs="0" name="Exception" nillable="true"
type="xs:anyType" />
</xs:sequence>
</xs:complexType>
<xs:element name="FailedConfigurationException">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="FailedConfigurationException"
nillable="true" type="ns0:FailedConfigurationException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="InvalidArgumentException">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="InvalidArgumentException"
nillable="true" type="ns0:InvalidArgumentException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="GenericTicketingException">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="GenericTicketingException"
nillable="true" type="ns0:GenericTicketingException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="loginByUsernamePassword">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="username" nillable="true"
type="xs:string" />
<xs:element minOccurs="0" name="password" nillable="true"
type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="loginByUsernamePasswordResponse">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="return" nillable="true"
type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="logout">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="ticket" nillable="true"
type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
</wsdl:types>
<wsdl:message name="logoutRequest">
<wsdl:part name="parameters" element="ns1:logout" />
</wsdl:message>
<wsdl:message name="logoutResponse" />
<wsdl:message name="FailedConfigurationException">
<wsdl:part name="parameters"
element="ns1:FailedConfigurationException" />
</wsdl:message>
<wsdl:message name="InvalidArgumentException">
<wsdl:part name="parameters" element="ns1:InvalidArgumentException" />
</wsdl:message>
<wsdl:message name="GenericTicketingException">
<wsdl:part name="parameters" element="ns1:GenericTicketingException" />
</wsdl:message>
<wsdl:message name="loginByUsernamePasswordRequest">
<wsdl:part name="parameters" element="ns1:loginByUsernamePassword" />
</wsdl:message>
<wsdl:message name="loginByUsernamePasswordResponse">
<wsdl:part name="parameters"
element="ns1:loginByUsernamePasswordResponse" />
</wsdl:message>
<wsdl:portType name="AccessServicesPortType">
<wsdl:operation name="logout">
<wsdl:input message="axis2:logoutRequest" wsaw:Action="urn:logout" />
<wsdl:output message="axis2:logoutResponse"
wsaw:Action="urn:logoutResponse" />
<wsdl:fault message="axis2:FailedConfigurationException"
name="FailedConfigurationException"
wsaw:Action="urn:logoutFailedConfigurationException" />
<wsdl:fault message="axis2:InvalidArgumentException"
name="InvalidArgumentException"
wsaw:Action="urn:logoutInvalidArgumentException" />
<wsdl:fault message="axis2:GenericTicketingException"
name="GenericTicketingException"
wsaw:Action="urn:logoutGenericTicketingException" />
</wsdl:operation>
<wsdl:operation name="loginByUsernamePassword">
<wsdl:input message="axis2:loginByUsernamePasswordRequest"
wsaw:Action="urn:loginByUsernamePassword" />
<wsdl:output message="axis2:loginByUsernamePasswordResponse"
wsaw:Action="urn:loginByUsernamePasswordResponse" />
<wsdl:fault message="axis2:FailedConfigurationException"
name="FailedConfigurationException"
wsaw:Action="urn:loginByUsernamePasswordFailedConfigurationException " />
<wsdl:fault message="axis2:InvalidArgumentException"
name="InvalidArgumentException"
wsaw:Action="urn:loginByUsernamePasswordInvalidArgumentException " />
<wsdl:fault message="axis2:GenericTicketingException"
name="GenericTicketingException"
wsaw:Action="urn:loginByUsernamePasswordGenericTicketingException " />
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="AccessServicesSOAP11Binding"
type="axis2:AccessServicesPortType">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"
style="document" />
<wsdl:operation name="logout">
<soap:operation soapAction="urn:logout" style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap:fault use="literal" name="FailedConfigurationException" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap:fault use="literal" name="InvalidArgumentException" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap:fault use="literal" name="GenericTicketingException" />
</wsdl:fault>
</wsdl:operation>
<wsdl:operation name="loginByUsernamePassword">
<soap:operation soapAction="urn:loginByUsernamePassword"
style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap:fault use="literal" name="FailedConfigurationException" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap:fault use="literal" name="InvalidArgumentException" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap:fault use="literal" name="GenericTicketingException" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:binding name="AccessServicesSOAP12Binding"
type="axis2:AccessServicesPortType">
<soap12:binding transport="http://schemas.xmlsoap.org/soap/http"
style="document" />
<wsdl:operation name="logout">
<soap12:operation soapAction="urn:logout" style="document" />
<wsdl:input>
<soap12:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap12:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap12:fault use="literal" name="FailedConfigurationException" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap12:fault use="literal" name="InvalidArgumentException" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap12:fault use="literal" name="GenericTicketingException" />
</wsdl:fault>
</wsdl:operation>
<wsdl:operation name="loginByUsernamePassword">
<soap12:operation soapAction="urn:loginByUsernamePassword"
style="document" />
<wsdl:input>
<soap12:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap12:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap12:fault use="literal" name="FailedConfigurationException" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap12:fault use="literal" name="InvalidArgumentException" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap12:fault use="literal" name="GenericTicketingException" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:binding name="AccessServicesHttpBinding"
type="axis2:AccessServicesPortType">
<http:binding verb="POST" />
<wsdl:operation name="logout">
<http:operation location="AccessServices/logout" />
<wsdl:input>
<mime:content type="text/xml" part="logout" />
</wsdl:input>
</wsdl:operation>
<wsdl:operation name="loginByUsernamePassword">
<http:operation location="AccessServices/loginByUsernamePassword" />
<wsdl:input>
<mime:content type="text/xml" part="loginByUsernamePassword" />
</wsdl:input>
<wsdl:output>
<mime:content type="text/xml" part="loginByUsernamePassword" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="AccessServices">
<wsdl:port name="AccessServicesSOAP11port_http"
binding="axis2:AccessServicesSOAP11Binding">
<soap:address
location="http://localhost:8080/axis2/services/AccessServices" />
</wsdl:port>
<wsdl:port name="AccessServicesSOAP12port_http"
binding="axis2:AccessServicesSOAP12Binding">
<soap12:address
location="http://localhost:8080/axis2/services/AccessServices" />
</wsdl:port>
<wsdl:port name="AccessServicesHttpport"
binding="axis2:AccessServicesHttpBinding">
<http:address
location="http://localhost:8080/axis2/services/AccessServices" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
Cheers,
Mauro.
|
|
|
|
|
Re: Help with WSDL validation error [message #202763 is a reply to message #202706] |
Mon, 22 October 2007 08:36 |
Eclipse User |
|
|
|
Originally posted by: mauro.molinari.cardinis.com
David Carver ha scritto:
> I think you need this here:
>
> <xs:import
> namespace="http://access.webservice.cardinis.cardinis.com/xsd"/>
>
> Otherwise, the schema doesn't know where ns1:Exception comes from.
Thank you David, thank you Lawrence.
Starting from this hint, I tried to add the option in Java2WSDL to add
the generated schema for java.lang.Exception, too.
The resulting XML doesn't have the problem described earlier, but has
other problems:
- a problem with the ax21 namespace: I'm not expert in XML, but I think
that the namespace definition
xmlns:ax21="http://ticketFramework.webservice.cardinis.com/xsd" should
be in <wsdl:definitions> rather than in <wsdl:types>...
- many errors like:
cvc-identity-constraint.4.2.2: Duplicate key value
[FailedConfigurationException] declared for identity constraint
"message" of element "definitions".
Any suggestion for this? May it be a problem in the relative position of
the entries, like David suggested?
- cvc-complex-type.2.4.a: Invalid content was found starting with
element 'wsdl:fault'. One of
'{"http://schemas.xmlsoap.org/wsdl/":output}' is expected. (on line 166)
Any suggestion for this, too?
Here is the whole generated WDSL:
<wsdl:definitions
xmlns:axis2="http://access.webservice.cardinis.cardinis.com"
xmlns:ns="http://access.webservice.cardinis.cardinis.com/xsd"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/"
targetNamespace="http://access.webservice.cardinis.cardinis.com">
<wsdl:types>
<xs:schema
xmlns:ax21="http://ticketFramework.webservice.cardinis.com/xsd"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://ticketFramework.webservice.cardinis.com/xsd">
<xs:element name="FailedConfigurationException"
type="ax21:FailedConfigurationException" />
<xs:complexType name="FailedConfigurationException">
<xs:complexContent>
<xs:extension base="xs:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:element name="InvalidArgumentException"
type="ax21:InvalidArgumentException" />
<xs:complexType name="InvalidArgumentException">
<xs:complexContent>
<xs:extension base="xs:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
<xs:element name="GenericTicketingException"
type="ax21:GenericTicketingException" />
<xs:complexType name="GenericTicketingException">
<xs:complexContent>
<xs:extension base="xs:Exception">
<xs:sequence />
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:schema>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:ns0="http://ticketFramework.webservice.cardinis.com/xsd"
attributeFormDefault="qualified" elementFormDefault="qualified"
targetNamespace="http://access.webservice.cardinis.cardinis.com/xsd">
<xs:element name="FailedConfigurationExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="FailedConfigurationException" nillable="true"
type="ns0:FailedConfigurationException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="InvalidArgumentExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="InvalidArgumentException" nillable="true"
type="ns0:InvalidArgumentException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="GenericTicketingExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="GenericTicketingException" nillable="true"
type="ns0:GenericTicketingException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="loginByUsernamePassword">
<xs:complexType>
<xs:sequence>
<xs:element name="username" nillable="true" type="xs:string" />
<xs:element name="password" nillable="true" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="loginByUsernamePasswordResponse">
<xs:complexType>
<xs:sequence>
<xs:element name="return" nillable="true" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="FailedConfigurationExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="FailedConfigurationException" nillable="true"
type="ns0:FailedConfigurationException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="InvalidArgumentExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="InvalidArgumentException" nillable="true"
type="ns0:InvalidArgumentException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="GenericTicketingExceptionFault">
<xs:complexType>
<xs:sequence>
<xs:element name="GenericTicketingException" nillable="true"
type="ns0:GenericTicketingException" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="logout">
<xs:complexType>
<xs:sequence>
<xs:element name="ticket" nillable="true" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
</wsdl:types>
<wsdl:message name="loginByUsernamePasswordMessage">
<wsdl:part name="part1" element="ns:loginByUsernamePassword" />
</wsdl:message>
<wsdl:message name="loginByUsernamePasswordResponseMessage">
<wsdl:part name="part1" element="ns:loginByUsernamePasswordResponse" />
</wsdl:message>
<wsdl:message name="FailedConfigurationException">
<wsdl:part name="part1" element="ax21:FailedConfigurationException" />
</wsdl:message>
<wsdl:message name="InvalidArgumentException">
<wsdl:part name="part1" element="ax21:InvalidArgumentException" />
</wsdl:message>
<wsdl:message name="GenericTicketingException">
<wsdl:part name="part1" element="ax21:GenericTicketingException" />
</wsdl:message>
<wsdl:message name="logoutMessage">
<wsdl:part name="part1" element="ns:logout" />
</wsdl:message>
<wsdl:message name="FailedConfigurationException">
<wsdl:part name="part1" element="ax21:FailedConfigurationException" />
</wsdl:message>
<wsdl:message name="InvalidArgumentException">
<wsdl:part name="part1" element="ax21:InvalidArgumentException" />
</wsdl:message>
<wsdl:message name="GenericTicketingException">
<wsdl:part name="part1" element="ax21:GenericTicketingException" />
</wsdl:message>
<wsdl:portType name="AccessServicesPortType">
<wsdl:operation name="loginByUsernamePassword">
<wsdl:input xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
wsaw:Action="urn:loginByUsernamePassword"
message="axis2:loginByUsernamePasswordMessage" />
<wsdl:output xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
message="axis2:loginByUsernamePasswordResponseMessage"
wsaw:Action="urn:loginByUsernamePassword" />
<wsdl:fault message="axis2:FailedConfigurationException"
name="FailedConfigurationException" />
<wsdl:fault message="axis2:InvalidArgumentException"
name="InvalidArgumentException" />
<wsdl:fault message="axis2:GenericTicketingException"
name="GenericTicketingException" />
</wsdl:operation>
<wsdl:operation name="logout">
<wsdl:input xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl"
wsaw:Action="urn:logout" message="axis2:logoutMessage" />
<wsdl:fault message="axis2:FailedConfigurationException"
name="FailedConfigurationException" />
<wsdl:fault message="axis2:InvalidArgumentException"
name="InvalidArgumentException" />
<wsdl:fault message="axis2:GenericTicketingException"
name="GenericTicketingException" />
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="AccessServicesSOAP11Binding"
type="axis2:AccessServicesPortType">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"
style="document" />
<wsdl:operation name="loginByUsernamePassword">
<soap:operation soapAction="urn:loginByUsernamePassword"
style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap:body use="literal" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap:body use="literal" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap:body use="literal" />
</wsdl:fault>
</wsdl:operation>
<wsdl:operation name="logout">
<soap:operation soapAction="urn:logout" style="document" />
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
<wsdl:fault name="FailedConfigurationException">
<soap:body use="literal" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap:body use="literal" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap:body use="literal" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:binding name="AccessServicesSOAP12Binding"
type="axis2:AccessServicesPortType">
<soap12:binding transport="http://schemas.xmlsoap.org/soap/http"
style="document" />
<wsdl:operation name="loginByUsernamePassword">
<soap12:operation soapAction="urn:loginByUsernamePassword"
style="document" />
<wsdl:input>
<soap12:body use="literal" />
</wsdl:input>
<wsdl:output>
<soap12:body use="literal" />
</wsdl:output>
<wsdl:fault name="FailedConfigurationException">
<soap12:body use="literal" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap12:body use="literal" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap12:body use="literal" />
</wsdl:fault>
</wsdl:operation>
<wsdl:operation name="logout">
<soap12:operation soapAction="urn:logout" style="document" />
<wsdl:input>
<soap12:body use="literal" />
</wsdl:input>
<wsdl:fault name="FailedConfigurationException">
<soap12:body use="literal" />
</wsdl:fault>
<wsdl:fault name="InvalidArgumentException">
<soap12:body use="literal" />
</wsdl:fault>
<wsdl:fault name="GenericTicketingException">
<soap12:body use="literal" />
</wsdl:fault>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="AccessServices">
<wsdl:port name="AccessServicesSOAP11port"
binding="axis2:AccessServicesSOAP11Binding">
<soap:address
location="http://localhost:8080/axis2/services/AccessServices" />
</wsdl:port>
<wsdl:port name="AccessServicesSOAP12port"
binding="axis2:AccessServicesSOAP12Binding">
<soap12:address
location="http://localhost:8080/axis2/services/AccessServices" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
> Depending on the WSDL editor and validator, you may need to flip these
> definitions around, so that the one below comes before the one above as
> well.
>
> Personally though, I would create a new schema that imported or included
> each of these itself. Multiple schemas in the wsdl:type definition is
> a gray area amongst tools.
I see... so, if I created multiple schemas for each complex type, I
could share them between multiple WDSLs, couldn't I?
It sounds interesting...
The main problem is that I was starting using Axis2's Java2WSDL thinking
that it should make all the work for me, but it seems that it actually
has some serious problems managing methods that can launch exceptions...
Axis2 online documentation doesn't give any example of using the
bottom-up approach with methods that are more complex than simple
"hello-world" cases...
I would be grateful if someone had any hints of where I could find some
useful documentation.
Cheers,
Mauro.
|
|
|
Re: Help with WSDL validation error [message #202786 is a reply to message #202763] |
Mon, 22 October 2007 13:56 |
David Carver Messages: 174 Registered: July 2009 |
Senior Member |
|
|
Comments in line:
Mauro Molinari wrote:
> - a problem with the ax21 namespace: I'm not expert in XML, but I think
> that the namespace definition
> xmlns:ax21="http://ticketFramework.webservice.cardinis.com/xsd" should
> be in <wsdl:definitions> rather than in <wsdl:types>...
No, you should be able to define it on the xs:schema. However, since you
reference it from outside the xs:schema, you probably should have it
defined at thw WSDL:definition level as well, to make it visible to the
system.
>
> - many errors like:
> cvc-identity-constraint.4.2.2: Duplicate key value
> [FailedConfigurationException] declared for identity constraint
> "message" of element "definitions".
> Any suggestion for this? May it be a problem in the relative position of
> the entries, like David suggested?
This is because you have two wsdl:message names with the same entry.
You have two FailedConfigurationException message entries defined.
>
> - cvc-complex-type.2.4.a: Invalid content was found starting with
> element 'wsdl:fault'. One of
> '{"http://schemas.xmlsoap.org/wsdl/":output}' is expected. (on line 166)
> Any suggestion for this, too?
In your operation logout, you need an empty wsdl:output before your
wsdl:fault.
>
> I see... so, if I created multiple schemas for each complex type, I
> could share them between multiple WDSLs, couldn't I?
> It sounds interesting...
>
> The main problem is that I was starting using Axis2's Java2WSDL thinking
> that it should make all the work for me, but it seems that it actually
> has some serious problems managing methods that can launch exceptions...
> Axis2 online documentation doesn't give any example of using the
> bottom-up approach with methods that are more complex than simple
> "hello-world" cases...
I always recommend a top down approach if you have control over what you
are designing. I never rely on tools to figure out what I want, you
usually have to do some tweaking to what they generate to make sure they
aren't confused.
|
|
|
|
Re: Help with WSDL validation error [message #202906 is a reply to message #202807] |
Tue, 23 October 2007 13:08 |
Eclipse User |
|
|
|
Originally posted by: mauro.molinari.cardinis.com
Thank you for your suggestions.
In fact, this is the approach I will adopt, although I was searching for
a quicker way as a short-term solution.
Mauro.
|
|
|
Powered by
FUDForum. Page generated in 0.04280 seconds