tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <rmannibu...@gmail.com>
Subject Re: IllegalAccess exception when reloading TomEE+ 7.0.1 using Apache Camel 2.18.0
Date Mon, 14 Nov 2016 10:28:56 GMT
2016-11-14 11:01 GMT+01:00 jessepeng <jan_pien@gmx.de>:

> Well, I've tried with this very simple scan.xml:
>
> <?xml version="1.0"?>
> <scan>
>         <packages>
>                 <package>de.lhind</package>
>                 <package>org.apache.deltaspike</package>
>                 <package>de.gebit.trend</package>
>                 <package>net.bootsfaces</package>
>                 <package>org.primefaces</package>
>         </packages>
> </scan>
>
> I verified that the scan.xml is correctly used by removing some packages
> from the scan.xml.
>
> But I still get the exception on reloading. By the way, this only happens
> when TomEE is reloading, when I shutdown TomEE using the normal shutdown
> script, everything works fine.
>
>
Which reloading mode? JMX/plain tomcat or eclipse?


>
> Romain Manni-Bucau wrote
> > this is clearly a "you shouldnt have scanned this class" issue. Now you
> > need to configure the scanning to solve it. scan.xml will allow you to
> ist
> > included packages/classes - can be easier if you dont really know what to
> > exclude:
> > <scan>
> > <packages>
> > <package>
> > com.company.myapp
> > </package>
> > </packages>
> > </scan>
> > in WEB-INF/
> >
> >
> >
> > Romain Manni-Bucau
> > @rmannibucau &lt;https://twitter.com/rmannibucau&gt; |  Blog
> > &lt;https://blog-rmannibucau.rhcloud.com&gt; | Old Blog
> > &lt;http://rmannibucau.wordpress.com&gt; | Github
> > &lt;https://github.com/rmannibucau&gt; |
> > LinkedIn &lt;https://www.linkedin.com/in/rmannibucau&gt; | JavaEE
> Factory
> > &lt;https://javaeefactory-rmannibucau.rhcloud.com&gt;
> >
> > 2016-11-14 10:28 GMT+01:00 jessepeng &lt;
>
> > jan_pien@
>
> > &gt;:
> >
> >> Hi,
> >>
> >> unfortunately, this doesn't seem to help. I've excluded the camel jars
> >> using
> >> both the context.xml and the system property way, but neither way gets
> >> rid
> >> of this exception. I sometimes get a slightly different exception:
> >>
> >> SCHWERWIEGEND: Exception invoking periodic operation:
> >> java.lang.NoClassDefFoundError: ch/qos/logback/classic/spi/
> ThrowableProxy
> >>         at ch.qos.logback.classic.spi.LoggingEvent.
> > <init>
> > (
> >> LoggingEvent.java:119)
> >>         at
> >> ch.qos.logback.classic.Logger.buildLoggingEventAndAppend(
> Logger.java:419)
> >>         at ch.qos.logback.classic.Logger.filterAndLog_0_Or3Plus(Logger.
> >> java:383)
> >>         at ch.qos.logback.classic.Logger.warn(Logger.java:692)
> >>         at
> >> org.apache.camel.impl.DefaultCamelContext.doStop(
> >> DefaultCamelContext.java:3177)
> >>         at org.apache.camel.support.ServiceSupport.stop(
> >> ServiceSupport.java:102)
> >>         at
> >> org.apache.camel.cdi.CamelContextProducer.dispose(
> >> CamelContextProducer.java:108)
> >>         at
> >> org.apache.camel.cdi.CamelContextProducer.dispose(
> >> CamelContextProducer.java:48)
> >>         at org.apache.camel.cdi.DelegateProducer.dispose(
> >> DelegateProducer.java:39)
> >>         at
> >> org.apache.camel.cdi.CamelContextInjectionTarget.preDestroy(
> >> CamelContextInjectionTarget.java:33)
> >>         at
> >> org.apache.camel.cdi.CamelContextInjectionTarget.preDestroy(
> >> CamelContextInjectionTarget.java:24)
> >>         at org.apache.camel.cdi.SyntheticBean.destroy(
> >> SyntheticBean.java:69)
> >>         at
> >> org.apache.webbeans.component.third.ThirdpartyBeanImpl.
> >> destroy(ThirdpartyBeanImpl.java:114)
> >>         at
> >> org.apache.webbeans.context.AbstractContext.destroyInstance(
> >> AbstractContext.java:206)
> >>         at
> >> org.apache.webbeans.context.AbstractContext.destroyInstance(
> >> AbstractContext.java:192)
> >>         at
> >> org.apache.webbeans.context.ApplicationContext.destroy(
> >> ApplicationContext.java:73)
> >>         at
> >> org.apache.webbeans.web.context.WebContextsService.
> >> destroyApplicationContext(WebContextsService.java:619)
> >>         at
> >> org.apache.webbeans.web.context.WebContextsService.
> >> endContext(WebContextsService.java:231)
> >>         at
> >> org.apache.openejb.cdi.OpenEJBLifecycle.stopApplication(
> >> OpenEJBLifecycle.java:287)
> >>         at
> >> org.apache.openejb.assembler.classic.Assembler.
> >> destroyApplication(Assembler.java:2128)
> >>         at
> >> org.apache.openejb.assembler.classic.Assembler.
> >> destroyApplication(Assembler.java:2079)
> >>         at
> >> org.apache.tomee.catalina.TomcatWebAppBuilder.afterStop(
> >> TomcatWebAppBuilder.java:2012)
> >>         at
> >> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(
> >> GlobalListenerSupport.java:126)
> >>         at
> >> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(
> >> LifecycleBase.java:94)
> >>         at
> >> org.apache.catalina.util.LifecycleBase.setStateInternal(
> >> LifecycleBase.java:401)
> >>         at org.apache.catalina.util.LifecycleBase.stop(
> >> LifecycleBase.java:249)
> >>         at
> >> org.apache.catalina.core.StandardContext.reload(
> StandardContext.java:3764)
> >>         at
> >> org.apache.catalina.loader.WebappLoader.backgroundProcess(
> >> WebappLoader.java:293)
> >>         at
> >> org.apache.tomee.catalina.TomEEWebappLoader.backgroundProcess(
> >> TomEEWebappLoader.java:59)
> >>         at
> >> org.apache.tomee.catalina.LazyStopLoader.backgroundProcess(
> >> LazyStopLoader.java:105)
> >>         at
> >> org.apache.catalina.core.StandardContext.backgroundProcess(
> >> StandardContext.java:5534)
> >>         at
> >> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.
> >> processChildren(ContainerBase.java:1374)
> >>         at
> >> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.
> >> processChildren(ContainerBase.java:1378)
> >>         at
> >> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.
> >> processChildren(ContainerBase.java:1378)
> >>         at
> >> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.
> >> run(ContainerBase.java:1346)
> >>         at java.lang.Thread.run(Thread.java:745)
> >> Caused by: java.lang.ClassNotFoundException: Illegal access: this web
> >> application instance has been stopped already. Could not load
> >> [ch.qos.logback.classic.spi.ThrowableProxy]. The following stack trace
> is
> >> thrown for debugging purposes as well as to attempt to terminate the
> >> thread
> >> which caused the illegal access.
> >>         at
> >> org.apache.catalina.loader.WebappClassLoaderBase.
> >> checkStateForClassLoading(WebappClassLoaderBase.java:1292)
> >>         at
> >> org.apache.catalina.loader.WebappClassLoaderBase.loadClass(
> >> WebappClassLoaderBase.java:1155)
> >>         at
> >> org.apache.tomee.catalina.TomEEWebappClassLoader.loadClass(
> >> TomEEWebappClassLoader.java:201)
> >>         at
> >> org.apache.catalina.loader.WebappClassLoaderBase.loadClass(
> >> WebappClassLoaderBase.java:1116)
> >>         ... 36 more
> >> Caused by: java.lang.IllegalStateException: Illegal access: this web
> >> application instance has been stopped already. Could not load
> >> [ch.qos.logback.classic.spi.ThrowableProxy]. The following stack trace
> is
> >> thrown for debugging purposes as well as to attempt to terminate the
> >> thread
> >> which caused the illegal access.
> >>         at
> >> org.apache.catalina.loader.WebappClassLoaderBase.
> >> checkStateForResourceLoading(WebappClassLoaderBase.java:1302)
> >>         at
> >> org.apache.catalina.loader.WebappClassLoaderBase.
> >> checkStateForClassLoading(WebappClassLoaderBase.java:1290)
> >>         ... 39 more
> >>
> >> But even excluding logback from the scanned jars doesn't help.
> >>
> >>
> >>
> >> --
> >> View this message in context: http://tomee-openejb.979440.
> >> n4.nabble.com/IllegalAccess-exception-when-reloading-
> >> TomEE-7-0-1-using-Apache-Camel-2-18-0-tp4680514p4680523.html
> >> Sent from the TomEE Users mailing list archive at Nabble.com.
> >>
>
>
>
>
>
> --
> View this message in context: http://tomee-openejb.979440.
> n4.nabble.com/IllegalAccess-exception-when-reloading-
> TomEE-7-0-1-using-Apache-Camel-2-18-0-tp4680514p4680525.html
> Sent from the TomEE Users mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message