ICEfaces
  1. ICEfaces
  2. ICE-4616

ICEfaces 2.0: compat auctionMonitor rendering and interactivity

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-Alpha3
    • Fix Version/s: 2.0-Alpha2, 2.0.0
    • Component/s: None
    • Labels:
      None
    • Environment:
      ICEfaces

      Description


      ICEfaces 2.0 compat/auctionMonitor does not render correctly and it is not interactive.
      1. table-element-update_ie-fix.patch
        2 kB
        Mircea Toma
      2. table-element-update.improved.patch
        2 kB
        Mircea Toma
      3. table-element-update.patch
        0.8 kB
        Mircea Toma

        Issue Links

          Activity

          Ted Goddard created issue -
          Hide
          Ted Goddard added a comment -

          First step is just to investigate the problem. Note that this application serves as a test case for users porting existing ICEfaces 1.8 applications to ICEfaces 2.0, so we should prefer fixes in icefaces-compat to application changes.

          Show
          Ted Goddard added a comment - First step is just to investigate the problem. Note that this application serves as a test case for users porting existing ICEfaces 1.8 applications to ICEfaces 2.0, so we should prefer fixes in icefaces-compat to application changes.
          Ted Goddard made changes -
          Field Original Value New Value
          Assignee Deryk Sinotte [ deryk.sinotte ]
          Deryk Sinotte made changes -
          Assignee Deryk Sinotte [ deryk.sinotte ] Mircea Toma [ mircea.toma ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19025 Thu Jul 02 14:47:08 MDT 2009 mircea.toma ICE-4616 Add ICEfaces specific servlet mapping.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/WEB-INF/web.xml
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19026 Thu Jul 02 14:49:32 MDT 2009 mircea.toma ICE-4616 Replace vanilla 'head' and 'body' tags with their corresponding h:* components.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/auctionMonitor.xhtml
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19027 Thu Jul 02 14:52:27 MDT 2009 mircea.toma ICE-4616 Reference jsf.js resource.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/auctionMonitor.xhtml
          Hide
          Mircea Toma added a comment -

          Add /icefaces/* servlet mapping for FacesServlet.

          Show
          Mircea Toma added a comment - Add /icefaces/* servlet mapping for FacesServlet.
          Hide
          Mircea Toma added a comment -

          Replace vanilla 'head' and 'body' tags with their corresponding h:* components. They are needed for resource injection.

          Show
          Mircea Toma added a comment - Replace vanilla 'head' and 'body' tags with their corresponding h:* components. They are needed for resource injection.
          Hide
          Mircea Toma added a comment -

          Reference jsf.js resource.

          Show
          Mircea Toma added a comment - Reference jsf.js resource.
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19036 Mon Jul 06 08:05:33 MDT 2009 mircea.toma ICE-4616 Move beans in ICEfaces non-standard request scope into session scope.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/WEB-INF/faces-config.xml
          Hide
          Mircea Toma added a comment - - edited

          Move beans in ICEfaces non-standard request scope into session scope. Thus same bean instances will be used between Ajax requests.

          Show
          Mircea Toma added a comment - - edited Move beans in ICEfaces non-standard request scope into session scope. Thus same bean instances will be used between Ajax requests.
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19038 Mon Jul 06 16:36:29 MDT 2009 mircea.toma ICE-4616 Serialize the element that triggered the submit.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/submit.js
          Hide
          Mircea Toma added a comment -

          Serialize also the element that triggered the submit so that ice:* components can identify themselves.

          Show
          Mircea Toma added a comment - Serialize also the element that triggered the submit so that ice:* components can identify themselves.
          Mircea Toma made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Mircea Toma made changes -
          Resolution Fixed [ 1 ]
          Status Resolved [ 5 ] Reopened [ 4 ]
          Hide
          Mircea Toma added a comment -

          Patch Mojarra JSF-RI Javascript code so that table elements like TD and TH are updated properly. See table-element-update.patch file.

          Show
          Mircea Toma added a comment - Patch Mojarra JSF-RI Javascript code so that table elements like TD and TH are updated properly. See table-element-update.patch file.
          Mircea Toma made changes -
          Attachment table-element-update.patch [ 11821 ]
          Hide
          Mircea Toma added a comment -

          Clicking repeatedly on "Bid" button and then "x" button makes the application to run out of memory pretty fast (about 10 clicks).

          Show
          Mircea Toma added a comment - Clicking repeatedly on "Bid" button and then "x" button makes the application to run out of memory pretty fast (about 10 clicks).
          Hide
          Ted Goddard added a comment -

          Table update patch reported to javaserverfaces issue tracker:

          https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1187

          Show
          Ted Goddard added a comment - Table update patch reported to javaserverfaces issue tracker: https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1187
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19042 Tue Jul 07 17:06:27 MDT 2009 ted.goddard wrapped panelGrid child markup with panelGroup (ICE-4616)
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/auctionMonitor.xhtml
          Hide
          Ted Goddard added a comment -

          The main problem with the appearance of the application involves the use of the <center> tag, but is not due to the <center> tag per se.

          When the panelGrid is used:

          <ice:panelGrid columns="5" >
          <center>
          <ice:commandLink action="#

          {AuctionBean.sortByTitle}" />
          </center>
          ...

          the behavior is different with ICEfaces 1.8 and JSF 2.0 (we may have encountered the same problem with a Facelets version of this page). The ICEfaces JSP parser parses the XML and represents the <center> tag as a single component. JSF 2.0, on the other hand, finds three components: "<center>", <ice:commandLink>, and "<center/>" causing the rendering of the panelGrid to be very different. The same problem would be encountered if any nested markup was used within the panelGrid. To repair the page, the individual cells of the panelGrid must be actual JSF components, such as panelGroup. The replacement markup is as follows:

          <ice:panelGrid columns="5" >
          <ice:panleGroup><center>
          <ice:commandLink action="#{AuctionBean.sortByTitle}

          " />
          </center></ice:panelGroup>
          ...

          Show
          Ted Goddard added a comment - The main problem with the appearance of the application involves the use of the <center> tag, but is not due to the <center> tag per se. When the panelGrid is used: <ice:panelGrid columns="5" > <center> <ice:commandLink action="# {AuctionBean.sortByTitle}" /> </center> ... the behavior is different with ICEfaces 1.8 and JSF 2.0 (we may have encountered the same problem with a Facelets version of this page). The ICEfaces JSP parser parses the XML and represents the <center> tag as a single component. JSF 2.0, on the other hand, finds three components: "<center>", <ice:commandLink>, and "<center/>" causing the rendering of the panelGrid to be very different. The same problem would be encountered if any nested markup was used within the panelGrid. To repair the page, the individual cells of the panelGrid must be actual JSF components, such as panelGroup. The replacement markup is as follows: <ice:panelGrid columns="5" > <ice:panleGroup><center> <ice:commandLink action="#{AuctionBean.sortByTitle} " /> </center></ice:panelGroup> ...
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19044 Wed Jul 08 07:06:17 MDT 2009 mircea.toma ICE-4616 Move session bound beans in 'view' scope.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/samples/auctionMonitor/web/WEB-INF/faces-config.xml
          Hide
          Mircea Toma added a comment -

          Move session bound beans in 'view' scope.

          Show
          Mircea Toma added a comment - Move session bound beans in 'view' scope.
          Hide
          Mircea Toma added a comment -

          Improved patch that works properly for all table child elements.

          Show
          Mircea Toma added a comment - Improved patch that works properly for all table child elements.
          Mircea Toma made changes -
          Hide
          Ted Goddard added a comment -

          Which browsers? Let's refine the patch a bit before we send it to Sun again – they've already applied the previous one. For instance, perhaps we can factor out parent.replaceChild().

          Why trim spaces? Perhaps that should be done on the server (not necessarily a choice for us here, since this is in the reference implementation.)

          Show
          Ted Goddard added a comment - Which browsers? Let's refine the patch a bit before we send it to Sun again – they've already applied the previous one. For instance, perhaps we can factor out parent.replaceChild(). Why trim spaces? Perhaps that should be done on the server (not necessarily a choice for us here, since this is in the reference implementation.)
          Hide
          Ted Goddard added a comment -

          compat/auctionMonitor starts working for me if I make a change like the following:

          Index: compat/components/src/main/resources/META-INF/resources/icesubmit.js
          ===================================================================
          — compat/components/src/main/resources/META-INF/resources/icesubmit.js (revision 19044)
          +++ compat/components/src/main/resources/META-INF/resources/icesubmit.js (working copy)
          @@ -14,7 +14,7 @@
          return false;
          }
          }

          • ice.submitForm(evt, form || formOf(component));
            + ice.submitEvent(evt, component, form || formOf(component));
            return false;
            }

          Mircea, perhaps you have a local change of this nature that is not checked in? commandButton does not work if it is not the "component" submitting the form (the current code submits the form anonymously).

          Show
          Ted Goddard added a comment - compat/auctionMonitor starts working for me if I make a change like the following: Index: compat/components/src/main/resources/META-INF/resources/icesubmit.js =================================================================== — compat/components/src/main/resources/META-INF/resources/icesubmit.js (revision 19044) +++ compat/components/src/main/resources/META-INF/resources/icesubmit.js (working copy) @@ -14,7 +14,7 @@ return false; } } ice.submitForm(evt, form || formOf(component)); + ice.submitEvent(evt, component, form || formOf(component)); return false; } Mircea, perhaps you have a local change of this nature that is not checked in? commandButton does not work if it is not the "component" submitting the form (the current code submits the form anonymously).
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19046 Wed Jul 08 15:40:29 MDT 2009 mircea.toma ICE-4616 Submit the component along with the form.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/compat/components/src/main/resources/META-INF/resources/icesubmit.js
          Hide
          Mircea Toma added a comment -

          You're right I missed to commit icesubmit.js changes. The fix is committed now.

          Show
          Mircea Toma added a comment - You're right I missed to commit icesubmit.js changes. The fix is committed now.
          Hide
          Mircea Toma added a comment -

          > Which browsers?

          Firefox, for sure.

          > Let's refine the patch a bit before we send it to Sun again – they've already applied the
          > previous one. For instance, perhaps we can factor out parent.replaceChild().

          The patch is almost similar with what we have in Trunk. With the first patch I completely forgot about the fact that browser are inserting intermediate elements. When I went back to Trunk code I remembered why I had to do the "while" loop.

          Show
          Mircea Toma added a comment - > Which browsers? Firefox, for sure. > Let's refine the patch a bit before we send it to Sun again – they've already applied the > previous one. For instance, perhaps we can factor out parent.replaceChild(). The patch is almost similar with what we have in Trunk. With the first patch I completely forgot about the fact that browser are inserting intermediate elements. When I went back to Trunk code I remembered why I had to do the "while" loop.
          Hide
          Mircea Toma added a comment -

          OutOfMemoryError is gone since the state saving was fixed. See https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1142 .

          Show
          Mircea Toma added a comment - OutOfMemoryError is gone since the state saving was fixed. See https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1142 .
          Mircea Toma made changes -
          Status Reopened [ 4 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Hide
          Mircea Toma added a comment -

          Fix table element update in IE. IE creates the "table" element only if "table" tag is part of the innerHTML markup. Also reverted the search in the array of table element names, native arrays are not indexed by cell values. See patch file: table-element-update_ie-fix.patch

          Show
          Mircea Toma added a comment - Fix table element update in IE. IE creates the "table" element only if "table" tag is part of the innerHTML markup. Also reverted the search in the array of table element names, native arrays are not indexed by cell values. See patch file: table-element-update_ie-fix.patch
          Mircea Toma made changes -
          Attachment table-element-update_ie-fix.patch [ 11833 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #19115 Fri Jul 24 09:44:44 MDT 2009 mircea.toma ICE-4616 Create application for testing DOM element update.
          Files Changed
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/resources
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/WEB-INF
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org/icefaces/demo/elementUpdate/TableBean.java
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org/icefaces/demo
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org/icefaces
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/input-element.xhtml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/build.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/index.html
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/WEB-INF/faces-config.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/WEB-INF/web.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org/icefaces/demo/elementUpdate
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/webapp/table-elements.xhtml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/elementUpdate/src/main/java/org/icefaces/demo/scopes
          Mircea Toma made changes -
          Link This issue depends on ICE-4777 [ ICE-4777 ]
          Ken Fyten made changes -
          Fix Version/s 2.0-Alpha2 [ 10214 ]
          Deryk Sinotte made changes -
          Link This issue blocks ICE-4795 [ ICE-4795 ]
          Ken Fyten made changes -
          Fix Version/s 2.0.0 [ 10230 ]
          Ken Fyten made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Mircea Toma
              Reporter:
              Ted Goddard
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: