-
Enhancement
-
Resolution: Done
-
Blocker
-
None
-
None
-
None
References:
ClassLoader oldLoader = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader(MyPolicy.class.getClassLoader()); // Execute policy here } finally { Thread.currentThread().setContextClassLoader(oldLoader); }
We may need to do this in the following places:
- When first loading a policy class (in case the policy class has static initializers)
- When instantiating the policy (in case the policy has instance initializers)
- When executing the policy (apply())