Ok, I'm using torque-3.0-b4.

Apparently the root of the problem are the pool "testOnBorrow" and
"validationQuery" properties. They produce on DB2 39 connections when the
idBroker thread starts, even that I ask for max 8. And I run out of
available connections since I'm using the DB2 Developer Edition (DB2/NT
7.2.4) that has a limited number of connections. So I don't get to do
anything.

When I turn off testOnBorrow using testOnBorrow = false, things work fine.

When I switch to the old TorquePool, everything it's fine, too.

Here is my Torque.props file section:

-----------------------------------------------
torque.database.default=webapp
# DB2 App adapter
torque.database.webapp.adapter=db2app

## Using Jdbc2Pool
torque.dsfactory.webapp.factory=org.apache.torque.dsfactory.Jdbc2PoolDataSou
rceFactory
torque.dsfactory.webapp.pool.defaultMaxIdle = 8  
torque.dsfactory.webapp.pool.defaultMaxActive = 3
torque.dsfactory.webapp.pool.testOnBorrow = false 
#torque.dsfactory.webapp.pool.validationQuery = SELECT 1 FROM DUAL
torque.dsfactory.webapp.connection.driver = COM.ibm.db2.jdbc.app.DB2Driver
torque.dsfactory.webapp.connection.url = jdbc:db2:play
torque.dsfactory.webapp.connection.user = username
torque.dsfactory.webapp.connection.password = password
-----------------------------------------------


Notice that I'm using the already proposed solution for Oracle users for the
same problem posted on the scarab-dev list, replace "SELECT 1" with  "SELECT
1 FROM DUAL" and it did't work. It seems that you should carefully choose
the "validationQuery" value according to your database, in my case I don't
have idea what it could be.

I like Torque, though  
good job! ;-)

Rogelio

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to