Correct exception handling for DynamicPooledDataSource....
Status: Beta
Brought to you by:
swaldman
This patch corrects the handling of exceptions in the getAttribute, setAttribute and invoke methods of com.mchange.v2.c3p0.DynamicPooledDataSourceManagerMBean. These methods are used by Jmx, and when they throw which exceptions is specified in the JavaDoc for the relevant methods.
The current implementation does not follow this specification: For example, if a non-existent attribute is retrieved using getAttribute, the method specifies that it should throw an AttributeNotFoundException. The current implementation throws an MBeanException that wraps an AttributeNotFoundException.
The patch corrects these cases.
Correct exception handling for DynamicPooledDataSourceManagerMBean