users@jersey.java.net

Re: [Jersey] Problem: Jersey swallows all JAXP exceptions silently !

From: Morten <mortench2004_at_yahoo.dk>
Date: Fri, 24 Jul 2009 10:33:55 +0000 (GMT)

--- Den fre 24/7/09 skrev Paul Sandoz <Paul.Sandoz@Sun.COM>: > What HTTP container are you using? I am using Sun's HTTPSERVER > If there is an error marshalling the JAXB object then > Jersey will throw an IOException to the underlying HTTP > container, as the code in the previous email presented > (also, any other RuntimeException, expect for > WebApplicationException in certain cases, will go directly > to the underlying HTTP container). > > My current guess is that the underlying HTTP container > seems to be ignoring the IOException (which wraps a > JAXBException) thrown to the underlying HTTP container. Hmm. Maybe > Is a JAXBException or a sub-class of thrown? Not sure about the class. My last email and trace was cut by my email client. I will try again with some more details here I hope it is not cut again. IllegalAnnotationExceptions ....(JAXB annotation is placed on a method that is not a JAXB property)... at com.sun.xml.internal.bind.v2.runtime.IllegalAnnotationsException$Builder.check(IllegalAnnotationsException.java:66) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(JAXBContextImpl.java:422) at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.java:270) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(ContextFactory.java:103) at com.sun.xml.internal.bind.v2.ContextFactory.createContext(ContextFactory.java:81) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:202) at javax.xml.bind.ContextFinder.find(ContextFinder.java:376) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:574) at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:522) Thanks for looking into this. Cheers, Morten __________________________________________________________ Find din nye laptop på kelkoo.dk. Se de gode tilbud her - http://dk.yahoo.com/r/pat/mm