1 Reply Latest reply on Mar 31, 2010 1:51 PM by Anton Lisovenko

    Custom interceptor does not work on methods for POJO

    Anton Lisovenko Newbie


      I'm creating the interceptor. It works ok for TYPE, but not for METHOD. I mean this:

      public class CustomerDetailsBean {..}
      // WORKS! The interceptor is called many times!

           public void someMethod()
      // DOES NOT WORK! Interceptor is never called.

      Here are annotation and interceptor themselves:

      @Target({METHOD, TYPE})
      public @interface DbExceptionCatch {)
      public class DataFetchExceptionInterceptor extends AbstractInterceptor {
           public Object aroundInvoke(InvocationContext ic) throws Exception {
                // TODO Auto-generated method stub
                return null;

      What am I doing wrong! Any help appreciated!