[Solved] Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!

The web project reports an error when executing the query:
Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!

19:27:26,672 ERROR [STDERR] org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; Connections could not be acquired from the underlying database!; nested exception is java.sql.SQLException: Connections could not be acquired from the underlying database!
19:27:26,672 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83)
19:27:26,672 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:27:26,672 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:27:26,672 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertJdbcAccessException(HibernateAccessor.java:424)
19:27:26,673 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:410)
19:27:26,673 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)
19:27:26,673 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
19:27:26,673 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:912)
19:27:26,673 ERROR [STDERR] 	at com.springtest.common.dao.GenericHibernateDao.find(GenericHibernateDao.java:224)
19:27:26,673 ERROR [STDERR] 	at com.springtest.system.service.LoginService.findTBaseUser(LoginService.java:25)
19:27:26,673 ERROR [STDERR] 	at com.springtest.system.action.LoginAction.login(LoginAction.java:39)
19:27:26,673 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
19:27:26,673 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
19:27:26,673 ERROR [STDERR] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
19:27:26,673 ERROR [STDERR] 	at java.lang.reflect.Method.invoke(Method.java:597)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
19:27:26,673 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
19:27:26,673 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
19:27:26,673 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
19:27:26,673 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:27:26,673 ERROR [STDERR] 	at com.springtest.common.filter.LoginFilter.doFilter(LoginFilter.java:48)
19:27:26,673 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:27:26,673 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:27:26,673 ERROR [STDERR] 	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
19:27:26,674 ERROR [STDERR] 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:27:26,674 ERROR [STDERR] 	at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
19:27:26,674 ERROR [STDERR] 	at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
19:27:26,674 ERROR [STDERR] 	at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
19:27:26,674 ERROR [STDERR] 	at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
19:27:26,674 ERROR [STDERR] 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
19:27:26,674 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
19:27:26,674 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
19:27:26,674 ERROR [STDERR] 	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
19:27:26,674 ERROR [STDERR] 	at java.lang.Thread.run(Thread.java:619)
19:27:26,674 ERROR [STDERR] Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!
19:27:26,674 ERROR [STDERR] 	at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
19:27:26,674 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
19:27:26,674 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
19:27:26,674 ERROR [STDERR] 	at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.getConnection(LocalDataSourceConnectionProvider.java:83)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:161)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1700)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQuery(Loader.java:801)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.doList(Loader.java:2542)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2276)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.Loader.list(Loader.java:2271)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:459)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:365)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1268)
19:27:26,675 ERROR [STDERR] 	at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102)
19:27:26,675 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:921)
19:27:26,675 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:912)
19:27:26,675 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406)
19:27:26,675 ERROR [STDERR] 	... 47 more
19:27:26,675 ERROR [STDERR] Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.
19:27:26,675 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319)
19:27:26,675 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557)
19:27:26,675 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477)
19:27:26,675 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525)
19:27:26,675 ERROR [STDERR] 	... 66 more
19:28:29,599 ERROR [STDERR] org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; Connections could not be acquired from the underlying database!; nested exception is java.sql.SQLException: Connections could not be acquired from the underlying database!
19:28:29,600 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83)
19:28:29,600 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:28:29,600 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:28:29,600 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertJdbcAccessException(HibernateAccessor.java:424)
19:28:29,600 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:410)
19:28:29,600 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)
19:28:29,600 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
19:28:29,600 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:912)
19:28:29,601 ERROR [STDERR] 	at com.springtest.common.dao.GenericHibernateDao.find(GenericHibernateDao.java:224)
19:28:29,601 ERROR [STDERR] 	at com.springtest.system.service.LoginService.findTBaseUser(LoginService.java:25)
19:28:29,601 ERROR [STDERR] 	at com.springtest.system.action.LoginAction.login(LoginAction.java:39)
19:28:29,601 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
19:28:29,601 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
19:28:29,601 ERROR [STDERR] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
19:28:29,601 ERROR [STDERR] 	at java.lang.reflect.Method.invoke(Method.java:597)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
19:28:29,601 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
19:28:29,601 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
19:28:29,601 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
19:28:29,601 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:29,601 ERROR [STDERR] 	at com.springtest.common.filter.LoginFilter.doFilter(LoginFilter.java:48)
19:28:29,601 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:29,601 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
19:28:29,601 ERROR [STDERR] 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:29,602 ERROR [STDERR] 	at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
19:28:29,602 ERROR [STDERR] 	at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
19:28:29,602 ERROR [STDERR] 	at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
19:28:29,602 ERROR [STDERR] 	at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
19:28:29,602 ERROR [STDERR] 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
19:28:29,602 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
19:28:29,602 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
19:28:29,602 ERROR [STDERR] 	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
19:28:29,602 ERROR [STDERR] 	at java.lang.Thread.run(Thread.java:619)
19:28:29,602 ERROR [STDERR] Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!
19:28:29,602 ERROR [STDERR] 	at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
19:28:29,602 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
19:28:29,602 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
19:28:29,602 ERROR [STDERR] 	at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.getConnection(LocalDataSourceConnectionProvider.java:83)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:161)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1700)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQuery(Loader.java:801)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.doList(Loader.java:2542)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2276)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.Loader.list(Loader.java:2271)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:459)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:365)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1268)
19:28:29,603 ERROR [STDERR] 	at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102)
19:28:29,603 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:921)
19:28:29,603 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:912)
19:28:29,603 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406)
19:28:29,603 ERROR [STDERR] 	... 47 more
19:28:29,604 ERROR [STDERR] Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.
19:28:29,604 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319)
19:28:29,604 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557)
19:28:29,604 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477)
19:28:29,604 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525)
19:28:29,604 ERROR [STDERR] 	... 66 more
19:28:46,580 ERROR [STDERR] org.springframework.jdbc.UncategorizedSQLException: Hibernate operation: Cannot open connection; uncategorized SQLException for SQL [???]; SQL state [null]; error code [0]; Connections could not be acquired from the underlying database!; nested exception is java.sql.SQLException: Connections could not be acquired from the underlying database!
19:28:46,580 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83)
19:28:46,580 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:28:46,580 ERROR [STDERR] 	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
19:28:46,580 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertJdbcAccessException(HibernateAccessor.java:424)
19:28:46,581 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:410)
19:28:46,581 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:411)
19:28:46,581 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.executeWithNativeSession(HibernateTemplate.java:374)
19:28:46,581 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.find(HibernateTemplate.java:912)
19:28:46,581 ERROR [STDERR] 	at com.springtest.common.dao.GenericHibernateDao.find(GenericHibernateDao.java:224)
19:28:46,581 ERROR [STDERR] 	at com.springtest.system.service.LoginService.findTBaseUser(LoginService.java:25)
19:28:46,581 ERROR [STDERR] 	at com.springtest.system.action.LoginAction.login(LoginAction.java:39)
19:28:46,581 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
19:28:46,581 ERROR [STDERR] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
19:28:46,581 ERROR [STDERR] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
19:28:46,581 ERROR [STDERR] 	at java.lang.reflect.Method.invoke(Method.java:597)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invoke(InvocableHandlerMethod.java:219)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:132)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:104)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandleMethod(RequestMappingHandlerAdapter.java:745)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:686)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:80)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:925)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:856)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:936)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:838)
19:28:46,581 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:812)
19:28:46,581 ERROR [STDERR] 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
19:28:46,581 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
19:28:46,581 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:46,581 ERROR [STDERR] 	at com.springtest.common.filter.LoginFilter.doFilter(LoginFilter.java:48)
19:28:46,581 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:46,581 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
19:28:46,581 ERROR [STDERR] 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:46,582 ERROR [STDERR] 	at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
19:28:46,582 ERROR [STDERR] 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
19:28:46,582 ERROR [STDERR] 	at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
19:28:46,583 ERROR [STDERR] 	at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
19:28:46,583 ERROR [STDERR] 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
19:28:46,583 ERROR [STDERR] 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
19:28:46,583 ERROR [STDERR] 	at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
19:28:46,583 ERROR [STDERR] 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
19:28:46,583 ERROR [STDERR] 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
19:28:46,583 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
19:28:46,583 ERROR [STDERR] 	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
19:28:46,583 ERROR [STDERR] 	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
19:28:46,583 ERROR [STDERR] 	at java.lang.Thread.run(Thread.java:619)
19:28:46,583 ERROR [STDERR] Caused by: java.sql.SQLException: Connections could not be acquired from the underlying database!
19:28:46,583 ERROR [STDERR] 	at com.mchange.v2.sql.SqlUtils.toSQLException(SqlUtils.java:106)
19:28:46,583 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:529)
19:28:46,586 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource.getConnection(AbstractPoolBackedDataSource.java:128)
19:28:46,586 ERROR [STDERR] 	at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.getConnection(LocalDataSourceConnectionProvider.java:83)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:161)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1700)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQuery(Loader.java:801)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.doList(Loader.java:2542)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2276)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.Loader.list(Loader.java:2271)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:459)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:365)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1268)
19:28:46,586 ERROR [STDERR] 	at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102)
19:28:46,588 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:921)
19:28:46,588 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:912)
19:28:46,588 ERROR [STDERR] 	at org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406)
19:28:46,588 ERROR [STDERR] 	... 47 more
19:28:46,588 ERROR [STDERR] Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.
19:28:46,588 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.awaitAvailable(BasicResourcePool.java:1319)
19:28:46,588 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.prelimCheckoutResource(BasicResourcePool.java:557)
19:28:46,588 ERROR [STDERR] 	at com.mchange.v2.resourcepool.BasicResourcePool.checkoutResource(BasicResourcePool.java:477)
19:28:46,588 ERROR [STDERR] 	at com.mchange.v2.c3p0.impl.C3P0PooledConnectionPool.checkoutPooledConnection(C3P0PooledConnectionPool.java:525)
19:28:46,588 ERROR [STDERR] 	... 66 more

Oracle service has been started, but an error was reported when executing the query statement. I failed to connect to the database with PLSQL tool, indicating that I did not listen. I remember that I shut down some services that you don’t often use this morning, and the PLSQL connection is normal after startup.

Baidu found that the following error information needs to be checked:
1. Wrong startup configuration: db.driverclass = oracle.jdbc.driver.oracledriver
2. Wrong database connection address: db.url = JDBC: Oracle: thin: @ 127.0.0.1:1521: orcl
3. Wrong account or password: db.user = spring
db.password = springpwd
4. No right to restrict access if the database is not started Ask. The database service or listening service is not started
5. The project does not introduce the corresponding driver jar package.
6. MySQL root does not have remote access permissions, so it needs to increase permissions.


Read More: