-
Notifications
You must be signed in to change notification settings - Fork 29
Open
Description
Currently connection leak detection can destroy a connection in busy state if the query exceeds the "leakDetectionThreshold" timeout. I have tried this code in place of "idleTimeout" property just to check if it works. It will destroy connection only if the connection state is in "Idle" state and not released to the pool. Seems ideal for leaking connections. Or I'm missing something ?
_checkIdleTimeout(PooledConnectionImpl pconn) {
if (_connections.length > settings.minConnections) {
if (pconn._state != available //Not available
&& pconn._connection.state == idle //But in idle state
&& pconn._obtained != null
&& _isExpired(pconn._obtained, settings.idleTimeout)) {
_debug('Idle connection ${pconn.name}.');
_destroyConnection(pconn);
}
}
}
Metadata
Metadata
Assignees
Labels
No labels