users@jax-rpc.java.net

RE: WSDL - empty request

From: Honorez Dylan <Dylan.Honorez_at_cronos.be>
Date: Thu, 10 Feb 2005 16:06:40 +0100

Method signatures include operation name, so if two different operations
both have an empty request, they are still unique. So that can't be the
reason. Otherwise two operations that have a string as input wouldn't be
unique either.

About the empty element, that's what I'm using now. It works,
butwscompile generates SOAPElements in signatures, instead of an empty
signatures.

Kind regards,
Dylan Honorez,
dylan.honorez_at_xt-i.com
http://www.xt-i.com/


-----Original Message-----
From: Anne Thomas Manes [mailto:atmanes_at_gmail.com]
Sent: donderdag 10 februari 2005 16:04
To: users_at_jax-rpc.dev.java.net
Subject: Re: WSDL - empty request

WS-I compliance requires that each operation have a unique signature.
Because you have two operations with an empty input message, you break
this rule. I suggest you create an empty element (e.g.,
<retrieveError/>) and use it as your input message for that operation.

Anne

On Wed, 9 Feb 2005 12:59:00 +0100, Honorez Dylan
<Dylan.Honorez_at_cronos.be> wrote:
> Hi,
>
> While developing a jax-rpc document/literal webservice, I came across
> the following issue:
> WSCompile is ok with one empty request, but not with more. The WSDL is
> fine and validates within XML Spy.
>
> WSCompile output:
> D:\projects\GFISFileHandling v2>call wscompile -gen:server
> -f:searchschema -keep -verbose -d build/WEB-INF/classes -model build/
> WEB-INF/model.xml.gz config.xml
> users_at_jax-rpc.dev.java.net[CustomClassGenerator: generating JavaClass
> for: fileInfo]
> [CustomClassGenerator: generating JavaClass for: objectInfo]
> [LiteralObjectSerializerGenerator: writing serializer/deserializer
for:
> fileInfo]
> [LiteralObjectSerializerGenerator: writing serializer/deserializer
for:
> objectInfo]
> error: generator error: cannot dispatch operation: retrieveError
>
> This is my WSDL:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
> xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
> xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
> xmlns:xs="http://www.w3.org/2001/XMLSchema"
> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
> xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"
> xmlns:tns="http://www.xt-i.com/gfis/"
> targetNamespace="http://www.xt-i.com/gfis/">
> <types>
> <xs:schema
targetNamespace="http://www.xt-i.com/gfis/">
> <xs:complexType name="fileInfo">
> <xs:sequence>
> <xs:element name="fileName"
> type="xs:string"/>
> <xs:element name="fileSizeKb"
> type="xs:long"/>
> <xs:element name="objectType"
> type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> <xs:complexType name="objectInfo">
> <xs:sequence>
> <xs:element name="fileName"
> type="xs:string"/>
> <xs:element name="objectType"
> type="xs:string"/>
> </xs:sequence>
> </xs:complexType>
> <xs:element name="fhstartRequest"
> type="xs:string"/>
> <xs:element name="fhstartResponse"
> type="xs:boolean"/>
> <xs:element name="retrieveResponse"
> type="tns:fileInfo"/>
> <xs:element name="copyRequest"
> type="tns:objectInfo"/>
> <xs:element name="copyResponse"
> type="xs:boolean"/>
> <xs:element name="removeRequest"
> type="tns:objectInfo"/>
> <xs:element name="removeResponse"
> type="xs:boolean"/>
> <xs:element name="retrieveErrorResponse"
> type="tns:fileInfo"/>
> </xs:schema>
> </types>
> <message name="fhstartRequest">
> <part name="fhstartRequest"
> element="tns:fhstartRequest"/>
> </message>
> <message name="fhstartResponse">
> <part name="fhstartResponse"
> element="tns:fhstartResponse"/>
> </message>
> <message name="retrieveRequest"/>
> <message name="retrieveResponse">
> <part name="fileInfo" element="tns:retrieveResponse"/>
> </message>
> <message name="copyRequest">
> <part name="objectInfo" element="tns:copyRequest"/>
> </message>
> <message name="copyResponse">
> <part name="success" element="tns:copyResponse"/>
> </message>
> <message name="removeRequest">
> <part name="objectInfo" element="tns:removeRequest"/>
> </message>
> <message name="removeResponse">
> <part name="success" element="tns:removeResponse"/>
> </message>
> <message name="retrieveErrorRequest"/>
> <message name="retrieveErrorResponse">
> <part name="fileInfo"
> element="tns:retrieveErrorResponse"/>
> </message>
> <portType name="FHPort">
> <operation name="fhstart">
> <input message="tns:fhstartRequest"/>
> <output message="tns:fhstartResponse"/>
> </operation>
> <operation name="retrieve">
> <input message="tns:retrieveRequest"/>
> <output message="tns:retrieveResponse"/>
> </operation>
> <operation name="copy">
> <input message="tns:copyRequest"/>
> <output message="tns:copyResponse"/>
> </operation>
> <operation name="remove">
> <input message="tns:removeRequest"/>
> <output message="tns:removeResponse"/>
> </operation>
> <operation name="retrieveError">
> <input message="tns:retrieveErrorRequest"/>
> <output message="tns:retrieveErrorResponse"/>
> </operation>
> </portType>
> <binding name="FHBinding" type="tns:FHPort">
> <soap:binding style="document"
> transport="http://schemas.xmlsoap.org/soap/http"/>
> <operation name="fhstart">
> <!-- initial start / do not use / invoke
> manually -->
> <input>
> <soap:body use="literal"/>
> </input>
> <output>
> <soap:body use="literal"/>
> </output>
> </operation>
> <operation name="retrieve">
> <!-- // return first element on waiting
queue
> (fileName, fileSize, objectType)
> // move element to retrieved queue -->
> <input>
> <soap:body use="literal"/>
> </input>
> <output>
> <soap:body use="literal"/>
> </output>
> </operation>
> <operation name="copy">
> <!-- // if transferMethod is "FTP",
construct
> new FtpClient and upload to correct location
> // if transferMethod is "FS", just copy to the
> correct location -->
> <input>
> <soap:body use="literal"/>
> </input>
> <output>
> <soap:body use="literal"/>
> </output>
> </operation>
> <operation name="remove">
> <!-- // delete file from fileSystem, remove
from
> queue or set status to processed -->
> <input>
> <soap:body use="literal"/>
> </input>
> <output>
> <soap:body use="literal"/>
> </output>
> </operation>
> <operation name="retrieveError">
> <!-- // get error from errorQueue -->
> <input>
> <soap:body use="literal"/>
> </input>
> <output>
> <soap:body use="literal"/>
> </output>
> </operation>
> </binding>
> <service name="FileHandler">
> <port name="FileHandlerPort" binding="tns:FHBinding">
> <soap:address
location="REPLACE_WITH_ACTUAL_URL"
> xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"/>
> </port>
> </service>
> </definitions>
>
> When I remove the "retrieveError" operation WSCompile works ok.
> Any suggestions to my problem or another way to send empty requests?
>
> Kind regards,
> Dylan Honorez,
> dylan.honorez_at_xt-i.com
> http://www.xt-i.com/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
> For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jax-rpc.dev.java.net
For additional commands, e-mail: users-help_at_jax-rpc.dev.java.net