How to make sure database connections are closed?

I'm running into an issue now, not sure what's triggering it, possibly related to moving the placement of items in the menu...


Anyway, the issue is with Dolphin under certain error conditions making too many connections to the database, which locks it up due to it hitting the max connections allowed by the user account.  This lock-up condition seems to happen when going to the Profile display page.

Where in the code can I verify to make sure that all connections are properly closed whether the queries fail or finish?  It seems maybe in certain conditions too many open connections are made at the same time and this causes the max connections to be hit before the page finishes loading.  That ends up causing the page to not finish loading and no other pages are able to load until MySQL kills the open connections with a timeout.

Quote · 2 Feb 2010
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.