@wenshao 你好,想跟你请教个问题:druid 在 apache tomcat 里面经常要出现这样的报错,百度了很久不得其解。
九月 17, 2014 9:53:31 上午 org.apache.catalina.loader.WebappClassLoader loadClass
信息: Illegal access: this web application instance has been stopped already. Could not load com.mysql.jdbc.ProfilerEventHandlerFactory. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1612)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1571)
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:169)
at com.alibaba.druid.filter.FilterAdapter.connection_close(FilterAdapter.java:776)
at com.alibaba.druid.filter.logging.LogFilter.connection_close(LogFilter.java:415)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:165)
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.close(ConnectionProxyImpl.java:115)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
Exception in thread "Druid-ConnectionPool-Destory-806406583" java.lang.NoClassDefFoundError: com/mysql/jdbc/ProfilerEventHandlerFactory
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:169)
at com.alibaba.druid.filter.FilterAdapter.connection_close(FilterAdapter.java:776)
at com.alibaba.druid.filter.logging.LogFilter.connection_close(LogFilter.java:415)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:165)
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.close(ConnectionProxyImpl.java:115)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.ProfilerEventHandlerFactory
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1720)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1571)
... 10 more
[Druid-ConnectionPool-Destory-116271079] DEBUG druid.sql.Connection - {conn-10001} closed
Exception in thread "Druid-ConnectionPool-Destory-2069188819" java.lang.NoClassDefFoundError: com/mysql/jdbc/ProfilerEventHandlerFactory
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
九月 17, 2014 9:53:31 上午 org.apache.catalina.loader.WebappClassLoader loadClass
信息: Illegal access: this web application instance has been stopped already. Could not load com.mysql.jdbc.ProfilerEventHandlerFactory. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1612)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1571)
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:169)
at com.alibaba.druid.filter.FilterAdapter.connection_close(FilterAdapter.java:776)
at com.alibaba.druid.filter.logging.LogFilter.connection_close(LogFilter.java:415)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:165)
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.close(ConnectionProxyImpl.java:115)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
Exception in thread "Druid-ConnectionPool-Destory-806406583" java.lang.NoClassDefFoundError: com/mysql/jdbc/ProfilerEventHandlerFactory
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:169)
at com.alibaba.druid.filter.FilterAdapter.connection_close(FilterAdapter.java:776)
at com.alibaba.druid.filter.logging.LogFilter.connection_close(LogFilter.java:415)
at com.alibaba.druid.filter.FilterChainImpl.connection_close(FilterChainImpl.java:165)
at com.alibaba.druid.proxy.jdbc.ConnectionProxyImpl.close(ConnectionProxyImpl.java:115)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.ProfilerEventHandlerFactory
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1720)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1571)
... 10 more
[Druid-ConnectionPool-Destory-116271079] DEBUG druid.sql.Connection - {conn-10001} closed
Exception in thread "Druid-ConnectionPool-Destory-2069188819" java.lang.NoClassDefFoundError: com/mysql/jdbc/ProfilerEventHandlerFactory
at com.mysql.jdbc.ConnectionImpl.realClose(ConnectionImpl.java:4677)
at com.mysql.jdbc.ConnectionImpl.close(ConnectionImpl.java:1615)
at com.alibaba.druid.util.JdbcUtils.close(JdbcUtils.java:82)
at com.alibaba.druid.pool.DruidDataSource.shrink(DruidDataSource.java:1915)
at com.alibaba.druid.pool.DruidDataSource$DestroyConnectionThread.run(DruidDataSource.java:1733)
我也是这样。。。
@wenshao
多个mysqldriver混在一起冲突了?druid需要和mysql版本对应吗,我这边也出现这个问题就用了一个啊,没多个。。jar包冲突~~~~~能具体一点不?
thiswebapplicationinstancehasbeenstoppedalready.---实例已经停止
因此不能假造 com.mysql.jdbc.ProfilerEventHandlerFactory
又或者
Druid-ConnectionPool-Destory-806406583
com/mysql/jdbc/ProfilerEventHandlerFactory-----可能
Druid要求的mysql的驱动包的版本相对较高
那么最后这个问题究竟是如何解决的呢,没人回答?
这问题解决了没?解决了没?
挖坟
版权声明:本文内容由阿里云实名注册用户自发贡献,版权归原作者所有,阿里云开发者社区不拥有其著作权,亦不承担相应法律责任。具体规则请查看《阿里云开发者社区用户服务协议》和《阿里云开发者社区知识产权保护指引》。如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。