title: Recover session EJB
body: <p>I was checking EJB stateful beans, the typical example for using this bean is in a shopping cart.</p>
  
  <p>So in the example what is done is check in HttpSession if the EJB exists, if not, one EJB instance is called and then upload to session using the HttpSessionId as identifier.</p>
  
  <p>So, what is the advantage of using a stateful EJB when I could use a simple POJO to do exactly the same?</p>
  
  <p>I guess the typical answer is that even if the HttpSession goes down the EJB still lives in the server container. If this is true, how can I recover that EJB from the EJB pool? given I don't have the HttpSessionID anymore.</p>
  
  <p>Is there another approach to recover EJB's that are living in a container?</p>