tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 54235] tomcat jdbc pool stackoverflow error used with spring
Date Tue, 04 Dec 2012 20:32:24 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=54235

Konstantin Kolinko <knst.kolinko@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 OS|                            |All

--- Comment #1 from Konstantin Kolinko <knst.kolinko@gmail.com> ---
1. The call to ConnectionPool.borrowConnection( ) is caused by setting 

  <property name="initialSize" value="5"/>

which causes ConnectionPool.init() to create 5 connections.


2. The call to PooledConnection.connectUsingDataSource() is seriously wrong.
It should have called PooledConnection.connectUsingDriver() instead.

This can happen only if poolProperties.getDataSource() is not null.

I do not see how this could have happened. Did Spring injected a recursive
reference by calling DataSource.setDataSource()?


3. When you define the pool via <Resource>, it is created using
org.apache.tomcat.jdbc.pool.DataSourceFactory. The factory calls
dataSource.createPool().

So it might be better to add init-method="createPool".

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message