[jboss-dev-forums] [Design the new POJO MicroContainer] - Re: Registering a bean as an aspect in the bootstrap
scott.stark@jboss.org
do-not-reply at jboss.com
Wed Jan 31 15:10:34 EST 2007
I'm also having problems with the bootstrap xml intercepting some classes. For example, if I add an org.jboss.deployers.spi.attachments.Attachments interceptor:
| <bean name="AspectManager" class="org.jboss.aop.deployers.AspectManagerJDK5">
| <constructor>
| <parameter><![CDATA[
| <aop>
| <aspect name="deployers" class="org.jboss.profileservice.aop.DeployerAspects"/>
| <bind pointcut="execution(* $instanceof{org.jboss.deployers.spi.deployer.Deployer}->*(..))">
| <advice name="invoke" aspect="deployers"/>
| </bind>
| <aspect name="mainDeployer" class="org.jboss.profileservice.aop.MainDeployerAspect"/>
| <bind pointcut="execution(* $instanceof{org.jboss.deployers.spi.deployment.MainDeployer}->process(..))">
| <advice name="process" aspect="mainDeployer"/>
| </bind>
| <aspect name="track" class="org.jboss.profileservice.aop.TrackingAdvice"/>
| <bind pointcut="execution(* $instanceof{org.jboss.deployers.spi.attachments.Attachments}->addAttachment(..))">
| <advice name="invoke" aspect="track"/>
| </bind>
| </aop>]]>
| </parameter>
| </constructor>
|
|
This is not applied. I had to go into one particular usage context (AbstractDeploymentContext) and wrap the Attachments instance I wanted to inercept in an aop proxy in order for the above aspect to be applied.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4008988#4008988
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4008988
More information about the jboss-dev-forums
mailing list