You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Aaron Mulder <am...@alumni.princeton.edu> on 2004/11/15 04:56:06 UTC
Can GBean get its configuration ClassLoader?
I wonder if there's a way for a GBean to get the ClassLoader for
the configuration it's a part of -- in other words, the
GBeanMBean.getClassLoader(), which includes the dependencies in the
deployment plan, etc.
I want the SQLSecurityRealm to be able to load a driver class.
However, the SQLSecurityRealm itself was loaded in the Server
configuration, and the JDBC driver is included as a dependency of the
service deployment plan that declares the realm (but gets the
SQLSecurityRealm class from its parent). So the SQLSecurityRealm can't
see the driver classes in a child of it's own CL, and the
ThreadContextClassLoader does not appear to be set to something useful
when doStart is called on the GBean.
I basically want to be able to call some static method to get the
GBeanMBean for the current GBean implementation class, becasue then I
could get the ClassLoader from it. But any other suggestions would be
appreciated too. :)
Thanks,
Aaron