1 Reply Latest reply on Oct 28, 2011 3:48 AM by gadeyne.bram

    Components shared between contexts?

    gadeyne.bram

      Hello,


      I've created 2 web modules in one seam ear project.


      Is it possible to put something in the session scope in one place and recover it in the other? Or should I setup my contextroot differently.


      war A contextroot: /A
      war B contextroot: /B


      I have one component SubjectManager that keeps track of the currently selected Subject.


      It is defined as


      @Name("subjectManager")
      @Scope(ScopeType.SESSION)
      public class SubjectManager{
          getters and setters for subject entity
      }
      




      In war A the object is set in this subjectManager.


      In war B the same property seems to be empty so I think a new session has been made.


      Can this be done?


      With kind regards
      Bram

        • 1. Re: Components shared between contexts?
          gadeyne.bram

          I've noticed that every new /A or /B starts a new web application.


          Would it be possible to deploy these apps like


          A as /A
          B as /A/B?


          So B could use the same session (stateless or stateful) or the same application context?


          Should the B project also have the SeamListener, SeamFilter and SeamResourceServle configured?