JAXBElement Linkage error in AEM 6
Hi ,
I am using JDK 7 ,AEM 6
I am using axis 1.4.1 to consume a soap service . I have generated my utility classes using XJC from schema.
I am able to hit the service from osgi after getting string as xml response I am marshalling it to JAXB .where I am getting below error.
Please suggest any solution to this .
org.apache.sling.commons.scheduler.impl.QuartzScheduler Exception during job execution of com.hrdi.scheduler.ATGToDAMScheduler@30fdc9e8 : loader constraint violation: when resolving method "javax.xml.bind.JAXBElement.<init>(Ljavax/xml/namespace/QName;Ljava/lang/Class;Ljava/lang/Object;)V" the class loader (instance of org/apache/felix/framework/BundleWiringImpl$BundleClassLoaderJava5) of the current class, com/hrdi/utils/HoltXmlUtil, and the class loader (instance of <bootloader>) for resolved class, javax/xml/bind/JAXBElement, have different Class objects for the type ava/lang/Object;)V used in the signature
java.lang.LinkageError: loader constraint violation: when resolving method "javax.xml.bind.JAXBElement.<init>(Ljavax/xml/namespace/QName;Ljava/lang/Class;Ljava/lang/Object;)V" the class loader (instance of org/apache/felix/framework/BundleWiringImpl$BundleClassLoaderJava5) of the current class, com/hrdi/utils/HoltXmlUtil, and the class loader (instance of <bootloader>) for resolved class, javax/xml/bind/JAXBElement, have different Class objects for the type ava/lang/Object;)V used in the signature
at com.hrdi.utils.HoltXmlUtil.ConvertToXML(HoltXmlUtil.java:32)
at com.hrdi.scheduler.MetaDataHelper.invokeATGProductFeedService(MetaDataHelper.java:71)
at com.hrdi.scheduler.ATGToDAMScheduler.run(ATGToDAMScheduler.java:50)
at org.apache.sling.commons.scheduler.impl.QuartzJobExecutor.execute(QuartzJobExecutor.java:105)
at org.quartz.core.JobRunShell.run(JobRunShell.java:207)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)