Creation of ClassAdvisor must use the AspectManager equivalent to the
advised class' ClassLoader
------------------------------------------------------------------------------------------------
Key: JBAOP-796
URL:
https://issues.jboss.org/browse/JBAOP-796
Project: JBoss AOP
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 2.1.9.Alpha1
Reporter: Flavia Rainone
Assignee: Flavia Rainone
Fix For: 2.1.6.CP03, 2.1.9.GA, Branch_2_2
Currently, an Advisor is created by calling
AspectManager.instance().getAdvisor(WovenClass.class).
The correct is to create the advisor by calling something equivalent to
AspectManager.instance(WovenClass.class.getClassLoader()).getAdvisor(WovenClass.class).
Otherwise, the Advisor will be created as part of the AspectManager/Domain corresponding
to the current context class loader:
public static synchronized AspectManager instance()
{
return instance(Thread.currentThread().getContextClassLoader());
}
In the JBoss AS environment, if the woven class is loaded during an archive deployment,
this is equivalent to say that the Advisor will be erroneously created by the domain of
the current deployment, instead of being created by the appropriate AspectManager/Domain
instance.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: