I use the maven InstrumentTask to modify my hibernate pojos for lazy fetching . Now I want to marshal instance of this pojo into xml for which I am using jaxb.
JAXBContext.newInstance(MyEntity.class)
fails giving exception
com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 5 counts of IllegalAnnotationExceptions
net.sf.cglib.transform.impl.InterceptFieldCallback is an interface, and JAXB can't handle interfaces.
this problem is related to the following location:
at net.sf.cglib.transform.impl.InterceptFieldCallback
at public net.sf.cglib.transform.impl.InterceptFieldCallback
can I use jaxb for cglib instrumented pojos ?