3 Replies Latest reply on Mar 13, 2013 5:35 AM by Thomas Frühbeck

    Injection in RpcInterceptor not working

    Thomas Frühbeck Newbie

      I am trying to use dependency injection in an RpcInterceptor:

       

      @Dependent

      public class EchoInterceptor implements RpcInterceptor {

       

          @Inject

          private Event<Message> message;

       

           @Inject 

           private SimpleEvent simpleEvent;

       

          @Override

          public void aroundInvoke(RemoteCallContext context) {

              GWT.log("intercepted"+message);

              context.proceed();

          }

      }

       

      Unfortunately message is always null. The simpleEvent is correctly injected.

      Is it not possible to use Event in Interceptors?

       

      Thanks,

      Thomas