HTTP Status 500 - java.sql.SQLException: Connections could not be acquired from the underlying database!
type Exception report
message java.sql.SQLException: Connections could not be acquired from the underlying database!
description The server encountered an internal error that prevented it from fulfilling this request.
exception java.lang.RuntimeException: java.sql.SQLException: Connections could not be acquired from the underlying database! cn.login.LoginDao.sel(LoginDao.java:18) cn.login.LoginServlet.doPost(LoginServlet.java:33) javax.servlet.http.HttpServlet.service(HttpServlet.java:648) javax.servlet.http.HttpServlet.service(HttpServlet.java:729) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
root cause java.sql.SQLException: Connections could not be acquired from the underlying database! com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:118) com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:690) com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:140) org.apache.commons.dbutils.AbstractQueryRunner.prepareConnection(AbstractQueryRunner.java:204) org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:287) cn.login.LoginDao.sel(LoginDao.java:16) cn.login.LoginServlet.doPost(LoginServlet.java:33) javax.servlet.http.HttpServlet.service(HttpServlet.java:648) javax.servlet.http.HttpServlet.service(HttpServlet.java:729) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
root cause com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source. com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1463) com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:639) com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:549) com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutAndMarkConnectionInUse(C3P0PooledConnectionPool.java:756) com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:683) com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:140) org.apache.commons.dbutils.AbstractQueryRunner.prepareConnection(AbstractQueryRunner.java:204) org.apache.commons.dbutils.QueryRunner.query(QueryRunner.java:287) cn.login.LoginDao.sel(LoginDao.java:16) cn.login.LoginServlet.doPost(LoginServlet.java:33) javax.servlet.http.HttpServlet.service(HttpServlet.java:648) javax.servlet.http.HttpServlet.service(HttpServlet.java:729) org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
note The full stack trace of the root cause is available in the Apache Tomcat/8.0.23 logs.
Apache Tomcat/8.0.23