"[EMAIL PROTECTED]" wrote : Look at the EJB3 code for examples, but it uses something called a ClassContainer. (I know the names are confusing). | | My thinking was a proxy (java.lang.reflect or a javassist one) that creates an invocation and delegates to this ClassContainer.Eventually, the InstanceAdvisor will be replaced by some extension of the ClassContainer and we'll have unified APIs for adding advices/interceptors to a proxy or to an instance. | | As far as your problem goes, if you want to use @MBean with weaving you DO NOT have to have control over classloading. Just use the AOPC compiler. For @Mbean anyways, we should pick one or the other. Either weave or don't weave.
My thinking was the class adapter would go through something like the following logic: Object implements Advised -> InstanceAdvisor (!Object implements Advised) && canWeave -> Runtime Weaving (!Object implements Advised) && canWeave == false -> ProxyAdvisor With this being transparent to the "user", i.e. me JMX. My problem with using AOPC is that I cannot predicate a standalone MBeanServer on the user using AOPC. They just do: | MBeanServer server = MBeanServerFactory(); | server.registerMBean(objectName, new MyMBean()); | In this case, MyMBean.class is not weaved for AOP and it is too late to do it in registerMBean because they already loaded the class. What I want to do inside registerMBean is use an AOP domain configuration to wrap the MBean in advices, but regardless of the advisor implementation. This is one of those backward compatibility requirements. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3874346#3874346 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3874346 ------------------------------------------------------- SF email is sponsored by - The IT Product Guide Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now. http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click _______________________________________________ JBoss-Development mailing list JBoss-Development@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-development