|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.rhq.plugins.database.DatabasePluginLifecycleListener
public class DatabasePluginLifecycleListener
This is a plugin lifecycle listener object for database plugins. It is used to deregister any JDBC drivers that happened to have been cached by the plugin. This is needed to avoid leaking perm gen memory when a plugin's classloader is destroyed because java.sql.DriverManager will maintain references that prevent the plugin's classloader and its resources from being garbaged collected. All database plugins should have their own class that does this but due to the odd way java.sql.DriverManager caches drivers, plugins that extend the database plugin cannot simply reuse or subclass this object.
| Constructor Summary | |
|---|---|
DatabasePluginLifecycleListener()
|
|
| Method Summary | |
|---|---|
void |
initialize(PluginContext context)
|
void |
shutdown()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DatabasePluginLifecycleListener()
| Method Detail |
|---|
public void initialize(PluginContext context)
throws java.lang.Exception
initialize in interface PluginLifecycleListenerjava.lang.Exceptionpublic void shutdown()
shutdown in interface PluginLifecycleListener
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||