Auto-alert of connection pool critical events?

Details

Description

Is there a way that the DBCP automatically alerts critical events such as db down or max # of connections reached too frequently? I was wondering if there's something written or this should be a nice feature for the DBCP. Our ops team really need to be alerted right away if the DBCP has some critical events.

Activity

I'm extremely reluctant to add specific functionality to DBCP for this. One person's critical event will be another person's normal behaviour. The configuration options required to differentiate between the two could easily get out of hand.

My preferred approach is to expose the current state of the likely attributes of interest (e.g. number of active connections currently borrowed from pool and max connections available) and allow folks to use their monitoring solution of choice to monitor those attributes and generate alerts as necessary.

As of DBCP 2, the pool attributes are all exposed via JMX. On this basis, I am resolving this issue as fixed.

I am sure there is scope for improvement but any specific request to improve what is currently available via JMX should be made in a new Jira issue.

Mark Thomas
added a comment - 10/Dec/13 11:02 I'm extremely reluctant to add specific functionality to DBCP for this. One person's critical event will be another person's normal behaviour. The configuration options required to differentiate between the two could easily get out of hand.
My preferred approach is to expose the current state of the likely attributes of interest (e.g. number of active connections currently borrowed from pool and max connections available) and allow folks to use their monitoring solution of choice to monitor those attributes and generate alerts as necessary.
As of DBCP 2, the pool attributes are all exposed via JMX. On this basis, I am resolving this issue as fixed.
I am sure there is scope for improvement but any specific request to improve what is currently available via JMX should be made in a new Jira issue.

There are no current or planned features for this kind of thing, though improved logging has been discussed. Client code can keep track of exceptions and raise alerts as necessary and locally meaningful.

Leaving this open for now, but inclined to close as WONTFIX. Specific suggestions for improvement to exceptions, logging or interfaces to get more information from the pool are welcome.

Phil Steitz
added a comment - 11/May/07 03:39 There are no current or planned features for this kind of thing, though improved logging has been discussed. Client code can keep track of exceptions and raise alerts as necessary and locally meaningful.
Leaving this open for now, but inclined to close as WONTFIX. Specific suggestions for improvement to exceptions, logging or interfaces to get more information from the pool are welcome.