ICEfaces
  1. ICEfaces
  2. ICE-7693

ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.0
    • Fix Version/s: 3.0.1, EE-3.0.0.GA
    • Component/s: ACE-Components
    • Labels:
      None
    • Environment:

      Description

      When ace:ajax is added to an ace:tabSet in server side mode sometimes the tabs don't change completely. Sometimes you can see the initial tab fading out or the new tab fading in, or sometimes the content of the tabSet becomes empty and nothing happens. This doesn't occur when the ace:ajax component is removed from the tabSet.
       
      To reproduce:
      1. Build / deploy test app from above location
      2. Navigate to TabSet Ajax test (bottom of the page)
      3. Try changing tabs in any of the server side tests
      It can be quite inconsistent so if it works the first time just try again.

        Activity

        Cruz Miraback created issue -
        Ken Fyten made changes -
        Field Original Value New Value
        Salesforce Case []
        Fix Version/s 3.0 [ 10241 ]
        Assignee Priority P1
        Assignee Mark Collette [ mark.collette ]
        Ken Fyten made changes -
        Salesforce Case []
        Assignee Priority P1 P2
        Ken Fyten made changes -
        Salesforce Case []
        Assignee Priority P2 P1
        Ken Fyten made changes -
        Fix Version/s 3.0.1 [ 10282 ]
        Fix Version/s 3.0 [ 10241 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28150 Mon Mar 05 06:11:03 MST 2012 mark.collette ICE-7693 : ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used
        Files Changed
        Commit graph MODIFY /icefaces3/trunk/icefaces/ace/component/resources/icefaces.ace/tabset/tabset.js
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28151 Mon Mar 05 06:18:30 MST 2012 mark.collette ICE-7693 : ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used
        Files Changed
        Commit graph MODIFY /icefaces3/branches/icefaces-3.0.x-maintenance/icefaces/ace/component/resources/icefaces.ace/tabset/tabset.js
        Hide
        Mark Collette added a comment -

        Analysis of the differences of code paths take between the ajax and non-ajax cases showed that the working non-ajax case had code executing after the successful conclusion of the form submit, which was not run in the ajax case. The code was refactored to run in both scenarios, and then the ajax case started working properly.

        icefaces3 trunk
        Subversion 28150

        icefaces-3.0.x-maintenance
        Subversion 28151

        Show
        Mark Collette added a comment - Analysis of the differences of code paths take between the ajax and non-ajax cases showed that the working non-ajax case had code executing after the successful conclusion of the form submit, which was not run in the ajax case. The code was refactored to run in both scenarios, and then the ajax case started working properly. icefaces3 trunk Subversion 28150 icefaces-3.0.x-maintenance Subversion 28151
        Mark Collette made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Salesforce Case []
        Fix Version/s EE-3.0.0.GA [ 10262 ]
        Security Private [ 10001 ]
        Hide
        Cruz Miraback added a comment -

        This issue is still occurring for me on Icefaces3.0.x-maintenance revision# 28204. I tested in IE8/9, FF3.6/10, Chrome17 and I am still unable to switch tabs when ace:ajax is added to an ace:tabSet in server side mode. Please investigate.

        Show
        Cruz Miraback added a comment - This issue is still occurring for me on Icefaces3.0.x-maintenance revision# 28204. I tested in IE8/9, FF3.6/10, Chrome17 and I am still unable to switch tabs when ace:ajax is added to an ace:tabSet in server side mode. Please investigate.
        Cruz Miraback made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28309 Tue Mar 13 18:47:25 MDT 2012 mark.collette ICE-7693 : ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used
        Files Changed
        Commit graph MODIFY /icefaces3/branches/icefaces-3.0.x-maintenance/icefaces/ace/component/resources/icefaces.ace/tabset/tabset.js
        Commit graph MODIFY /icefaces3/branches/icefaces-3.0.x-maintenance/icefaces/ace/component/src/org/icefaces/ace/component/ajax/AjaxBehaviorRenderer.java
        Hide
        Mark Collette added a comment -

        Investigation with QA team found that ICE-7501 had diverged the trunk from the branch, so that ace:ajax javascript calls were happening differently. The branch was still using the javascript function, instead of javascript parameters approach, to reduce release regression risk.

        Essentially, the branch lacked a simple means for the tabSet's javascript to make use of the onsuccess callback for its own processing. A technique was used that builds on a previous extension mechanism, for creating a means for the component to specify its own onsuccess handling, before the application's from the ace:ajax tag. There was an implementation difficulty due to arguments scoping of nested functions, but that was worked around.

        icefaces-3.0.x-maintenance
        Subversion 28309

        Show
        Mark Collette added a comment - Investigation with QA team found that ICE-7501 had diverged the trunk from the branch, so that ace:ajax javascript calls were happening differently. The branch was still using the javascript function, instead of javascript parameters approach, to reduce release regression risk. Essentially, the branch lacked a simple means for the tabSet's javascript to make use of the onsuccess callback for its own processing. A technique was used that builds on a previous extension mechanism, for creating a means for the component to specify its own onsuccess handling, before the application's from the ace:ajax tag. There was an implementation difficulty due to arguments scoping of nested functions, but that was worked around. icefaces-3.0.x-maintenance Subversion 28309
        Mark Collette made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Cruz Miraback added a comment -

        The original issue has been fixed, although when testing I've come across some other issues:

        "serverSideTabChange" Event Test w/ TabChangeListener attribute

        • When changing tabs with this configuration the event is fired but the second tab's content is never displayed. I am able to make the second tab content render if I click the 'Reset Values' button on the test page.

        "serverSideTabChange" Event Test w/ Ajax Disabled

        • When changing tabs with this configuration the second tab's content is never displayed.

        To reproduce:
        1. Build / deploy test app from this location: I've used this test here: http://server.ice:8888/svn/repo/qa/trunk/Regression-Icefaces2/Sparkle/tabset
        2. Navigate to TabSet Ajax test
        3. Try changing tabs on each of the above test

        This is maintenance branch revision# 28309.

        Show
        Cruz Miraback added a comment - The original issue has been fixed, although when testing I've come across some other issues: "serverSideTabChange" Event Test w/ TabChangeListener attribute When changing tabs with this configuration the event is fired but the second tab's content is never displayed. I am able to make the second tab content render if I click the 'Reset Values' button on the test page. "serverSideTabChange" Event Test w/ Ajax Disabled When changing tabs with this configuration the second tab's content is never displayed. To reproduce: 1. Build / deploy test app from this location: I've used this test here: http://server.ice:8888/svn/repo/qa/trunk/Regression-Icefaces2/Sparkle/tabset 2. Navigate to TabSet Ajax test 3. Try changing tabs on each of the above test This is maintenance branch revision# 28309.
        Cruz Miraback made changes -
        Resolution Fixed [ 1 ]
        Status Resolved [ 5 ] Reopened [ 4 ]
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28342 Thu Mar 15 06:13:28 MDT 2012 mark.collette ICE-7693 : ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used
        Files Changed
        Commit graph MODIFY /icefaces3/branches/icefaces-3.0.x-maintenance/icefaces/ace/component/resources/icefaces.ace/tabset/tabset.js
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28343 Thu Mar 15 07:08:19 MDT 2012 mark.collette ICE-7693 : ace:tabSet: Tabs not loading completely in server side mode when ace:ajax is used
        Files Changed
        Commit graph MODIFY /icefaces3/trunk/icefaces/ace/component/resources/icefaces.ace/tabset/tabset.js
        Hide
        Mark Collette added a comment -

        For this issue: "serverSideTabChange" Event Test w/ TabChangeListener attribute
        I tested in Firefox, Chrome, Safari and couldn't figure out why I could not reproduce the issue that QA had found. But then I ran an svn diff on tabSetAjax.xhtml and found this local change:

        192-168-1-4:tabset mark$ svn diff web/tabSetAjax.xhtml
        Index: web/tabSetAjax.xhtml
        ===================================================================
        — web/tabSetAjax.xhtml (revision 30149)
        +++ web/tabSetAjax.xhtml (working copy)
        @@ -110,7 +110,7 @@
        <ace:tabPane id="tabPane2" label="TabPane 2">
        <h:outputText id="tabPane2Content" value="TabPane 2 Content"/>
        </ace:tabPane>

        • <ace:ajax event="serverSideTabChange" execute="@all" render="statusMsg" listener="$ {ajaxTestBean.ajaxEventListener}" />
          + <ace:ajax event="serverSideTabChange" execute="@all" render="@this statusMsg" listener="${ajaxTestBean.ajaxEventListener}

          " />
          </ace:tabSet>
          <h3>Results:</h3>
          <ul>
          @@ -173,4 +173,4 @@
          </h:panelGroup>
          <a href="index.html">Goto Main page</a>
          </h:body>
          -</html>
          \ No newline at end of file
          +</html>

        Basically, at some point I had seen that this wasn't working properly, modified the test app, and manually added @this to the render attribute on the ace:ajax tag. The component relies on itself getting rendered, so that its javascript will execute after the tab change. In the other tests on the same page, either @all is given, or nothing is specified to render, in which case the default is @all in TabSetMeta. The Ajax disabled test actually has the same problem with not executing @this, since execute is specified in the ace:ajax tag, so @all is no longer the default. Although fixing this issue still doesn't address the ajax disabled problem.

        For the branch, the code fix for the component is straightforward, just need to add "@this" the render index of the arguments (as well as to the execute index, which isn't being shown in the test but is still needed)

        icefaces-3.0.x-maintenance
        Subversion 28342

        Show
        Mark Collette added a comment - For this issue: "serverSideTabChange" Event Test w/ TabChangeListener attribute I tested in Firefox, Chrome, Safari and couldn't figure out why I could not reproduce the issue that QA had found. But then I ran an svn diff on tabSetAjax.xhtml and found this local change: 192-168-1-4:tabset mark$ svn diff web/tabSetAjax.xhtml Index: web/tabSetAjax.xhtml =================================================================== — web/tabSetAjax.xhtml (revision 30149) +++ web/tabSetAjax.xhtml (working copy) @@ -110,7 +110,7 @@ <ace:tabPane id="tabPane2" label="TabPane 2"> <h:outputText id="tabPane2Content" value="TabPane 2 Content"/> </ace:tabPane> <ace:ajax event="serverSideTabChange" execute="@all" render="statusMsg" listener="$ {ajaxTestBean.ajaxEventListener}" /> + <ace:ajax event="serverSideTabChange" execute="@all" render="@this statusMsg" listener="${ajaxTestBean.ajaxEventListener} " /> </ace:tabSet> <h3>Results:</h3> <ul> @@ -173,4 +173,4 @@ </h:panelGroup> <a href="index.html">Goto Main page</a> </h:body> -</html> \ No newline at end of file +</html> Basically, at some point I had seen that this wasn't working properly, modified the test app, and manually added @this to the render attribute on the ace:ajax tag. The component relies on itself getting rendered, so that its javascript will execute after the tab change. In the other tests on the same page, either @all is given, or nothing is specified to render, in which case the default is @all in TabSetMeta. The Ajax disabled test actually has the same problem with not executing @this, since execute is specified in the ace:ajax tag, so @all is no longer the default. Although fixing this issue still doesn't address the ajax disabled problem. For the branch, the code fix for the component is straightforward, just need to add "@this" the render index of the arguments (as well as to the execute index, which isn't being shown in the test but is still needed) icefaces-3.0.x-maintenance Subversion 28342
        Hide
        Mark Collette added a comment -

        Same problem was on trunk, but the resolution was technically different due to the ICE-7501 discrepancy.

        trunk
        Subversion 28343

        Show
        Mark Collette added a comment - Same problem was on trunk, but the resolution was technically different due to the ICE-7501 discrepancy. trunk Subversion 28343
        Hide
        Mark Collette added a comment -

        The problem with Ajax Disabled is part of a larger issue, which is encapsulated in this jira:
        ICE-7908 : ace:ajax disabled inconsistent behaviour

        Show
        Mark Collette added a comment - The problem with Ajax Disabled is part of a larger issue, which is encapsulated in this jira: ICE-7908 : ace:ajax disabled inconsistent behaviour
        Mark Collette made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Priority P1

          People

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

            Dates

            • Created:
              Updated:
              Resolved: