现在位置:首页 » Mysql » java.sql.SQLException: Connections could not be acquired from the underlying database!
java.sql.SQLException: Connections could not be acquired from the underlying database!
java.sql.SQLException: Connections could not be acquired from the underlying database!
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
at com.isoft.idi.core.datasource.C3p0Pool.getDataStore(C3p0Pool.java:102)
at com.isoft.idi.core.datasource.C3p0Pool.getDataStore(C3p0Pool.java:1)
at com.isoft.idi.dijob.DataSetMapper.transform(DataSetMapper.java:117)
at com.isoft.idi.dijob.DBToFileJob.run(DBToFileJob.java:58)
at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
at com.isoft.idi.core.datasource.C3p0Pool.getDataStore(C3p0Pool.java:102)
at com.isoft.idi.core.datasource.C3p0Pool.getDataStore(C3p0Pool.java:1)
at com.isoft.idi.dijob.DataSetMapper.transform(DataSetMapper.java:117)
at com.isoft.idi.dijob.DBToFileJob.run(DBToFileJob.java:58)
at com.isofthome.idiweb.web.util.CompoundJob.run(CompoundJob.java:74)
解决一:
jdbc:sqlserver://192.168.21.102:1433/TESTSQL改为
jdbc:sqlserver://192.168.21.102:1433;databaseName=TESTSQL
解决二:
ComboPooledDataSource cpds = new ComboPooledDataSource();
// 设置超时,超时数字设置为18000就会出现上面的错误,改为180则正常了
cpds.setLoginTimeout(180);
本文固定链接:http://www.yizhi227.com/?post=62
本文由Jessie原创或编辑,互联分享,尊重版权,转载请以链接形式标明本文地址
本文由Jessie原创或编辑,互联分享,尊重版权,转载请以链接形式标明本文地址