[tomcat启动报错]registered the JDBC driver [com.alibaba.druid.proxy.DruidDriver] but failed to unregister it when the web application was stopped
环境:一个tomcat ,一个工程配置了多数据源,在启动的时候报如下错误:
SEVERE: The web application [/qdp-resource-job] registered the JDBC driver [com.alibaba.druid.proxy.DruidDriver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
Aug 14, 2017 3:23:27 PM org.apache.catalina.loader.WebappClassLoader clearReferencesJdbc
SEVERE: The web application [/qdp-resource-job] registered the JDBC driver [com.mysql.jdbc.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
Aug 14, 2017 3:23:27 PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Abandoned connection cleanup thread] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Create-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Destroy-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Create-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Destroy-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Create-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Destroy-] but has failed to stop it. This is very likely to create a memory leak.
Aug , :: PM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [/qdp-resource-job] appears to have started a thread named [Druid-ConnectionPool-Create-] but has failed to stop it. This is very likely to create a memory leak.
解决方法:在多数据源配置的时候,只配置一个在启动的时候进行初始化,其他的不动,如下:
<!-- 第一数据源 -->
<bean name="dataSourceResource" class="com.alibaba.druid.pool.DruidDataSource" init-method="init" destroy-method="close">
<property name="url" value="${jdbc.url}" />
<property name="username" value="${jdbc.username}" />
<property name="password" value="${jdbc.password}" />
<property name="initialSize" value="${jdbc.initialSize}" />
<property name="minIdle" value="${jdbc.minIdle}" />
<property name="maxActive" value="${jdbc.maxActive}" />
<property name="maxWait" value="${jdbc.maxWait}" />
<property name="timeBetweenEvictionRunsMillis" value="${jdbc.timeBetweenEvictionRunsMillis}" />
<property name="minEvictableIdleTimeMillis" value="${jdbc.minEvictableIdleTimeMillis}" />
<property name="validationQuery" value="${jdbc.validationQuery}" />
<property name="testWhileIdle" value="${jdbc.testWhileIdle}" />
<property name="testOnBorrow" value="${jdbc.testOnBorrow}" />
<property name="testOnReturn" value="${jdbc.testOnReturn}" />
<property name="removeAbandoned" value="${jdbc.removeAbandoned}" />
<property name="removeAbandonedTimeout" value="${jdbc.removeAbandonedTimeout}" />
<property name="filters" value="${jdbc.filters}" />
<property name="logAbandoned" value="true" />
<property name="proxyFilters">
<list>
<ref bean="log-filter"/>
</list>
</property>
</bean>
<!-- 第二数据源 -->
<bean name="dataSourceCustomer" class="com.alibaba.druid.pool.DruidDataSource" init-method="init" destroy-method="close">
<property name="url" value="${customer.url}" />
<property name="username" value="${customer.username}" />
<property name="password" value="${customer.password}" />
</bean> <!-- 第三数据源 -->
<bean name="dataSourceBuilding" class="com.alibaba.druid.pool.DruidDataSource" init-method="init" destroy-method="close">
<property name="url" value="${building.url}" />
<property name="username" value="${building.username}" />
<property name="password" value="${building.password}" />
</bean>
第二和第三数据源只保留最基础的url 、username、password 三个配置即可!
[tomcat启动报错]registered the JDBC driver [com.alibaba.druid.proxy.DruidDriver] but failed to unregister it when the web application was stopped的更多相关文章
- 解决:The web application [] registered the JDBC driver [] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
问题描述 在将Spring Boot程序打包生成的war包部署到Tomcat后,启动Tomcat时总是报错,但是直接在IDEA中启动Application或者用"java -jar" ...
- 严重: The web application [] registered the JDBC driver [com.microsoft.sqlserver.jdbc.SQLServerDriver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDB
idea项目启动报如下错误, 网上的方法都试了都没用, 一直没解决, 干掉项目, 重新从svn检出就好了...坑 啊 Root WebApplicationContext: initializatio ...
- registered the JDBC driver [com.mysql.jdbc.Driver] but failed to unregister it when the web application was stopped.
最近在用maven整合SSH做个人主页时候,在eclipse里面使用tomcat7插件发布项目是没有问题的,但当打包成war之后,使用tomcat7单独发布项目,就出现了以下的错误. 严重: Cont ...
- registered the JBDC driver [oracle.jdbc.OracleDriver] but failed to unregister it when the web application was stopped. (转)
最近项目中遇见一问题,在开发环境没有问题的代码,到了生产环境就会报如下错误: 严重: A web application registered the JBDC driver [oracle.jd ...
- The web application registered the JDBC driver * but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
最近使用了最新版的tomcat9,使用jdbc链接mysql数据库.关闭tomcat过程中出现警告 13-Sep-2017 22:22:54.369 WARNING [main] org.apache ...
- The web application [ ] registered the JDBC driver [net.sourceforge.jtds.jdbc.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver
出现以下错误时,我找了很多方法,都未解决,网上有很多,最后我实在无奈,怀疑会不会是Tomcat的原因,更换了一个版本之后就好了.The web application [ ] registered t ...
- registered the JDBC driver [com.mysql.jdbc.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered.
问题是tomcat的版本问题,tomcat新检测机制导致的这个问题,换版本可以解决问题,但不建议这么做,租用服务器不是你说换就换的.其实问题根源是BasicDataSource,BasicDataSo ...
- Tomcat启动报错org.apache.catalina.core.StandardContext.startInternal One or more listeners failed to start. Full details will be found in the appropriate container log file
错误: 今天SVN导入新项目后启动项目时控制台报错,之后在网上搜了很多方法.下面列了一些大佬的解决方案: 1. 检查日志配置文件-logging.properties:https://www.cnbl ...
- The web application [/codeMarket] registered the JBDC driver[.........] but failed to unregister it when the web application was stopped. To prevent
如果你报错了上面的这个严重,那么你的tomcat版本一定是在6.0.25之上的 原因:tomcat 6.025以后在sever.xml中引入了内存泄露侦测,对于垃圾回收不能处理的对像,它就会做日志. ...
随机推荐
- BZOJ4739 : 定向越野
起点/终点向每个圆的切点连边. 任意两个圆的公切点之间连边. 同一圆上相邻两个关键点之间连边. 然后Dijkstra求最短路即可,时间复杂度$O(n^3)$. 注意判边可行性的时候要忽略这条边来源的圆 ...
- Tarjan求强连通分量 缩点
强连通分量的定义: 在一张有向图中,如果两个点u,v之间能相互到达则称这两个点u,v是强连通的,在这个基础上如果有向图G中的任意两个顶点都强连通,那么称图G是一个强连通图.有向非强连通图的极大强连通子 ...
- 团队——League of Programers简介
团队名称 League of Programers 团队成员简介 武璧泽:编程能力较强,善于程序思路设计: 邹兰兰:擅长代码的分析.编写与调试: 倪彤炜:擅长解决代码的修正与编写,善于调节团队关系: ...
- pygame-KidsCanCode系列jumpy-part8-记录历史最高分
通常在多玩家的游戏中,每个玩家都会有自己的得分,最高分数会成为该游戏的最佳记录.这一篇,学习下如何记录最高得分:(为了简化代码,本文采用文件方式,仅记录本机得分,明白原理后,可以将得分保存在云端或数据 ...
- Linux内存管理学习资料
下面是Linux内存管理学习的一些资料. 博客 mlock() and mlockall() system calls. All about Linux swap space 逆向映射的演进 Linu ...
- 阿里云ACE深圳同城会 开始报名
大家好,阿里云 ACE深圳同城会本周末第一活动,主要大家一起聚聚,互相认识和熟悉,未来一起玩儿一起进步~ 通知大家一个好消息,当前凡是加入深圳ACE同城会组织(群)的朋友,通过跟群主报名申请,将有机会 ...
- kettle 6.1 通过JS脚本与SwitchCase结合实现目标步骤选择
场景: 判断抽取的数据在目标库中是否已经存在(同一个病人是否已经存在治疗方案号): 1.若不存在,则GROUPROWNO=1,并Insert into 目标库 ( 判断外关联字段是否为空 ) 2. ...
- testng + reportng 测试结果邮件发送
https://blog.csdn.net/qq744746842/article/details/51497506 其实大多数的时候我们的测试报告的发送可能都是结合Jenkins发送的,所以这方面更 ...
- SSE图像算法优化系列二十八:深度优化局部拉普拉斯金字塔滤波器。
基于局部拉普拉斯金字塔的Edge-aware滤波器是在2011年由Adobe 公司的研究员Sylvain Paris(大神级人物,写了很多文章)提出的,我在4年前曾经参考有关代码实现过这个算法,但是速 ...
- http重定向到https
<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.we ...