You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Eric Gueidao <Er...@ens.insa-rennes.fr> on 2008/03/31 09:55:10 UTC

Problem with CXF inheritance exception

Hello,

I'm working on project with CXF and I try to keep the inheritance between
exceptions in my WSDL but it doesn't work.
It works well with data objects but when I generate the WSDL of my service with
java2wsdl (2.0.4 and 2.0.5) or java2ws (2.1) I lose the inheritance between
exceptions.
Do you know, please, how to do for keeping inheritance between exceptions? If
it's impossible to do it, can I be able to do it in the future CXF version?

Thank you in advance,
GUEIDAO Eric


Re: Problem with CXF inheritance exception

Posted by Daniel Kulp <dk...@apache.org>.

As Glen mentioned, this is completely per spec.   

You can work around it SLIGHTLY by refactoring your exceptions to store 
all their data in JAXB specified java beans (grabbed via getFaultInfo()) 
that implement the same heiarchy.   That said, when you run wsdl2java on 
the wsdl to generate code from it, that heiarchy would not be honored in 
the exceptions themselves. 

In anycase, this is all per spec.

Dan


On Monday 31 March 2008, Eric Gueidao wrote:
> Hello,
>
> I'm working on project with CXF and I try to keep the inheritance
> between exceptions in my WSDL but it doesn't work.
> It works well with data objects but when I generate the WSDL of my
> service with java2wsdl (2.0.4 and 2.0.5) or java2ws (2.1) I lose the
> inheritance between exceptions.
> Do you know, please, how to do for keeping inheritance between
> exceptions? If it's impossible to do it, can I be able to do it in the
> future CXF version?
>
> Thank you in advance,
> GUEIDAO Eric



-- 
J. Daniel Kulp
Principal Engineer, IONA
dkulp@apache.org
http://www.dankulp.com/blog

Re: Problem with CXF inheritance exception

Posted by Glen Mazza <gl...@verizon.net>.
I believe you'd get the very same result with Metro (try it [1])--CXF is
performing according to spec. If you're unhappy with JAX-WS' design on
this issue, sending comments to the JSR[2] over the matter would
probably be the best solution.

Regards,
Glen

[1] http://www.jroller.com/gmazza/date/20070929
[2] http://jcp.org/en/jsr/detail?id=224

Am Montag, den 31.03.2008, 09:55 +0200 schrieb Eric Gueidao:
> Hello,
> 
> I'm working on project with CXF and I try to keep the inheritance between
> exceptions in my WSDL but it doesn't work.
> It works well with data objects but when I generate the WSDL of my service with
> java2wsdl (2.0.4 and 2.0.5) or java2ws (2.1) I lose the inheritance between
> exceptions.
> Do you know, please, how to do for keeping inheritance between exceptions? If
> it's impossible to do it, can I be able to do it in the future CXF version?
> 
> Thank you in advance,
> GUEIDAO Eric
>