[jboss-dev-forums] [Design the new POJO MicroContainer] - MC upgrade breaks scoped aop tests in trunk

kabir.khan@jboss.com do-not-reply at jboss.com
Fri Nov 28 06:25:27 EST 2008


https://jira.jboss.org/jira/browse/JBAS-6255
If an AspectDefinition and its aspect class is deployed in the default classloader domain, and a deployment in a child classloader domain with no parent delegation overrides that class, the child deployment should use its own copy of the class. 

Some code in GenericBeanAspectFactory.doCreate() handled that scenario and pushed the correct loader to use into the underlying GenericBeanFactory. However, now the underlying GenericBeanFactory will always use the loader of its KernelControllerContext to create the bean instance, so in the case outlined the wrong loader is used to create the bean.

Rather than calling GBF directly from GBAF, if there is a pushed classloader I am trying to wrap GBF in a wrapper class that implements the same createBean() method, but with the option to specify the classloader. This gives me better results although I am still seeing some failures.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4192988#4192988

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4192988



More information about the jboss-dev-forums mailing list