I have created two Spring AOP pointcuts that are completely separate and will be woven in for different parts of the system. The pointcuts are used in two different around advices, these around-advices will point to the same Java method. How the xml-file looks:
<aop:config>
<aop:pointcut expression="execution(......)" id="pointcutOne" />
<aop:pointcut expression="execution(.....)" id="pointcurTwo" />
<aop:aspect id="..." ref="springBean">
<aop:around pointcut-ref="pointcutOne" method="commonMethod" />
<aop:around pointcut-ref="pointcutTwo" method="commonMethod" />
</aop:aspect>
</aop:config>
The problem is that only the last pointcut works (if I change the order "pointcutOne" works because it is last). I have gotten it to work by creating one big pointcut, but I would like to have them separate. Any suggestions to why only one of the pointcuts works at a time?