Sorry for the previous mail, i didnt say hello :)
So hello folks,
I just have seen in the code of CXF in the
org.apache.cxf.jaxws.handler.AbstractJAXWSHandlerInterceptor.setupBindingOperationInfo(org.apache.cxf.message.Exchange,
java.lang.Object) method that
a Exchange is considered OneWay if the BindingOperationInfo has no
output but the fault is not considered.
Is it a normal behavior while the spec says that the fault has to be
considered to decide if the operation is one way or not ?
Nordine Boussedra a écrit :
We use wsdl2java (CXF 2.3.1) to generate classes from a wsdl.
Here is the definition of the operation in the PortType:
<wsdl:operation name="creerCongeSansRetour">
<wsdl:input name="creerCongeSansRetourRequest"
message="tns:creerCongeSansRetourRequest" />
<wsdl:fault name="UtilisateurInexistantException"
message="tns:UtilisateurInexistantException">
</wsdl:fault>
</wsdl:operation>
Binding:
<wsdl:operation name="creerCongeSansRetour">
<soap:operation soapAction="creerCongeSansRetour"
style="document" />
<wsdl:input name="creerCongeSansRetourRequest">
<soap:body use="literal" />
</wsdl:input>
<wsdl:fault name="UtilisateurInexistantException">
<soap:fault name="UtilisateurInexistantException"
use="literal" />
</wsdl:fault>
</wsdl:operation>
/The JAX-WS specification says:
Only java methods whose return type is void that have no parameters
that implement holder and that do not throw any checked exception can
be mapped to one way operations.
...
automatic choice between two ways and one way mapping is not possible./
But when we generate java classes from WSDL we have the @oneWay
annotation above the method
@Oneway
@WebMethod(action = "creerCongeSansRetour")
public void creerCongeSansRetour(
@WebParam(partName = "creerCongeSansRetourRequest", name =
"CreerCongesSansRetourRequest", targetNamespace =
"http://toto.titi.fr/gestion/conge/objets/v1/") CreerCongeRequest
creerCongeSansRetourRequest)
throws UtilisateurInexistantException;
is it a bug in CXF or an error in my wsdl ?
thanx for the help.
Ce message est protégé par les règles relatives au secret des correspondances.
Il est donc établi à destination exclusive de son destinataire. Celui-ci peut
donc contenir des informations confidentielles. La divulgation de ces
informations est à ce titre rigoureusement interdite. Si vous avez reçu ce
message par erreur, merci de le renvoyer à l'expéditeur dont l'adresse e-mail
figure ci-dessus et de détruire le message ainsi que toute pièce jointe.
This message is protected by the secrecy of correspondence rules. Therefore,
this message is intended solely for the attention of the addressee. This
message may contain privileged or confidential information, as such the
disclosure of these informations is strictly forbidden. If, by mistake, you
have received this message, please return this message to the addressser whose
e-mail address is written above and destroy this message and all files attached.
Ce message est protégé par les règles relatives au secret des correspondances.
Il est donc établi à destination exclusive de son destinataire. Celui-ci peut
donc contenir des informations confidentielles. La divulgation de ces
informations est à ce titre rigoureusement interdite. Si vous avez reçu ce
message par erreur, merci de le renvoyer à l'expéditeur dont l'adresse e-mail
figure ci-dessus et de détruire le message ainsi que toute pièce jointe.
This message is protected by the secrecy of correspondence rules. Therefore,
this message is intended solely for the attention of the addressee. This
message may contain privileged or confidential information, as such the
disclosure of these informations is strictly forbidden. If, by mistake, you
have received this message, please return this message to the addressser whose
e-mail address is written above and destroy this message and all files attached.