2 Replies Latest reply on Jun 16, 2006 5:32 PM by cryptonaut

    Outjection and Scope

      I'm using a Stateless bean to retrieve a List of entities from a database. If I annotate the List as @Out(scope=ScopeType.SESSION) it works. (APPLICATION scope also works). However, putting the list into any other scope, including EVENT or CONVERSATION renders it invisible to the JSF facelet where I'm sending it. (Code fragment is below). What am I missing?

      @Name("register")
      @Stateless
      public class RegisterOfficer implements Register ....

      // doesn't work:
      // @Out(value="officers",scope=ScopeType.CONVERSATION)
      // private List officers;

      // works fine:
      @Out(value="officers",scope=ScopeType.SESSION)
      private List officers;

      public String show() {
      officers = em.createQuery("from Officer").getResultList();
      return "show";
      }

      ...
      }