I am going to backtrack just a little. Only ONE of our browser based calls gets the exception. All other browser based calls perform natural translation without error. We cannot determine why they are different at this point.
Gene
From: Jordi Domingo [mailto:noseya_at_hotmail.com]
Sent: Monday, September 14, 2009 10:55
To: users_at_jersey.dev.java.net
Subject: RE: [Jersey] confusing exception
Hi George,
In my case the exception is thrown when deploying the application and JSONJaxbContext gets loaded.
Jordi
> Date: Mon, 14 Sep 2009 10:45:59 -0600
> From: george.turner_at_lmco.com
> To: users_at_jersey.dev.java.net
> Subject: RE: [Jersey] confusing exception
>
> I have taken the JAXB2.2 jars (all of the api jars) and copied them into both the JDK6/lib/endorsed and the glassfish lib/endorsed (even though this duplicates the classes bundled by Metro in the webservices-api.jar that is ALSO in lib/endorsed) and the exception does not go away. It would help a lot to troubleshoot this if we could figure out what is going on and a better explanation of the exception. As it occurs whatever we do but still works, we cannot determine the cause.
>
> Also, we have SEVERAL services all using the natural notation, called from GWT/Javascript clients and there is never an exception thrown, BUT, the exception is thrown EVERY time when called by a Jersey client. This means that there is something be set or not set by the Jersey client to induce the exception that DOES NOT OCCUR when the client is a browser, either IE or Firefox.
>
> Thanks
>
> Gene
>
> -----Original Message-----
> From: Jakub.Podlesak_at_Sun.COM [mailto:Jakub.Podlesak_at_Sun.COM]
> Sent: Monday, September 14, 2009 02:43
> To: users_at_jersey.dev.java.net
> Subject: Re: [Jersey] confusing exception
>
> On Mon, Sep 14, 2009 at 10:01:06AM +0200, Jakub Podlesak wrote:
> > On Fri, Sep 11, 2009 at 07:48:34AM -0600, Turner, George wrote:
> > > I am already working another test case for a memory leak in Metro, so this one will have to wait.
> >
> > O.K.
> >
> > > For the moment though, I would like to confirm some versioning here.
> > >
> > > I am using Glassfish V2.1 with Metro 2.0 and Jdk6u16. The version of Jaxb that is packaged with Metro should be recent enough for the Jersey 1.1.2, or am I mistaken?
>
> So Metro in GlassFish v2.1 is bundling JAXB v2.1.6, which is not sufficient for Jersey, namely when you want to use the natural JSON notation.
>
> You would need to bundle JAXB v2.1.12 jars with your application war archive to make the natural thing work with GFv2.1. I was told, JAXB bundled with Metro will be upgraded when Metro 2.0 is released. This should happen together with GFv3 release sometime on November.
>
> ~Jakub
>
> >
> > Is the jaxb-api jar placed in the lib/endorsed subdirectory of your GFv2 domain?
> > I need to check with metro guys the JAXB version, but generally since
> > JDK6 bundles JAXB, you need to use endorsed mechanism here to pick up the right jars.
> >
> > ~Jakub
> >
> > >
> > > Thanks
> > >
> > > Gene
> > >
> > > -----Original Message-----
> > > From: Jakub.Podlesak_at_Sun.COM [mailto:Jakub.Podlesak_at_Sun.COM]
> > > Sent: Friday, September 11, 2009 00:59
> > > To: users_at_jersey.dev.java.net
> > > Subject: Re: [Jersey] confusing exception
> > >
> > > On Fri, Sep 11, 2009 at 03:50:26AM +0200, Jordi Domingo wrote:
> > > >
> > > > I was going to ask the same question.I'm using natural notation, JDK6u12 (i tried jdk6u16 a few mins ago) and Glassfish v3 b62.
> > > > I tried adding Jaxb 2.1.11 in my project and setting <class-loader
> > > > delegate="false"/> but this generates another exception (even if
> > > > this works its a very ugly solution..)
> > >
> > > The version 2.1.12 (2.1.11 is not sufficient) of JAXB is needed when using natural notation in Jersey. If you installed Jersey via GFv3 update-center client, this should work out of the box without a need to bundle anything with your application war file.
> > >
> > >
> > > Can you please log an issue with your project attached as a reproducible test case?
> > > If you do not want to make it public, please e-mail directly to me.
> > >
> > > Another issue is, that the error message should be properly localized, i.e. still in English, but more verbose and informative in this case. It seems [1] is back again.
> > > Will try to check out once i get your test case.
> > >
> > > Thanks,
> > >
> > > ~Jakub
> > >
> > > [1]https://jersey.dev.java.net/issues/show_bug.cgi?id=276
> > >
> > >
> > >
> > > > Thanks for your help.
> > > > Jordi
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > _________________________________________________________________
> > > > Messenger cumple 10 años ¡Descárgate ya los nuevos emoticonos!
> > > > http://www.vivelive.com/felicidades
> > >
> > > --
> > > Jakub Podlešák, Software Engineer
> > > Web Services and Technologies, SUN Microsystems
> > > http://blogs.sun.com/japod
> > >
> > > --------------------------------------------------------------------
> > > - To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> > > For additional commands, e-mail: users-help_at_jersey.dev.java.net
> > >
> >
> > --
> > Jakub Podlešák, Software Engineer
> > Web Services and Technologies, SUN Microsystems
> > http://blogs.sun.com/japod
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> > For additional commands, e-mail: users-help_at_jersey.dev.java.net
> >
>
> --
> Jakub Podlešák, Software Engineer
> Web Services and Technologies, SUN Microsystems
> http://blogs.sun.com/japod
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>
________________________________
Messenger cumple 10 años ¡Descárgate ya los nuevos emoticonos!<
http://www.vivelive.com/felicidades>