Uploaded image for project: 'MyFaces Orchestra'
  1. MyFaces Orchestra
  2. ORCHESTRA-35

ConversationManager instances leak when using OC4J servlet engine

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.3
    • 1.3.1
    • Conversation
    • None

    Description

      As reported by Steve Ronderos, the OC4J servlet container does not call removeAttribute on session attributes when the session is invalidated. This means that the ConversationManagerSessionListener does not remove ConversationManager instances from the ConversationWiperThread when the owning session is destroyed.

      This is possibly a bug in OC4J; the servlet specs aren't entirely clear what should happen when a session is invalidated but it seems that the HttpSessionBindingListener javadoc does imply that removeAttribute should be called. Apache Tomcat certainly does call removeAttribute (see method StandardSession.removeAttributeInternal for details).

      Regardless of whether this is a servlet-engine bug or not, this is something that it would be nice to handle.

      One option would be to use weak references in the ConversationWiperThread. Another would be for ConversationManagerSessionListener to implement the HttpSessionListener interface and use the sessionDestroyed callback to scan for ConversationManager instances and remove them from the wiper thread.

      Attachments

        Activity

          People

            Unassigned Unassigned
            skitching Simon Kitching
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: