Home >Database >Mysql Tutorial >connection-Connection has been abandoned :java.lang.Exception

connection-Connection has been abandoned :java.lang.Exception

WBOY
WBOYOriginal
2016-06-06 09:44:013845browse

connectionmysqljavadbcpexception

使用的DBCP连接池和Mysql数据库,偶尔会出现这种异常,不知是什么导致的,并且在出现这个异常的地方进行对Exception的catch,但是奇怪的时捕获不了这种异常,异常一直被传回虚拟机然后打印,请哪位大侠指导一下,具体的异常如下

警告: Connection has been abandoned PooledConnection[com.mysql.jdbc.Connection@5
17667bd]:java.lang.Exception
at org.apache.tomcat.jdbc.pool.ConnectionPool.getThreadDump(ConnectionPo
ol.java:1062)
at org.apache.tomcat.jdbc.pool.ConnectionPool.createConnection(Connectio
nPool.java:704)
at org.apache.tomcat.jdbc.pool.ConnectionPool.borrowConnection(Connectio
nPool.java:631)
at org.apache.tomcat.jdbc.pool.ConnectionPool.init(ConnectionPool.java:4
85)
at org.apache.tomcat.jdbc.pool.ConnectionPool.(ConnectionPool.java
:143)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.pCreatePool(DataSourcePro
xy.java:116)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.createPool(DataSourceProx
y.java:103)
at org.apache.tomcat.jdbc.pool.DataSourceProxy.getConnection(DataSourceP
roxy.java:127)
at analyseutil.dbmanager.C3P0ConnectionPool.getConnection(C3P0Connection
Pool.java:38)
at analyseutil.dbmanager.DBManager.findCompanyByName(DBManager.java:41)
at datastore.InsertOrUpdate.handleNextData(InsertOrUpdate.java:108)
at datastore.InsertOrUpdate$1.run(InsertOrUpdate.java:48)
at java.lang.Thread.run(Thread.java:662)

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn