[jboss-user] [Installation, Configuration & DEPLOYMENT] - LinkageError... and yet everything seems fine
nicdo77
do-not-reply at jboss.com
Tue Jan 29 07:46:24 EST 2008
Hi,
I have an app running under JBoss4.0.5.
I have a quartz task, supposed to do some file parsing and then send a mail with a file attached. Before implementing this task, i didnt have any Linkage problem with my mail and activation librairies.
But now when the task launches, i get the following:
javax.ejb.EJBException: com.thalys.opalys.business.MailServiceException: loader constraints violated when linking javax/activation/DataHandler class
| at com.thalys.opalys.business.ejb.MailServiceBean.sendAttachmentMail(MailServiceBean.java:53)
| 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:585)
| at org.jboss.invocation.Invocation.performCall(Invocation.java:359)
| at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:237)
| at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:158)
| at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:169)
| at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
| at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
| at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
| at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
| at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:168)
| at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
| at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:136)
| at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:648)
| at org.jboss.ejb.Container.invoke(Container.java:954)
| at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:430)
| at org.jboss.ejb.plugins.local.StatelessSessionProxy.invoke(StatelessSessionProxy.java:103)
| at $Proxy91.sendAttachmentMail(Unknown Source)
| 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:585)
| at org.springframework.ejb.access.LocalSlsbInvokerInterceptor.invoke(LocalSlsbInvokerInterceptor.java:71)
| at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:169)
| at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:169)
| at $Proxy124.sendAttachmentMail(Unknown Source)
| at com.thalys.opalys.schedule.WifiRequestSenderJob.doIt(WifiRequestSenderJob.java:55)
| 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:585)
| at org.springframework.util.MethodInvoker.invoke(MethodInvoker.java:248)
| at org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean$MethodInvokingJob.executeInternal(MethodInvokingJobDetailFactoryBean.java:198)
| at org.springframework.scheduling.quartz.QuartzJobBean.execute(QuartzJobBean.java:90)
| at org.quartz.core.JobRunShell.run(JobRunShell.java:203)
| at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:520)
| Caused by: com.thalys.opalys.business.MailServiceException: loader constraints violated when linking javax/activation/DataHandler class
| at com.thalys.opalys.business.MailServiceBase.sendAttachmentMail(MailServiceBase.java:105)
| 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:585)
| at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:291)
| at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:180)
| at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:147)
| at org.springframework.orm.hibernate3.HibernateInterceptor.invoke(HibernateInterceptor.java:88)
| at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:169)
| at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:169)
| at $Proxy124.sendAttachmentMail(Unknown Source)
| at com.thalys.opalys.business.ejb.MailServiceBean.sendAttachmentMail(MailServiceBean.java:44)
| ... 38 more
| Caused by: java.lang.LinkageError: loader constraints violated when linking javax/activation/DataHandler class
| at org.springframework.mail.javamail.MimeMessageHelper.addAttachment(MimeMessageHelper.java:966)
| at org.springframework.mail.javamail.MimeMessageHelper.addAttachment(MimeMessageHelper.java:987)
| at com.thalys.opalys.business.MailServiceImpl.handleSendAttachmentMail(MailServiceImpl.java:73)
| at com.thalys.opalys.business.MailServiceBase.sendAttachmentMail(MailServiceBase.java:101)
| ... 50 more
But i checked in my JMX console, i tried displayClassInfo() on "javax/activation/DataHandler" and i get the following
javax/activation/DataHandler Information
| Not loaded in repository cache
|
|
| ### Instance0 found in UCL: org.jboss.mx.loading.UnifiedClassLoader3 at 297ba3{ url=null ,addedOrder=2}
|
which is Ok according to the JBoss wiki available here about LinkageError: http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassCastExceptions
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4124379#4124379
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4124379
More information about the jboss-user
mailing list