Announcement Announcement Module
Collapse
No announcement yet.
BeanNameAutoProxyCreator and BeforeAdvise not working Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • BeanNameAutoProxyCreator and BeforeAdvise not working

    Hi

    I am using BeanNameAutoProxyCreator to invoke interceptor in my applications.
    I have registered BeforeAdvise interceptor and MethodInterceptor.
    But when i run my application , I only see MethodInterceptor being executed , I am not sure what i am doing wrong.

    Here is my configuration.

    <bean id="methodInterceptor" class="org.xxx.xxx.xxx.xxx.xxx.impl.MethodIntercep tor">
    </bean>

    <bean id="beforeMethodInterceptor" class="xxx.IPTSMethodBeforeAdvise"/>

    <bean id="daobeforeAdviseInterceptor" class="org.springframework.aop.support.RegexpMetho dPointcutAdvisor">
    <property name="advice" ref="beforeMethodInterceptor"/>
    <property name="patterns" value=".*"/>
    </bean>



    <bean id="daoProxyCreator" class="org.springframework.aop.framework.autoproxy .BeanNameAutoProxyCreator">
    <property name="proxyTargetClass"><value>true</value></property>
    <property name="interceptorNames">
    <list>
    <value>daobeforeAdviseInterceptor</value>
    <value>methodInterceptor</value>
    </list>
    </property>
    <property name="beanNames">
    <list>
    <value>*DAOManager</value>

    </list>

    </property>
    </bean>
Working...
X