I have a problem very similar to: How to create an aspect in an interface method that extends from A "Super" Interface , but my save method is in an abstract superclass.
The structure is as follows:
Interfaces:
public interface SuperServiceInterface { ReturnObj save(ParamObj); } public interface ServiceInterface extends SuperServiceInterface { ... }
Implementations:
public abstract class SuperServiceImpl implements SuperServiceInterface { public ReturnObj save(ParamObj) { ... } } public class ServiceImpl implements ServiceInterface extends SuperServiceImpl { ... }
I want to check for any calls made using the ServiceInterface.save method.
The pointcut point currently looks like this:
@Around("within(com.xyz.api.ServiceInterface+) && execution(* save(..))") public Object pointCut(final ProceedingJoinPoint call) throws Throwable { }
It starts when the save method is placed in ServiceImpl , but not when it is in SuperServiceImpl . What am I missing in my pointcut circle?
source share