Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.8DR#1
    • Fix Version/s: 1.8DR#2, 1.8
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      JSF 1.2, component-showcase, both synchronous mode and asynchronous mode

      Description

      I think that we have a problem with our state saving. I took some code from Sun's StateManagerImpl, where it restores the view, to see how it accesses the saved state. I noticed that, for subsequent post-backs to a single view, we appear to be accumulating saved state into the session.

      I added the following lines to the end of D2DViewHandler.writeState(FacesContext):

      // javax.faces.render.ResponseStateManager.VIEW_STATE_PARAM
      String ResponseStateManager__VIEW_STATE_PARAM = "javax.faces.ViewState";
      Object pValue = context.getExternalContext().
          getRequestParameterMap().get(ResponseStateManager__VIEW_STATE_PARAM);
      System.out.println("pValue: " + pValue);

      // The value com.sun.faces.application.StateManagerImpl uses
      String LOGICAL_VIEW_MAP = "com.sun.faces." + "logicalViewMap";
      Map logicalMap = (Map) context.getExternalContext().getSessionMap().get(LOGICAL_VIEW_MAP);
      System.out.println("logicalMap: " + logicalMap);

      I then clicked around in the component showcase several times, each time it printed out two lines:

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id2=[Ljava.lang.Object;@f036de, j_id3=[Ljava.lang.Object;@c50443}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id2=[Ljava.lang.Object;@f036de, j_id4=[Ljava.lang.Object;@1a6d5e1}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id4=[Ljava.lang.Object;@1a6d5e1, j_id2=[Ljava.lang.Object;@f036de, j_id
      5=[Ljava.lang.Object;@c5c0e5}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id4=[Ljava.lang.Object;@1a6d5e1, j_id5=[Ljava.lang.Object;@c5c0e5, j_id
      2=[Ljava.lang.Object;@f036de, j_id6=[Ljava.lang.Object;@1e1dfb2}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id4=[Ljava.lang.Object;@1a6d5e1, j_id5=[Ljava.lang.Object;@c5c0e5, j_id
      6=[Ljava.lang.Object;@1e1dfb2, j_id2=[Ljava.lang.Object;@f036de, j_id7=[Ljava.lang.Object;@163058b}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id4=[Ljava.lang.Object;@1a6d5e1, j_id5=[Ljava.lang.Object;@c5c0e5, j_id
      6=[Ljava.lang.Object;@1e1dfb2, j_id7=[Ljava.lang.Object;@163058b, j_id2=[Ljava.lang.Object;@f036de, j_id8=[Ljava.lang.Object;@15fd309}}

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@c50443, j_id4=[Ljava.lang.Object;@1a6d5e1, j_id5=[Ljava.lang.Object;@c5c0e5, j_id
      6=[Ljava.lang.Object;@1e1dfb2, j_id7=[Ljava.lang.Object;@163058b, j_id8=[Ljava.lang.Object;@15fd309, j_id2=[Ljava.lang.Object;@f036de, j_id9=[Ljava.lang.Ob
      ject;@1b8c5e3}}

        Issue Links

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              Mark Collette
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: