RE: JDBC pool configuration bug/ugliness

2004-08-11 Thread Shapira, Yoav
Hi,
OK, docs corrected and clarified.  Thanks for pointing that out.

Yoav Shapira
Millennium Research Informatics


-Original Message-
From: Dirk Verbeeck [mailto:[EMAIL PROTECTED]
Sent: Tuesday, August 10, 2004 12:55 PM
To: Tomcat Developers List
Subject: Re: JDBC pool configuration bug/ugliness

This is a documentation bug, it should be:
 !-- Maximum number of idle dB connections to retain in pool.
  Set to -1 for no limit.
  --

A connection is considered idle when it is returned to the pool by
calling conn.close()
So by setting maxIdle=0 you never get any connection in the pool
effectively disabling the pooling.
This is probably not what you want.

In your case you want to use the minEvictableIdleTimeMillis parameter.
http://jakarta.apache.org/commons/dbcp/configuration.html

If a connection is unused (idle) for xxx msec then the pool will close
it.

-- Dirk

Wojciech Sobczuk wrote:

 hey,

 i hope that i'm getting to the right people with this email.  anyway,
 the tomcat JDBC connection pool docs state:

!-- Maximum number of idle dB connections to retain in pool.
 Set to 0 for no limit.
 --
parameter
  namemaxIdle/name
  value30/value
/parameter


 well due to this i have to have at least one db connection per
website
 using the database. i'm running a host with 30 such websites and each
 has 1 DB connections at all times.
 this isn't exactly critical but i'd like to have those connections
 dropped and opened up when
 they're needed, and not at all times like now.  the configuration
 doesn't allow you
 to set maximum number of idle connections to 0 (anyway, when is a
 connection considered idle?
 that isn't covered by the configuration either at least the docs
don't
 mention it).

 so i'm proposing to allow the user to set the max idle connection
number
 to 0 so that all
 unused connections for a site can be reclaimed and there isn't always
 one hanging around.
 plus to allow the user to set what an idle connection means (how many
 seconds have to pass without a query before a connection is condered
to
 be idle).

 thanks,
 Wojtek




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


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



Re: JDBC pool configuration bug/ugliness

2004-08-10 Thread Dirk Verbeeck
This is a documentation bug, it should be:
!-- Maximum number of idle dB connections to retain in pool.
 Set to -1 for no limit.
 --
A connection is considered idle when it is returned to the pool by
calling conn.close()
So by setting maxIdle=0 you never get any connection in the pool
effectively disabling the pooling.
This is probably not what you want.
In your case you want to use the minEvictableIdleTimeMillis parameter.
http://jakarta.apache.org/commons/dbcp/configuration.html
If a connection is unused (idle) for xxx msec then the pool will close
it.
-- Dirk
Wojciech Sobczuk wrote:
hey,
i hope that i'm getting to the right people with this email.  anyway, 
the tomcat JDBC connection pool docs state:

   !-- Maximum number of idle dB connections to retain in pool.
Set to 0 for no limit.
--
   parameter
 namemaxIdle/name
 value30/value
   /parameter
well due to this i have to have at least one db connection per website 
using the database. i'm running a host with 30 such websites and each 
has 1 DB connections at all times.
this isn't exactly critical but i'd like to have those connections 
dropped and opened up when
they're needed, and not at all times like now.  the configuration 
doesn't allow you
to set maximum number of idle connections to 0 (anyway, when is a 
connection considered idle?
that isn't covered by the configuration either at least the docs don't 
mention it).

so i'm proposing to allow the user to set the max idle connection number 
to 0 so that all
unused connections for a site can be reclaimed and there isn't always 
one hanging around.
plus to allow the user to set what an idle connection means (how many 
seconds have to pass without a query before a connection is condered to 
be idle).

thanks,
Wojtek

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


JDBC pool configuration bug/ugliness

2004-08-08 Thread Wojciech Sobczuk
hey,
i hope that i'm getting to the right people with this email.  anyway, 
the tomcat JDBC connection pool docs state:

   !-- Maximum number of idle dB connections to retain in pool.
Set to 0 for no limit.
--
   parameter
 namemaxIdle/name
 value30/value
   /parameter
well due to this i have to have at least one db connection per website using the database. 
i'm running a host with 30 such websites and each has 1 DB connections at all times.
this isn't exactly critical but i'd like to have those connections dropped and opened up when
they're needed, and not at all times like now.  the configuration doesn't allow you
to set maximum number of idle connections to 0 (anyway, when is a connection considered idle?
that isn't covered by the configuration either at least the docs don't mention it).

so i'm proposing to allow the user to set the max idle connection number to 0 so that all
unused connections for a site can be reclaimed and there isn't always one hanging around.
plus to allow the user to set what an idle connection means (how many seconds have to pass 
without a query before a connection is condered to be idle).

thanks,
Wojtek
--
Wojciech Sobczuk
[EMAIL PROTECTED]
+48 501 456 923
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]