[jboss-user] [JBoss AOP] - How to access an EJB 3.0 from an Interceptor

Giordacchio++ do-not-reply at jboss.com
Fri Nov 10 09:01:46 EST 2006


I'm trying to access an EJB3 from an interceptor.
My app is packaged and works correctly: the interceptor is called at the right time but if inside the interceptor I try to get, through injection, an EJB of my app I always get a null pointer instead the instance of my EJB.

I use the @EJB annotation like this:

  | @EJB
  | private it.mypackage.myejb;

Can I use @EJB from an interceptor ? or I have to use InitialContext() and lookup(..) ??

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3984883#3984883

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3984883

More information about the jboss-user mailing list