This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Dmitri Ericsson wrote:It is not right to use from Stateless Bean Stateful Bean, in this case state saving does not make sense
Ok, SessionFacade can be Stateful or Stateless, as I understand it's possible to use Stateful -> stateful, but not Stateless -> stateful by DI.
So here is another question, how can I get a link to SessionFacade (SFSB) from my Controller? Controller is not EJB bean... Is it only way through ServiceLocator?
Joined: May 14, 2007
Thanks for your answers guys!
Joined: Feb 24, 2010
you can have DI in servlets.
EDIT: reading your problem again I'm confused - SFSB is tied to a client so I don't think it is ok to inject it into a servlet. I think my answer is I dont know
I have been using Java for 8 years and I have used SFSB only once so I think I better stay away from this question :-)