title: Accessing a session scoped JSF managed bean in a servlet, is this guaranteed to be the same session as JSF uses?
body: <p>When calling a managed bean in a servlet using </p>
  
  <pre><code>MyBean myBean = (MyBean) request.getSession().getAttribute("myBean");
  </code></pre>
  
  <p>if it's about trying to call a SessionScopped managed bean : will this know exactly which bean instance to call (the one associated to the current user who was responsible of making the call). will this process be safe in case where many users use the servlet in the same time ? 
  I want also know if it is possible to use an entity bean on a servlet.</p>