tag:blogger.com,1999:blog-1710464868724994296.post1847950492963863410..comments2023-06-29T09:48:09.653-04:00Comments on Java XML and JSON Binding: MOXy as Your JAX-RS JSON Provider - Client SideBlaise Doughanhttp://www.blogger.com/profile/02016807982653343777noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-1710464868724994296.post-42618481272422290922014-05-06T13:46:28.455-04:002014-05-06T13:46:28.455-04:00Thanks for this. I was using Jettison + JDK's ...Thanks for this. I was using Jettison + JDK's JAXB and Jettison won't ignore the root element. MOXy's ability to ignore the root element when generating JSON is most welcome. Didn't want a nested document when inserting into ElasticSearch.Michaelhttps://www.blogger.com/profile/04222042011928938178noreply@blogger.comtag:blogger.com,1999:blog-1710464868724994296.post-16934724142220884302013-01-08T08:17:58.659-05:002013-01-08T08:17:58.659-05:00Very Good Example of REST and JSONVery Good Example of REST and JSONAnonymoushttps://www.blogger.com/profile/15395267544468820300noreply@blogger.comtag:blogger.com,1999:blog-1710464868724994296.post-51514290421654316762012-05-25T13:58:28.077-04:002012-05-25T13:58:28.077-04:00Hi,
I apologize for the delay in responding, the ...Hi,<br /><br />I apologize for the delay in responding, the EclipseLink 2.4.0 release is rapidly approaching and has been my primary focus lately. By default a JAXB (JSR-222) implementation will use the public accessors, this will trigger the lazy relationships set up by the JPA implementation. For your use case I would recommend using JAXB with <i>@XmlAccessorType(XmlAccessType.FIELD)</i>. The field should be null if it has not been realized yet, and by default will not be marshalled.<br />- <a href="http://blog.bdoughan.com/2011/06/using-jaxbs-xmlaccessortype-to.html" rel="nofollow">Using JAXB's @XmlAccessorType to Configure Field or Property Access</a><br />- <a href="http://blog.bdoughan.com/2012/04/binding-to-json-xml-handling-null.html" rel="nofollow">Binding to JSON & XML - Handling Null </a><br /><br />-BlaiseBlaise Doughanhttps://www.blogger.com/profile/02016807982653343777noreply@blogger.comtag:blogger.com,1999:blog-1710464868724994296.post-71151278628936878182012-05-15T06:24:26.518-04:002012-05-15T06:24:26.518-04:00Hi,
I am using moxy as the jaxb provider in my ap...Hi,<br /><br />I am using moxy as the jaxb provider in my application.When i am marshalling an JPA entity<br />it ends up by populating all the attributes even lazy initialized ones.But as per my requirement only non-lazy attributes should be populated.Is it a bug in moxy or normal behavior.Prasobh PKnoreply@blogger.com