ICEfaces
  1. ICEfaces
  2. ICE-986

Seam: Logout causes lifecycle exceptions

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.5
    • Fix Version/s: 1.5.2
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      Operating System: Windows XP
      Platform: PC

      Description

      Seam applications that have logout buttons whose business logic methods
      invalidate the session can cause an exception later in the JSF lifecycle, which
      breaks any redirection back to a 'login' page.

      The BridgeExternalContext attempts to execute the method resetRequestMap, which
      throws an IllegalStateException, since the Session has already been invalidated
      by the business logic in this case.


      Reloading the application will successfully restart it.

      While this might seem like a Seam bug, any application writer including a logout
      function that invalidates the session will break the application. In other
      words, this could be rather common.


      Exception is

      2006-11-16 09:28:15,239 INFO java.lang.IllegalStateException: getAttribute:
      Session already invalidated

      2006-11-16 09:28:15,239 ERROR java.lang.IllegalStateException: getAttribute:
      Session already invalidated

      2006-11-16 09:28:15,239 ERROR at
      org.apache.catalina.session.StandardSession.getAttribute(StandardSession.java:1011)

      2006-11-16 09:28:15,239 ERROR at
      org.apache.catalina.session.StandardSessionFacade.getAttribute(StandardSessionFacade.java:109)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.SessionMap.getAttribute(SessionMap.java:53)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.AbstractAttributeMap.containsKey(AbstractAttributeMap.java:94)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.application.D2DViewHandler.getContextServletTables(D2DViewHandler.java:303)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.application.D2DViewHandler.getContextServletTable(D2DViewHandler.java:314)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.BridgeFacesContext.getContextServletTable(BridgeFacesContext.java:292)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.BridgeExternalContext.getRequestMap(BridgeExternalContext.java:367)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.BridgeExternalContext.resetRequestMap(BridgeExternalContext.java:402)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.context.BridgeFacesContext.release(BridgeFacesContext.java:325)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.webapp.xmlhttp.BlockingServlet.renderCycle(BlockingServlet.java:443)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.webapp.xmlhttp.BlockingServlet.receiveUpdates(BlockingServlet.java:427)

      2006-11-16 09:28:15,239 ERROR at
      com.icesoft.faces.webapp.xmlhttp.BlockingServlet.service(BlockingServlet.java:277)

      2006-11-16 09:28:15,255 ERROR at
      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

       . . .

      2006-11-16 09:28:15,302 ERROR [STDERR] at java.lang.Thread.run(Thread.java:619)

        Activity

        Greg Dick created issue -
        Icefaces Administrator made changes -
        Field Original Value New Value
        issue.field.bugzillaimportkey 1005 12255
        Ken Fyten made changes -
        Affects Version/s 1.5 [ 10027 ]
        Affects Version/s unspecified [ 10021 ]
        Ken Fyten made changes -
        Summary Logout causes lifecycle exceptions Seam: Logout causes lifecycle exceptions
        Ken Fyten made changes -
        Assignee Ted Goddard [ ted.goddard ]
        Ken Fyten made changes -
        Fix Version/s 1.6 [ 10031 ]
        Hide
        Ken Fyten added a comment -

        This issue needs to be analyzed along with other Seam related issues and distilled to root causes.

        Show
        Ken Fyten added a comment - This issue needs to be analyzed along with other Seam related issues and distilled to root causes.
        Ken Fyten made changes -
        Estimated Complexity Medium
        Fix Version/s 1.6DR#2 [ 10040 ]
        Fix Version/s 1.6 [ 10031 ]
        Assignee Priority P1
        Assignee Greg Dick [ greg.dick ]
        Ken Fyten made changes -
        Fix Version/s 1.6 [ 10031 ]
        Fix Version/s 1.6DR#2 [ 10040 ]
        Hide
        Mike Finkenzeller added a comment -

        Are there any known work arounds for this issue? Thanks

        Show
        Mike Finkenzeller added a comment - Are there any known work arounds for this issue? Thanks
        Hide
        Greg Dick added a comment -

        I'm closing this issue because this particular issue was with the BlockingServlet, when the user logged out using a partial submit. That issue has been fixed in 1.5.2 and forward.

        There is, however, a new issue with logout using the Identity named Seam component, in both 1.5.3 and the 1.6 developer release. that issue is here:
        http://jira.icefaces.org/browse/ICE-1330

        Show
        Greg Dick added a comment - I'm closing this issue because this particular issue was with the BlockingServlet, when the user logged out using a partial submit. That issue has been fixed in 1.5.2 and forward. There is, however, a new issue with logout using the Identity named Seam component, in both 1.5.3 and the 1.6 developer release. that issue is here: http://jira.icefaces.org/browse/ICE-1330
        Greg Dick made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Fix Version/s 1.5.2 [ 10029 ]
        Fix Version/s 1.6 [ 10031 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Priority P1
        Assignee Greg Dick [ greg.dick ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Greg Dick
          • Votes:
            3 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: