users@glassfish.java.net

Re: _at_EJB annotation application rules

From: Jerome Dochez <Jerome.Dochez_at_Sun.COM>
Date: Fri, 14 Apr 2006 06:29:29 -0700

Hi Joe

you would need to look at the JSR 244 Java EE 5 platform, chapter 5.2.3
to find the exhaustive list of eligible components for annotation. In
the web space, In web space, I believe you can annotate JSF Managed
classes, Servlet, Servlet filters, event listeners and JSP tag handlers
and tag library event listeners.

So if your webwork component is not explicitly declared in the web.xml
as being one of the above mentioned type, annotation processing will not
happen and therefore injection neither.

HTH, jerome

Joseph B. Ottinger wrote:
> What are the rules that determine whether EJB injection takes place? I
> am playing about with using webwork in a web application, and I have
> an @EJB annotation in an action class, but the @EJB annotation isn't
> used. In servlets, obviously, it works, and in JSF as well, but I
> don't know how webwork's classloading is different such that the
> annotation isn't being processed.
>
> Any clues?
>
> -----------------------------------------------------------------------
> Joseph B. Ottinger http://enigmastation.com
> Editor, http://www.TheServerSide.com joeo@enigmastation.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>