Tomcat启动项目出现com.mchange.v2.async.ThreadPoolAsynchronousRunner$DeadlockDetector错误

今天一回到工作室就听说我们的项目挂了,赶紧打开远程服务器看看什么问题,结果是:


2015-6-22 0:02:49 com.mchange.v2.async.ThreadPoolAsynchronousRunner$DeadlockDetector run
警告: com.mchange.v2.async.ThreadPoolAsynchronousRunner$DeadlockDetector@1862e6 -- APPARENT DEADLOCK!!! Creating emergency threads for unassigned pending tasks!
2015-6-22 0:07:56 com.mchange.v2.async.ThreadPoolAsynchronousRunner$DeadlockDetector run
警告: com.mchange.v2.async.ThreadPoolAsynchronousRunner$DeadlockDetector@1862e6 -- APPARENT DEADLOCK!!! Complete Status: 
Managed Threads: 3
Active Threads: 3
Active Tasks: 
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask@fd5189 (com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#0)
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask@f41cc1 (com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#2)
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask@8bed73 (com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#1)
Pending Tasks: 
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask@92259c
Pool thread stack traces:
Thread[com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#0,5,main]
java.lang.Object.wait(Native Method)
java.lang.Object.wait(Object.java:485)
java.net.InetAddress.checkLookupTable(InetAddress.java:1266)
java.net.InetAddress.getAddressFromNameService(InetAddress.java:1189)
java.net.InetAddress.getAllByName0(InetAddress.java:1153)
java.net.InetAddress.getAllByName(InetAddress.java:1083)
java.net.InetAddress.getAllByName(InetAddress.java:1019)
java.net.InetAddress.getByName(InetAddress.java:969)
java.net.InetSocketAddress.(InetSocketAddress.java:124)
java.net.Socket.(Socket.java:180)
com.microsoft.sqlserver.jdbc.TDSChannel.open(IOBuffer.java:366)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1178)
com.microsoft.sqlserver.jdbc.SQLServerConnection.loginWithoutFailover(SQLServerConnection.java:1054)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:758)
com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:842)
com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:134)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:182)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:171)
com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:137)
com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1014)
com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:32)
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1810)
com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)
Thread[com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#2,5,main]
java.lang.Object.wait(Native Method)
java.lang.Object.wait(Object.java:485)
java.net.InetAddress.checkLookupTable(InetAddress.java:1266)
java.net.InetAddress.getAddressFromNameService(InetAddress.java:1189)
java.net.InetAddress.getAllByName0(InetAddress.java:1153)
java.net.InetAddress.getAllByName(InetAddress.java:1083)
java.net.InetAddress.getAllByName(InetAddress.java:1019)
java.net.InetAddress.getByName(InetAddress.java:969)
java.net.InetSocketAddress.(InetSocketAddress.java:124)
java.net.Socket.(Socket.java:180)
com.microsoft.sqlserver.jdbc.TDSChannel.open(IOBuffer.java:366)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1178)
com.microsoft.sqlserver.jdbc.SQLServerConnection.loginWithoutFailover(SQLServerConnection.java:1054)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:758)
com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:842)
com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:134)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:182)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:171)
com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:137)
com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1014)
com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:32)
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1810)
com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)
Thread[com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread-#1,5,main]
java.lang.Object.wait(Native Method)
java.lang.Object.wait(Object.java:485)
java.net.InetAddress.checkLookupTable(InetAddress.java:1266)
java.net.InetAddress.getAddressFromNameService(InetAddress.java:1189)
java.net.InetAddress.getAllByName0(InetAddress.java:1153)
java.net.InetAddress.getAllByName(InetAddress.java:1083)
java.net.InetAddress.getAllByName(InetAddress.java:1019)
java.net.InetAddress.getByName(InetAddress.java:969)
java.net.InetSocketAddress.(InetSocketAddress.java:124)
java.net.Socket.(Socket.java:180)
com.microsoft.sqlserver.jdbc.TDSChannel.open(IOBuffer.java:366)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connectHelper(SQLServerConnection.java:1178)
com.microsoft.sqlserver.jdbc.SQLServerConnection.loginWithoutFailover(SQLServerConnection.java:1054)
com.microsoft.sqlserver.jdbc.SQLServerConnection.connect(SQLServerConnection.java:758)
com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(SQLServerDriver.java:842)
com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:134)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:182)
com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:171)
com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool$1PooledConnectionResourcePoolManager.acquireResource(C3P0PooledConnectionPool.java:137)
com.mchange.v2.resourcepool.BasicResourcePool.doAcquire(BasicResourcePool.java:1014)
com.mchange.v2.resourcepool.BasicResourcePool.access$800(BasicResourcePool.java:32)
com.mchange.v2.resourcepool.BasicResourcePool$AcquireTask.run(BasicResourcePool.java:1810)
com.mchange.v2.async.ThreadPoolAsynchronousRunner$PoolThread.run(ThreadPoolAsynchronousRunner.java:547)


一开始有点纳闷,一直好好的怎么会突然报错,而且是SQL的连接问题,就是说并不是用户错误操作而是项目配置出了错,于是仔细查看了项目的配置和导包情况,发现配置并未被修改,而且JDBC包也没有被误删,那是什么情况呢?

上网找了一下,大多都说是配置的密码啊什么之类出错,但我这里并没有错呢。。。

然后看到一个大神的微博上写他是因为数据库没有创建对应的database才出错的,由此找到灵感,想了想莫非是项目找不到数据库里面的对应的database?

但配置又没错,数据库又早已建好而且这个项目运行了一个学期之久了都没问题。。。

于是想到了难道是与数据库验证有关?

重新打开远程服务器里面的SQL Server,发现登录身份验证不知道被谁改成了“windows 身份验证”了,然后我就把他改为“SQL Server 身份验证”,用户名为“sa”,密码也写好,登录验证确认一下,最后重启Tomcat,发现正常开启了!!

你可能感兴趣的:(Tomcat异常笔记)