FLUID-5220: Improve composite panel performance by not re-instantiating after init.

Metadata

Source
FLUID-5220
Type
Bug
Priority
Major
Status
Closed
Resolution
Fixed
Assignee
Justin Obara
Reporter
Justin Obara
Created
2013-11-21T15:26:56.460-0500
Updated
2016-07-08T08:41:33.198-0400
Versions
N/A
Fixed Versions
  1. 1.5
Component
  1. Prefs Framework

Description

Currently a composite panel will create the sub panels first to use methods such as produceTree from them, needed for rendering their markup. However, since the actual rendering process modifies the existing markup on the page, the DOM bindings are destroy and the components need to be re-instantiated to re-establish the connections. This means that all of the sub panels need to be created twice.

This can be improved by not re-instatiating but simply refreshing the DOMbinder. This means that all panels will need to have a new event onDomBind which will be used to trigger any listener that requires a DOM element. For example a this-ist listener that had been bound onCreate. Any invokers that will require a DOM element will need to be slow invokers with the dynamic flag set to true.

The onDomBind event in a panel will be triggered by onCreate, however, in a sub panel this will be overridden to be fired by afterRender.

The composite panel will need to under go some other changes to remove all of the now unnecessary forwarding of events and re-instantiation that it currently conducts.

Comments

  • Justin Obara commented 2013-11-27T15:46:52.710-0500

    Merged pull request ( https://github.com/fluid-project/infusion/pull/439 ) at 73889463d799973a3a858c921d7bd2f9361c5906

  • Michelle D'Souza commented 2013-11-27T16:08:05.777-0500

    Merged pull request ( https://github.com/fluid-project/prefsEditors/pull/58 ) at 902dd27de37c6f8879694829ee59175d951dd0e0

  • Antranig Basman commented 2016-05-03T22:32:51.494-0400

    The tests for this issue were found to be very faulty whilst tracking down sites of misuse of jqUnit.assertDeepEq while resolving FLUID-5901. They include the following problems:

    i) registering an onCreate listener after a component has been created
    ii) issuing "expect" calls out of line with respect to the sequence of actual test fixtures
    iii) making a faulty call to assertDeepEq with simply a value of "false" which counted as a pass as a result of FLUID-5901
    iv) Issuing inline configuration to a creator function rather than defining a grade

    The test was commented out as part of the fix for FLUID-5901 and needs to be rewritten