Author: wyoung
Date: Wed Mar 19 14:30:19 2008
New Revision: 2252
URL: http://svn.gna.org/viewcvs/mysqlpp?rev=2252&view=rev
Log:
Made ConnectionPool::release() virtual, per request on the list
Modified:
trunk/doc/userman/threads.dbx
trunk/lib/cpool.h
Modified: trunk/doc/userman/threads.dbx
URL:
http://svn.gna.org/viewcvs/mysqlpp/trunk/doc/userman/threads.dbx?rev=2252&r1=2251&r2=2252&view=diff
==============================================================================
--- trunk/doc/userman/threads.dbx (original)
+++ trunk/doc/userman/threads.dbx Wed Mar 19 14:30:19 2008
@@ -119,6 +119,10 @@
in the client would make the most sense, so it asks its subclass
via the <methodname>max_idle_time()</methodname> method.</para>
+ <para><classname>ConnectionPool</classname> also allows you to
+ override <methodname>release()</methodname>, if needed. For simple
+ uses, it’s not necessary to override this.</para>
+
<para>In designing your <classname>ConnectionPool</classname>
derivative, you might consider making it a Singleton (see Gamma
et al.), since there should only be one pool in a program.</para>
Modified: trunk/lib/cpool.h
URL:
http://svn.gna.org/viewcvs/mysqlpp/trunk/lib/cpool.h?rev=2252&r1=2251&r2=2252&view=diff
==============================================================================
--- trunk/lib/cpool.h (original)
+++ trunk/lib/cpool.h Wed Mar 19 14:30:19 2008
@@ -106,7 +106,7 @@
/// if it doesn't know approximately how long a connection has
/// really been idle, it can't make good judgements about when to
/// remove it from the pool.
- void release(const Connection* pc);
+ virtual void release(const Connection* pc);
/// \brief Remove all unused connections from the pool
void shrink() { clear(false); }
_______________________________________________
Mysqlpp-commits mailing list
[email protected]
https://mail.gna.org/listinfo/mysqlpp-commits