Reputation: 1581
I have an exception:
public class MyException extends Exception {
public MyException() {
}
public MyException(String message) {
super(message);
}
}
The exception is thrown from a webservice method.
When I generate the Webservice using a regular Jax-ws implementation, the WSDL has:
<xs:complexType name='MyException'> <xs:sequence> <xs:element minOccurs='0' name='message' type='xs:string' /> </xs:sequence> </xs:complexType>
But, when generating the webservice with cxf, I get:
<xs:complexType name='MyException'> <xs:sequence/></xs:complexType>
Which is not ok for me: I expect to get the first variant.
Can you please advise how to force CXF to provide the desired result?
Remark: I cannot alter the code in the exception! The Exception does not have any fields!
Thanks!
Upvotes: 0
Views: 932
Reputation: 14607
This is already reported and fixed in the latest CXF versions:
https://issues.apache.org/jira/browse/CXF-4748
Upvotes: 0