[ 
https://issues.apache.org/jira/browse/AXIS2-3295?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12536997
 ] 

Vincent Brabant commented on AXIS2-3295:
----------------------------------------

Seems that problem is caused by the checkPostConditions of the DispatchPhase.
the following code 

fault.setFaultCode(org.apache.axis2.namespace.Constants.FAULT_CLIENT);

should be replaced by something like that

if (msgContext.isSoap11) {
  fault.setFaultCode(org.apache.axiom.soap.SOAP11Constants.FAULT_CODE_SENDER);
} else {
  fault.setFaultCode(org.apache.axiom.soap.SOAP12Constants.FAULT_CODE_SENDER);
}

That's one possible solution.

Another possible solution is to change the 
MessageContextBuilder.createFaultEnvelope to check if the localPart of the 
faultCode is Client or Sender and replace it by the correct value depending of 
the SOAP version.
It's maybe better to fix the problem in the 
MessageContextBuilder.createFaultEnvelope because it's the central point to 
generate a correct FaultEnvelope.

> soapenv:Client is returned in the s
> -----------------------------------
>
>                 Key: AXIS2-3295
>                 URL: https://issues.apache.org/jira/browse/AXIS2-3295
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: kernel
>    Affects Versions: 1.3, nightly
>         Environment: Windows XP / JDK 1.4
>            Reporter: Vincent Brabant
>
> I am calling a Axis2 server with a invalid url. Result is that Axis2 can't 
> resolve the Service/Operation. 
> So, it returns an soapFault like the following : 
> <soapenv:Envelope xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope";>
>    <soapenv:Body>
>       <soapenv:Fault>
>          <soapenv:Code>
>             <soapenv:Value>soapenv:Client</soapenv:Value>
>          </soapenv:Code>
>          <soapenv:Reason>
>             <soapenv:Text xml:lang="en-US">The service cannot be found for 
> the endpoint reference (EPR) 
> http://hostname:9080/root/services/InvalidServiceName/OperationName</soapenv:Text>
>          </soapenv:Reason>
>          <soapenv:Detail/>
>       </soapenv:Fault>
>    </soapenv:Body>
> </soapenv:Envelope>
> Because I am a SOAP 1.2 client, I am expecting that Axis return a 
> soapenv:Sender in place of a soapenv:Client (that's for Axis1.1 only)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to