[ 
https://issues.apache.org/jira/browse/CXF-1136?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12538146
 ] 

Glen Mazza commented on CXF-1136:
---------------------------------

Another option is to take a look at GlassFish Metro, with your current code.  
If it is failing also there, it would appear to be something wrong with your 
coding.  

Quote: "Another possiblity as you mentioned is to perform a java to wsdl .. 
modify the wsdl .. perform wsdl to java but that's a huge workaround. If I have 
to resort to that then clearly CXF doesn't support pojo development with 
exceptions."

Not necessarily.  The steps I'm outlining are good for CXF/JAXB novices to 
figure out how to get the code right.  After doing the above, you can probably 
backport the generated code to what you presently have to figure out the 
exception problem.

Also, Dennis Sosnoski (who codes JiBX) also thinks that "java to wsdl .. modify 
the wsdl .. perform wsdl to java" is not that bad an idea:
http://www.infoq.com/articles/sosnoski-code-first

Glen


> Custom exception not appearing in SOAP fault response
> -----------------------------------------------------
>
>                 Key: CXF-1136
>                 URL: https://issues.apache.org/jira/browse/CXF-1136
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.0.2
>         Environment: WIndows XP
> Java SDK 1.5_0_12
>            Reporter: ed p
>            Priority: Critical
>         Attachments: helloWorld.wsdl, java_first_jaxws.zip
>
>
> I modified the apache-cxf-2.0.2-incubator\samples\java_first_jaxws web 
> service to throw a custom exception and a custom request and response object 
> like so:
> public interface HelloWorld {
>     Response sayHi(Request text) throws CustomException;
> }
> CustomException is a CustomExceptionBase with two string properties. 
> CustomExceptionBase is a java.lang.Exception
> The CustomException appears in the WSDL but the CustomExceptionBase is 
> missing. When the service is invoked and throws a CustomException the soap 
> response is:
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
>    <soap:Body>
>       <soap:Fault>
>          <faultcode>soap:Server</faultcode>
>          <faultstring>custom error</faultstring>
>       </soap:Fault>
>    </soap:Body>
> </soap:Envelope>
> I am expecting to see the CustomException serialized in the 
> Envelope/Body/Fault/detail node.

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

Reply via email to