jaikiran pai [
http://community.jboss.org/people/jaikiran] created the discussion
"Re: @EJB(lookup) fails while context.lookup() is successfull"
To view the discussion, visit:
http://community.jboss.org/message/633418#633418
--------------------------------------------------------------
Dan Sirbu wrote:
OK. If I add an application.xml where I define the <module><ejb> info (e.g. :
http://docs.jboss.com/books/lightweight/ch03.html
http://docs.jboss.com/books/lightweight/ch03.html) would I still be able to use the @EJB
from the non EE component or I would have to re-work the classes ?
Resource injection which includes (@Resource, @EJB etc...) will +not+ happen in a
application managed class (i.e. a class whose lifecycle is managed by an application and
not by the container). So ultimately, if your class is a non-EE class, then there's no
server provided resource injection.
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/633418#633418]
Start a new discussion in JBoss AS7 Development at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]