Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-Alpha2
    • Fix Version/s: 2.0-Beta1, 2.0.0
    • Component/s: Bridge, Framework
    • Labels:
      None
    • Environment:
      client & server
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.), Compatibility/Configuration

      Description

      We need to implement form delta-submission so that the amount of data sent over the wire is minimized.

        Issue Links

          Activity

          Mircea Toma created issue -
          Mircea Toma made changes -
          Field Original Value New Value
          Assignee Mircea Toma [ mircea.toma ]
          Mircea Toma made changes -
          Salesforce Case []
          Component/s Bridge [ 10011 ]
          Component/s Framework [ 10013 ]
          Fix Version/s 2.0-Beta [ 10032 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20829 Tue Mar 02 10:10:13 MST 2010 mircea.toma ICE-5361 Start Hashtable implementation & test.
          Files Changed
          Commit graph ADD /projects/bridge-support/src/main/javascript/hashtable.js
          Commit graph ADD /projects/bridge-support/src/test/javascript/jshashtable.html
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20830 Tue Mar 02 10:10:55 MST 2010 mircea.toma ICE-5361 Start Hashtable implementation & test.
          Files Changed
          Commit graph ADD /projects/bridge-support/src/test/javascript/hashtable.html
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20831 Tue Mar 02 10:11:31 MST 2010 mircea.toma ICE-5361 Start Hashtable implementation & test.
          Files Changed
          Commit graph DEL /projects/bridge-support/src/test/javascript/jshashtable.html
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/unittest.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20834 Tue Mar 02 14:38:36 MST 2010 mircea.toma ICE-5361 Use method lookup provided by OO framework.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/hashtable.html
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20836 Tue Mar 02 14:49:12 MST 2010 mircea.toma ICE-5361 Use method lookup provided by OO framework.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20839 Tue Mar 02 14:58:15 MST 2010 mircea.toma ICE-5361 Implement remove method.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20840 Tue Mar 02 15:09:08 MST 2010 mircea.toma ICE-5361 Make removeAt method work in IE.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20853 Wed Mar 03 16:06:49 MST 2010 mircea.toma ICE-5361 Move OO fundamental operations in oo.js. Define hash, equal and asString methods for all objects. Make hashtable use object specific hash and equal implementations.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/collection.js
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/oo.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20856 Thu Mar 04 10:20:47 MST 2010 mircea.toma ICE-5361 Add each method.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20857 Thu Mar 04 10:27:12 MST 2010 mircea.toma ICE-5361 Add tests.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/hashtable.html
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20858 Thu Mar 04 10:36:39 MST 2010 mircea.toma ICE-5361 Add key removal test.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/hashtable.html
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20860 Thu Mar 04 12:00:21 MST 2010 mircea.toma ICE-5361 Start Implementing hashset.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/hashtable.html
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/collection.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20861 Thu Mar 04 14:13:22 MST 2010 mircea.toma ICE-5361 Bypass method dispatch for hash sets to improve complement operation.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20862 Thu Mar 04 14:56:50 MST 2010 mircea.toma ICE-5361 Rename private operator.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20866 Fri Mar 05 04:26:36 MST 2010 mircea.toma ICE-5361 Allow hash set initialization from a previously created collection.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20867 Fri Mar 05 05:08:39 MST 2010 mircea.toma ICE-5361 Implement HashSet.asString method.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20868 Fri Mar 05 05:20:46 MST 2010 mircea.toma ICE-5361 Fix hash default function.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/oo.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20869 Fri Mar 05 05:41:34 MST 2010 mircea.toma ICE-5361 Return only positive values.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/oo.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20870 Fri Mar 05 08:05:19 MST 2010 mircea.toma ICE-5361 Limit the number of generated buckets.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/oo.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20885 Tue Mar 09 10:57:09 MST 2010 mircea.toma ICE-5361 Use HashSet to implement client side form parameters diffing. Enable delta submit through a configuration parameter. Define phase listener to implement server side form parameters reconstruction.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/resources/META-INF/faces-config.xml
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/application.js
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/build.javascript.xml
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/push/BridgeSetup.java
          Commit graph ADD /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/event/DeltaSubmitPhaseListener.java
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/submit.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20926 Wed Mar 10 16:45:42 MST 2010 mircea.toma ICE-5361 Decode value before assigning it to input field. Refactor hidden input element generation.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/submit.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20929 Thu Mar 11 11:34:33 MST 2010 mircea.toma ICE-5361 Remove direct (non-patching) parameters from the map saved for the next diffing.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/event/DeltaSubmitPhaseListener.java
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20936 Thu Mar 11 14:44:34 MST 2010 mircea.toma ICE-5361 Create delta submit test application.
          Files Changed
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/build.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/inputText.xhtml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java/org/icefaces/demo
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/selectMany.xhtml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java/org
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java/org/icefaces/demo/deltasubmit/InputBean.java
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/WEB-INF/faces-config.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java/org/icefaces
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/index.html
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/resources
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/WEB-INF/web.xml
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/webapp/WEB-INF
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit/src/main/java/org/icefaces/demo/deltasubmit
          Commit graph ADD /icefaces/scratchpads/glimmer/samples/test/deltasubmit
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20945 Fri Mar 12 10:44:09 MST 2010 mircea.toma ICE-5361 Serialize hidden input elements.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/event/DeltaSubmitPhaseListener.java
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20956 Sat Mar 13 05:09:05 MST 2010 mircea.toma ICE-5361 Test if "not found" thunk is passed in. Avoid hidding previously defined operator with method function.
          Add 'tbody' to the table containing the test results to make it work in IE. Show error and error message when exception occurs inside a unit test.
          Files Changed
          Commit graph MODIFY /projects/bridge-support/src/main/javascript/hashtable.js
          Commit graph MODIFY /projects/bridge-support/src/test/javascript/unittest.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20957 Sat Mar 13 09:04:23 MST 2010 mircea.toma ICE-5361 Create input element then add to parent since IE6 doesn't like changing the type.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/submit.js
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #20967 Mon Mar 15 16:16:53 MDT 2010 mircea.toma ICE-5361 Calculate delta only when ice.deltasubmit.form parameter is present. Pick view state value from original form.
          Files Changed
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/push/BridgeSetup.java
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/java/org/icefaces/event/DeltaSubmitPhaseListener.java
          Commit graph MODIFY /icefaces/scratchpads/glimmer/core/src/main/javascript/submit.js
          Hide
          Mircea Toma added a comment -

          After a failed prototype and some additional discussions we came to the conclusion that we need a delta submit implementation that is not spreading like cancer throughout the entire code base. Also it should be easily turned on or off.

          Show
          Mircea Toma added a comment - After a failed prototype and some additional discussions we came to the conclusion that we need a delta submit implementation that is not spreading like cancer throughout the entire code base. Also it should be easily turned on or off.
          Hide
          Mircea Toma added a comment -

          The chosen implementation is supposed to truly calculate the difference in parameters between a previously sent submit and the current form submit. Only the added and removed parameters are sent to the server which is responsible to recreate the full form submission.

          Calculating the difference between to sets of parameters is an expensive operation (for Javascript). The complementing of two sets is done by iterating over the elements of the complemented set, while testing if the current element is found in the complementing set. When the lookup is sucessful the element it is not added to the resulting set.

          Show
          Mircea Toma added a comment - The chosen implementation is supposed to truly calculate the difference in parameters between a previously sent submit and the current form submit. Only the added and removed parameters are sent to the server which is responsible to recreate the full form submission. Calculating the difference between to sets of parameters is an expensive operation (for Javascript). The complementing of two sets is done by iterating over the elements of the complemented set, while testing if the current element is found in the complementing set. When the lookup is sucessful the element it is not added to the resulting set.
          Hide
          Mircea Toma added a comment -

          To improve the speed of lookup we need to implement a hashtable in Javascript. The lookup operations will be sped up considerably for sets larger than 3000 items.

          Show
          Mircea Toma added a comment - To improve the speed of lookup we need to implement a hashtable in Javascript. The lookup operations will be sped up considerably for sets larger than 3000 items.
          Hide
          Mircea Toma added a comment -

          Implemented Hashtable using a direct chaining strategy. See http://en.wikipedia.org/wiki/Hash_table#Separate_chaining .

          Show
          Mircea Toma added a comment - Implemented Hashtable using a direct chaining strategy. See http://en.wikipedia.org/wiki/Hash_table#Separate_chaining .
          Hide
          Mircea Toma added a comment -

          Implemented SDBM hash function. See http://www.cse.yorku.ca/~oz/hash.html .

          Show
          Mircea Toma added a comment - Implemented SDBM hash function. See http://www.cse.yorku.ca/~oz/hash.html .
          Hide
          Mircea Toma added a comment -

          Implemented Hashset based on the hash table operations. This is the structure we need to hold the paramerters of a form submit to allow fast lookup to the contained elements.

          Implemented complement operation for the Hashset. The operation is attached to the Hashset object to allow fast access to the internals of the underlying hashtable's primitive operations.

          Show
          Mircea Toma added a comment - Implemented Hashset based on the hash table operations. This is the structure we need to hold the paramerters of a form submit to allow fast lookup to the contained elements. Implemented complement operation for the Hashset. The operation is attached to the Hashset object to allow fast access to the internals of the underlying hashtable's primitive operations.
          Hide
          Mircea Toma added a comment -

          Created unit test to verify Hashtable and Hashset functionality and also empirical performance tests.

          Show
          Mircea Toma added a comment - Created unit test to verify Hashtable and Hashset functionality and also empirical performance tests.
          Hide
          Mircea Toma added a comment -

          Started delta submit implementation.
          Modified ice.submit function to calculate the complement between the sets of parameters generated by the previous ice.submit function invocation and paramaeters calculated for the current invocations.

          The previous parameters are saved as a property on the form element.

          Normally, the first form submit does not a previous set of parameters. To avoid sending a large form submit the initial parameters are calculated for each form on page load.

          Show
          Mircea Toma added a comment - Started delta submit implementation. Modified ice.submit function to calculate the complement between the sets of parameters generated by the previous ice.submit function invocation and paramaeters calculated for the current invocations. The previous parameters are saved as a property on the form element. Normally, the first form submit does not a previous set of parameters. To avoid sending a large form submit the initial parameters are calculated for each form on page load.
          Hide
          Mircea Toma added a comment -

          Introduced DeltaSubmitPhaseListener phase lister that reconstructs the full set of parameters by using the previous set of parameters (saved as attribute on the form component) the submitted delta parameters. The processing is done before apply-request-phase so that the components will the calculated parameters for decoding.

          Show
          Mircea Toma added a comment - Introduced DeltaSubmitPhaseListener phase lister that reconstructs the full set of parameters by using the previous set of parameters (saved as attribute on the form component) the submitted delta parameters. The processing is done before apply-request-phase so that the components will the calculated parameters for decoding.
          Hide
          Mircea Toma added a comment - - edited

          Make delta submit feature configurable. Setting 'org.icefaces.deltaSubmit' context parameter to 'true' enables the delta submit feature.

          Show
          Mircea Toma added a comment - - edited Make delta submit feature configurable. Setting 'org.icefaces.deltaSubmit' context parameter to 'true' enables the delta submit feature.
          Mircea Toma made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Mircea Toma made changes -
          Salesforce Case []
          Affects [Documentation (User Guide, Ref. Guide, etc.)]
          Ken Fyten made changes -
          Link This issue is duplicated by ICE-5159 [ ICE-5159 ]
          Ken Fyten made changes -
          Salesforce Case []
          Affects [Documentation (User Guide, Ref. Guide, etc.)] [Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial, Compatibility/Configuration]
          Ken Fyten made changes -
          Salesforce Case []
          Affects [Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial, Compatibility/Configuration] [Documentation (User Guide, Ref. Guide, etc.), Compatibility/Configuration]
          Ken Fyten made changes -
          Salesforce Case []
          Fix Version/s 2.0-Beta [ 10231 ]
          Fix Version/s 2.0-Alpha3 [ 10032 ]
          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:
              Mircea Toma
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: