I'm trying to apply a cross cutting concern which is logging with AspectJ and a test framework called Katalon which uses Groovy and Java. I found that the best weaving type appropriate here is load-time weaving which requires a META-INF folder and an Aop.xml. I tried to put my aop.xml in multiple places but I think aspectj is unable to find it. This is the structure of my project:
Here is my aop.xml file content:
<aspectj>
<aspects>
<aspect name="com.fd.common.aspectName"/>
<weaver options="-verbose -showWeaveInfo">
<include within="com.myapp.common.*"/>
</weaver>
</aspects>
</aspectj>
And here is my aspect :
@Aspect
public class test {
@org.aspectj.lang.annotation.Before("execution(* *.*(..))")
public void bef (JoinPoint jp) {
System.out.println(jp.getSignature());
System.out.println("Beforeeeeeeeeeeeeeeeeeeeee");
}
}