Benson, This is a sideaffect of the fixes we did for the Aegis faults with the JAX-WS frontend. By making the WebFaultOutInterceptor delegate up to the normal fault handling, the databinding gets a crack at trying to write the fault.
In 2.0.2, if the exception didn't have an @WebFault, the WebFaultOutInterceptor would ignore it and then the SOAPFaultOut stuff would then just map the getMessage() call onto the wire an no other data would get sent on the wire. With 2.0.3, the superclass gets a chance which basically feeds the fault into the databinding writer. In this case, JAXB doesn't know what to do with it and throws an exception. The FaultOutInterceptor does swallow that exception so it does properly go to the SOAPFaultOut stuff as before, but I did log it so you know any detail that may be in the Exception that you expected to be on the wire won't be there. The databinding had no clue what to do with it. Dan On Thursday 18 October 2007, Benson Margulies wrote: > Since moving to the latest 2.0.3 snapshot, I'm getting an exception > when marshalling a fault declared on a 'throws' clause. No @WebFault. > This didn't happen with 2.0.2 afaik. > > WARNING: Exception occurred while writing fault. > org.apache.cxf.interceptor.Fault: Marshalling Error: > com.basistech.ws.fortest.TestException is not known to this context > at > org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.jav >a: 179) > at > org.apache.cxf.jaxb.io.DataWriterImpl.write(DataWriterImpl.java:42) > at > org.apache.cxf.interceptor.FaultOutInterceptor.handleMessage(FaultOutI >nt erceptor.java:75) > at > org.apache.cxf.jaxws.interceptors.WebFaultOutInterceptor.handleMessage >(W ebFaultOutInterceptor.java:127) > at > org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto >rC hain.java:207) > at > org.apache.cxf.interceptor.AbstractFaultChainInitiatorObserver.onMessa >ge (AbstractFaultChainInitiatorObserver.java:90) > at > org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercepto >rC hain.java:224) > at > org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitia >ti onObserver.java:73) > at > org.apache.cxf.transport.http_jetty.JettyHTTPDestination.serviceReques >t( JettyHTTPDestination.java:282) > at > org.apache.cxf.transport.http_jetty.JettyHTTPDestination.doService(Jet >ty HTTPDestination.java:238) > at > org.apache.cxf.transport.http_jetty.JettyHTTPHandler.handle(JettyHTTPH >an dler.java:54) > at > org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:71 >2) at > org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandl >er Collection.java:211) > at > org.mortbay.jetty.handler.HandlerList.handle(HandlerList.java:49) > at > org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:13 >9) at org.mortbay.jetty.Server.handle(Server.java:313) > at > org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:506 >) at > org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection >.j ava:844) > at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:644) > at > org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211) > at > org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:381) > at > org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.jav >a: 396) > at > org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool. >ja va:442) > Caused by: javax.xml.bind.MarshalException > - with linked exception: > [javax.xml.bind.JAXBException: com.basistech.ws.fortest.TestException > is not known to this context] > at > com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:2 >95 ) > at > com.sun.xml.bind.v2.runtime.MarshallerImpl.marshal(MarshallerImpl.java >:2 21) > at > javax.xml.bind.helpers.AbstractMarshallerImpl.marshal(AbstractMarshall >er Impl.java:91) > at > org.apache.cxf.jaxb.JAXBEncoderDecoder.writeObject(JAXBEncoderDecoder. >ja va:192) > at > org.apache.cxf.jaxb.JAXBEncoderDecoder.marshall(JAXBEncoderDecoder.jav >a: 167) > ... 22 more > Caused by: javax.xml.bind.JAXBException: > com.basistech.ws.fortest.TestException is not known to this context > at > com.sun.xml.bind.v2.runtime.XMLSerializer.reportError(XMLSerializer.ja >va > > :223) > > at > com.sun.xml.bind.v2.runtime.XMLSerializer.reportError(XMLSerializer.ja >va > > :238) > > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(Elemen >tB eanInfoImpl.java:85) > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(Elemen >tB eanInfoImpl.java:127) > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeBody(ElementB >ea nInfoImpl.java:244) > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementB >ea nInfoImpl.java:251) > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl.serializeRoot(ElementB >ea nInfoImpl.java:33) > at > com.sun.xml.bind.v2.runtime.XMLSerializer.childAsRoot(XMLSerializer.ja >va > > :461) > > at > com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:2 >92 ) > ... 26 more > Caused by: javax.xml.bind.JAXBException: > com.basistech.ws.fortest.TestException is not known to this context > at > com.sun.xml.bind.v2.runtime.JAXBContextImpl.getBeanInfo(JAXBContextImp >l. java:538) > at > com.sun.xml.bind.v2.runtime.ElementBeanInfoImpl$1.serializeBody(Elemen >tB eanInfoImpl.java:82) > ... 32 more > Oct 18, 2007 8:22:55 PM > org.apache.cxf.interceptor.LoggingOutInterceptor$LoggingCallback > onClose -- J. Daniel Kulp Principal Engineer IONA P: 781-902-8727 C: 508-380-7194 [EMAIL PROTECTED] http://www.dankulp.com/blog
