This is completely per JAX-WS specification.   Without the @Oneway annotation, 
the methods are all considered request/response and the wsdl and such should 
reflect that.

It's partially because not having the "output" there also mandates that no 
fault information can be passed back.    Thus, if something exceptional occurs 
in the "updateActor" method, the client would not be able to be notified.   By 
mandating the @Oneway, it really puts the developer in the position of making 
it a conscious decision.  

Dan


On Wednesday 10 November 2010 9:15:29 am KnutIvar wrote:
> Hi!
> 
> Using Java 1.6, CXF 2.3.0;
> 
> The following metod ...
> @WebMethod(operationName="updateActor")
> void updateActor(@WebParam(name = "updateActorRequest")
> UpdateActorRequestDocument requestDocument) throws Exception;
> 
> ... looks like this in the generated WSDL:
> 
>     <wsdl:operation name="updateActor">
>       <soap:operation soapAction="" style="document"/>
>       <wsdl:input name="updateActor">
>         <soap:body use="literal"/>
>       </wsdl:input>
>       <wsdl:output name="updateActorResponse">
>         <soap:body use="literal"/>
>       </wsdl:output>
>     </wsdl:operation>
> 
> Why does it have a defined response? It's a void... Is this all good, or is
> it wrong according to some spesification? ... Oracle SOA Suite 10.1.3.4
> complains that the method returns an SOAP Envelope with an empty soap:Body
> tag. According to the wsdl, it expects a <updateActorResponse /> as well,
> but that's not supplied.
> 
> Is the generated wsdl (and response) correct according to standards?
> 
> ... however; I manage to "remove" the generated response with the
> javax.jws.Oneway annotation;
> @WebMethod(operationName="updateActor")
> @Oneway
> void updateActor(@WebParam(name = "updateActorRequest")
> UpdateActorRequestDocument requestDocument) throws Exception;
> 
> The generated wsdl will not contain the response.., but acctually; I'd
> perfer it if I woudn't need the @Oneway.
> 
> regards
> Knut Ivar

-- 
Daniel Kulp
[email protected]
http://dankulp.com/blog

Reply via email to