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, ICE-Components
    • Labels:
      None
    • Environment:
      JSF 1.2, component-showcase

      Description

      Refer to ICE-3841 first, for this problem happening generically. Then read this, to see how it specifically affects the file uploading.

      sync mode
      ---------
      Regular interactions:
      - session map entries keep increasing
      - for tree navigations, pValue remains j_id1:j_id2
      - but for clicking on stuff in a page, pValue is last number -1 (if last one is j_id8, then is j_id1:j_id7)
      - Navigation tree must be doing something different (GET?)

      File upload:
      - no progress since sync, but on ending lifecycle, pValue is last number -1


      async mode
      ----------

      (I'd already clicked around a bit)

      Click to navigate to file upload:

      pValue: j_id1:j_id2
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@984b95, j_id4=[Ljava.lang.Object;@1d344e7, j_id5=[Ljava.lang.Object;@16db8d6, j_i
      d6=[Ljava.lang.Object;@1d0eefb, j_id7=[Ljava.lang.Object;@1be645d, j_id8=[Ljava.lang.Object;@116d55f, j_id9=[Ljava.lang.Object;@1e566f3, j_id2=[Ljava.lang.
      Object;@e9d52e, j_id10=[Ljava.lang.Object;@159742d}}

      First progress (0%) lifecycle:

      pValue: j_id1:j_id10
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@984b95, j_id4=[Ljava.lang.Object;@1d344e7, j_id5=[Ljava.lang.Object;@16db8d6, j_i
      d6=[Ljava.lang.Object;@1d0eefb, j_id7=[Ljava.lang.Object;@1be645d, j_id8=[Ljava.lang.Object;@116d55f, j_id9=[Ljava.lang.Object;@1e566f3, j_id2=[Ljava.lang.
      Object;@e9d52e, j_id10=[Ljava.lang.Object;@159742d, j_id11=[Ljava.lang.Object;@19c1dc4}}

      Second progress (10%) lifecycle:

      pValue: j_id1:j_id11
      logicalMap: {j_id1={j_id3=[Ljava.lang.Object;@984b95, j_id4=[Ljava.lang.Object;@1d344e7, j_id5=[Ljava.lang.Object;@16db8d6, j_i
      d6=[Ljava.lang.Object;@1d0eefb, j_id7=[Ljava.lang.Object;@1be645d, j_id8=[Ljava.lang.Object;@116d55f, j_id9=[Ljava.lang.Object;@1e566f3, j_id2=[Ljava.lang.
      Object;@e9d52e, j_id10=[Ljava.lang.Object;@159742d, j_id11=[Ljava.lang.Object;@19c1dc4, j_id12=[Ljava.lang.Object;@1a27795}}

      The ending upload lifecycle:

      pValue: j_id1:j_id18
      logicalMap: {j_id1={j_id6=[Ljava.lang.Object;@1d0eefb, j_id7=[Ljava.lang.Object;@1be645d, j_id8=[Ljava.lang.Object;@116d55f, j_
      id9=[Ljava.lang.Object;@1e566f3, j_id2=[Ljava.lang.Object;@e9d52e, j_id10=[Ljava.lang.Object;@159742d, j_id11=[Ljava.lang.Object;@19c1dc4, j_id12=[Ljava.la
      ng.Object;@1a27795, j_id13=[Ljava.lang.Object;@122d847, j_id14=[Ljava.lang.Object;@181305e, j_id15=[Ljava.lang.Object;@727249, j_id16=[Ljava.lang.Object;@1
      aea1ed, j_id17=[Ljava.lang.Object;@1b8dc93, j_id18=[Ljava.lang.Object;@f4a7b6, j_id19=[Ljava.lang.Object;@803a13}}

      Pressed commandButton after the upload (see that the restored state is stale, back to 10% upload completion, which was second progress lifecycle):

      pValue: j_id1:j_id12
      logicalMap: {j_id1={j_id7=[Ljava.lang.Object;@1be645d, j_id8=[Ljava.lang.Object;@116d55f, j_id9=[Ljava.lang.Object;@1e566f3, j_
      id2=[Ljava.lang.Object;@e9d52e, j_id10=[Ljava.lang.Object;@159742d, j_id11=[Ljava.lang.Object;@19c1dc4, j_id13=[Ljava.lang.Object;@122d847, j_id14=[Ljava.l
      ang.Object;@181305e, j_id15=[Ljava.lang.Object;@727249, j_id16=[Ljava.lang.Object;@1aea1ed, j_id17=[Ljava.lang.Object;@1b8dc93, j_id18=[Ljava.lang.Object;@
      f4a7b6, j_id19=[Ljava.lang.Object;@803a13, j_id12=[Ljava.lang.Object;@1a27795, j_id20=[Ljava.lang.Object;@9815f3}}

        Issue Links

          Activity

          Hide
          Greg Dick added a comment -

          I have checked in two fixes in this case. One was better id disambiguation on the div that contains the state saving key. I think if there were multiple forms on the page not all the forms were getting the correct update applied leading to a form submitting an old value for the state key. This could lead to anything from old state to a JSF ViewExpiredException if the id returned was no longer in the LinkedHashMap.

          Second, I added code to InputFile to write the state saving key to the form that is embedded in the IFrame in the case of the FileUpload component. That allows the file to be uploaded, but there still seems to be an issue with the buttons disappearing.

          Show
          Greg Dick added a comment - I have checked in two fixes in this case. One was better id disambiguation on the div that contains the state saving key. I think if there were multiple forms on the page not all the forms were getting the correct update applied leading to a form submitting an old value for the state key. This could lead to anything from old state to a JSF ViewExpiredException if the id returned was no longer in the LinkedHashMap. Second, I added code to InputFile to write the state saving key to the form that is embedded in the IFrame in the case of the FileUpload component. That allows the file to be uploaded, but there still seems to be an issue with the buttons disappearing.
          Hide
          Greg Dick added a comment -

          I have checked in two fixes in this case. One was better id disambiguation on the div that contains the state saving key. I think if there were multiple forms on the page not all the forms were getting the correct update applied leading to a form submitting an old value for the state key. This could lead to anything from old state to a JSF ViewExpiredException if the id returned was no longer in the LinkedHashMap.

          Second, I added code to InputFile to write the state saving key to the form that is embedded in the IFrame in the case of the FileUpload component. That allows the file to be uploaded, but there still seems to be an issue with the buttons disappearing.

          Show
          Greg Dick added a comment - I have checked in two fixes in this case. One was better id disambiguation on the div that contains the state saving key. I think if there were multiple forms on the page not all the forms were getting the correct update applied leading to a form submitting an old value for the state key. This could lead to anything from old state to a JSF ViewExpiredException if the id returned was no longer in the LinkedHashMap. Second, I added code to InputFile to write the state saving key to the form that is embedded in the IFrame in the case of the FileUpload component. That allows the file to be uploaded, but there still seems to be an issue with the buttons disappearing.
          Hide
          Greg Dick added a comment -

          Also, and this was a bigger problem, I had to do state saving at the appropriate time. This would up the way it was because of difficulty using the DOMResponseWriter once the renderResponse method returned. Issues with a closed document that don't exist if you're working with a real stream.

          So currently the FormRenderers insert Marker divs into the DOM when rendering the Form. The call to writeState in the ViewHandler no longer does anything. Once the renderResponse method call is complete, but before the document is ended, we invoke state saving methods on the JSF stateManager object.

          Show
          Greg Dick added a comment - Also, and this was a bigger problem, I had to do state saving at the appropriate time. This would up the way it was because of difficulty using the DOMResponseWriter once the renderResponse method returned. Issues with a closed document that don't exist if you're working with a real stream. So currently the FormRenderers insert Marker divs into the DOM when rendering the Form. The call to writeState in the ViewHandler no longer does anything. Once the renderResponse method call is complete, but before the document is ended, we invoke state saving methods on the JSF stateManager object.

            People

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

              Dates

              • Created:
                Updated:
                Resolved: