[jboss-dev-forums] [Design of AOP on JBoss (Aspects/JBoss)] - Re: AOP asintegration WITHOUT the integration :-)

adrian@jboss.org do-not-reply at jboss.com
Tue Sep 4 11:44:49 EDT 2007


To reproduce all the OSGi rules and old JBoss rules you would need
to look at the classloading rules and create AOP Domains that delegate to each other.

Think of A1, A2 and Support1/2 as applications. They are the
same application(s) deployed multiple times
(possibly different versions of the classes or just so the user can get their own singletons).

The AOPDeployer could use the classloading config and create domains
to match. i.e. A1 can see AOP configuration from A1 and Support1

For the old JBoss rules (importAll=true) then the visibilty would depend on the
domain name and parent policy like the old ScopedDomain.

The real work is going on in the "incomplete"
org.jboss.deployers.plugins.classloading.Module.

My preferred solution to use the scopes. i.e. you can choose
to deploy aop config at the SERVER, SUBSYSTEM, APPLICATION level, etc.
but this requires doing a lot work fixing everything to make sure
it sets the correct thread local MetaData for AOP to know which Scope
applies at runtime.

i.e. somebody could apply default aop config for some interception
at the server/global level and an application could override it.
Which AOP config applies when creating the object depends on the context of the
invocation NOT what classloader loads the aspect 
(which could be in a different/global deployment) or the intercepted class (same reason)
to the application doing the work.

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

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



More information about the jboss-dev-forums mailing list