Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 1.2
    • Component/s: Uncategorized
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Issuezilla Id:
      549

      Description

      In the case of server-side state saving, implementation of ResponseStateManager
      saves a new state for an every request,even for a same viewId as previous was,
      and generates a new value for "javax.faces.ViewState" hidden field. That feature
      allows JSF to restore proper view state then user returns to previous page by
      browser "back" button and submit some form from that page again.
      But that behaviour is incorrect for AJAX requests because in this case browser
      does not save page in history ( Even if "back" button support for AJAX will be
      implemented, it could be done by special 'iframe' object only, and does not save
      page in history anyway ), and old values is only going to garbage. As a result,
      small view states cache ( which default size is 16 ) could be refilled by values
      from AJAX requests soon, and browser "back" button support will be broken.

        Activity

        Hide
        rogerk added a comment -

        I've added the following to javax.faces.render.ResponseStateManager.writeState :

        + * <p>If the state saving method for this application is

        {@link + * javax.faces.application.StateManager#STATE_SAVING_METHOD_SERVER}

        ,
        + * and the current request is an <code>Ajax</code> request
        + * (@link javax.faces.context.PartialViewContext.isAjaxRequest} returns
        + * <code>true</code>), use the current view state identifier if it is
        + * available (do not generate a new identifier).</p>

        Show
        rogerk added a comment - I've added the following to javax.faces.render.ResponseStateManager.writeState : + * <p>If the state saving method for this application is {@link + * javax.faces.application.StateManager#STATE_SAVING_METHOD_SERVER} , + * and the current request is an <code>Ajax</code> request + * (@link javax.faces.context.PartialViewContext.isAjaxRequest} returns + * <code>true</code>), use the current view state identifier if it is + * available (do not generate a new identifier).</p>
        Hide
        rogerk added a comment -

        change target milestone

        Show
        rogerk added a comment - change target milestone
        Hide
        Ed Burns added a comment -

        Prepare to delete "implementation" subcomponent.

        Show
        Ed Burns added a comment - Prepare to delete "implementation" subcomponent.
        Hide
        Ed Burns added a comment -

        Move all to 1.2

        Show
        Ed Burns added a comment - Move all to 1.2
        Hide
        Manfred Riem added a comment -

        Closing resolved issue out

        Show
        Manfred Riem added a comment - Closing resolved issue out

          People

          • Assignee:
            rogerk
            Reporter:
            alexsmirnov
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: