Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Cannot get a connection, pool exhausted errors

807603Oct 31 2007 — edited Oct 31 2007
I am receiving the following error on a web server for a JAVA web application that I have no source code for.

We have a web server that is running apache tomcat with Sybase database server. The web server uses JDBC to connect to Sybase. I get thousands of TIME_WAIT's on my network card when I do a netstat.

Is there any way to increase the connection pool available for JDBC connections?

Sorry if this does not apply to this forum.



30 Oct 2007 01:59:19,405 [ERROR] [pool-3-thread-3] riodicNotificationService - Error
org.springframework.jdbc.CannotGetJdbcConnectionException: Could not get JDBC Connection; nested exception is org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot get a connection, pool exhausted
Caused by:
org.apache.tomcat.dbcp.dbcp.SQLNestedException: Cannot get a connection, pool exhausted
at org.apache.tomcat.dbcp.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:103)
at org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540)
at org.springframework.jdbc.datasource.DataSourceUtils.doGetConnection(DataSourceUtils.java:113)
at org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:79)
at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:327)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:403)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:411)
at org.springframework.jdbc.core.simple.SimpleJdbcTemplate.query(SimpleJdbcTemplate.java:107)
at com.mottmac.help2travel.core.dao.TrainStationJdbcDao.getTrainStations(TrainStationJdbcDao.java:35)
at com.mottmac.help2travel.core.services.TrainServiceImpl.timeoutNotification(TrainServiceImpl.java:186)
at com.mottmac.help2travel.core.services.notification.PeriodicNotificationService$1.run(PeriodicNotificationService.java:107)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.util.NoSuchElementException: Timeout waiting for idle object
at org.apache.tomcat.dbcp.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:756)
at org.apache.tomcat.dbcp.dbcp.PoolingDataSource.getConnection(PoolingDataSource.java:95)
... 19 more
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 28 2007
Added on Oct 31 2007
9 comments
11,725 views