Class SearchQueryAspect

java.lang.Object
com.erudika.para.server.aop.SearchQueryAspect
All Implemented Interfaces:
org.aopalliance.aop.Advice, org.aopalliance.intercept.Interceptor, org.aopalliance.intercept.MethodInterceptor

public class SearchQueryAspect extends Object implements org.aopalliance.intercept.MethodInterceptor
This method interceptor watches search queries fora all Search implementations and gathers metrics. It listens for calls to Search methods, annotated with Measured.
Author:
Alex Bogdanovski [[email protected]]
See Also:
  • Constructor Details

    • SearchQueryAspect

      public SearchQueryAspect()
  • Method Details

    • invoke

      public Object invoke(org.aopalliance.intercept.MethodInvocation mi) throws Throwable
      Executes code when a method is invoked.
      Specified by:
      invoke in interface org.aopalliance.intercept.MethodInterceptor
      Parameters:
      mi - method invocation
      Returns:
      the returned value of the method invoked or something else (decided here)
      Throws:
      Throwable - error