users@glassfish.java.net

Re: RE: How to inject EJB to Servlet Filter?

From: <glassfish_at_javadesktop.org>
Date: Fri, 16 Oct 2009 08:14:45 PDT

Hi,

my WAR container is part of my own EAR container.

My servlet can use EJBs:

public class MyServlet extends javax.servlet.http.HttpServlet implements javax.servlet.Servlet {
   private static final Logger log = Logger.getLogger(MyServlet.class.getName());

   private static final long serialVersionUID = -7366113481276107174L;

   @EJB
   private MyOtherBean myOtherBean;
// ...
}

Is there no chance to access my EJB bean from a servlet filter?
[Message sent by forum member 'hegalor' (Michael.Decker_at_MobileXAG.de)]

http://forums.java.net/jive/thread.jspa?messageID=368225