Uploaded image for project: 'Fluid Infusion'
  1. Fluid Infusion
  2. FLUID-4922

Investigate performance of existing invoker system and implement "fast invokers" which cache arguments


    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.4
    • Fix Version/s: 1.5
    • Component/s: IoC System
    • Labels:


      With the resolution of FLUID-4709, the only remaining barrier to universal adoption of invokers as our solution for "methods" attached to the top level of components is their worrying performance issues, which have yet to be characterised, but are likely to be very serious.
      Each call to an invoker causes a complete resolution of all IoC-resolved arguments - if any of them mention components other than "

      {that}" this will cause a search up the component tree, and even if all non-argument positions resolve onto "{that}

      " we will still take a very expensive trip through fluid.embodyDemands. We should by default instantiate invokers as "fast invokers" which will cache all material resolved in the component tree (except references into models), and only show changes in argument positions which refer on to


      . This would enable invoker resolution to not be grievously slower than a standard method call after the first successful call.
      A new notation dynamic: true attached to an invoker would restore the old behaviour for invokers which bind onto improperly changing material.
      We should also in the far future consider a system similar to the DOM binder which is able to flush its cache under certain conditions where, for example, we apply some proper ChangeApplier semantics which do indeed support changes to component material outside their models - which we expect to occur on a much slower timescale than model-directed changes.
      We should investigate and compare the performance of "slow" and "fast" invokers after this implementation and circulate guidelines on baseline performance expectations.




            • Assignee:
              antranig Antranig Basman
              antranig Antranig Basman
            • Votes:
              0 Vote for this issue
              2 Start watching this issue


              • Created: