From: Todd P. <pal...@ya...> - 2004-08-27 19:01:07
|
The current (1.6.1, haven't looked at 1.7a) connection pooling behavior has an interesting side effect: by default connections never go away. If you have a connection string with the default values (e.g. "Pooling=true;Connection Lifetime=0" or don't specify these values) and you write code like: FbConnection c = new FbConnection("connection string"); c.Open(); ... do work here c.Close(); c = null; The connection is put into the pool, and you connection will remain open for the lifetime of you application. However, it will be reused if you happen go create a new FbConnection. While this seems to make sense once you figure out that a Connection Lifetime of 0 means forever (the docs aren't very clear on this), it's not what I would consider expected behavior. The .Net SqlClient connection with the same parameters will be cleaned up after a default maximum timeout if you set Pooled=true;Connection Lifetime=0 (also the default). I'd suggest that the Firebird provider do the same for a reasonable period of inactivity. Comments? Todd _______________________________ Do you Yahoo!? Win 1 of 4,000 free domain names from Yahoo! Enter now. http://promotions.yahoo.com/goldrush |