I have an EAR that contains WAR and EJB Jar.
My Custom LoginModule is inside a JAR(WEB-INF/lib) of the Web application.
Is it possible to inject an EJB in a custom LoginModule(using @EJB annotation) ?
I am trying to do the same but the injection simply doesn't happen.I don't get any exception the reference to the injected fied is set to Null.
I think it is not possible using @EJB.
You can use Context lookup or (the hard way) u can use AOP and create your own annotation.