Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-14410

Node components startup

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 3.0
    • None
    • Docs Required, Release Notes Required

    Description

      Need to define requirements/rules that should define components lifecycle and theirs mutual interaction.

      For testability purposes, we require that component dependencies are defined upfront and provided at the construction time. This additionaly requires that component dependencies form no cycles. Therefore, components form an acyclic directed graph that is constructed in topological sort order wrt root.

      Components created and initialized also in an order consistent with a topological sort of the components graph. This enforces serveral rules related to the components interaction:

      • Since metastorage watches can only be added during the component startup, the watch notification order is consistent with the component initialization order. I.e. if a component B depdends on a component A, then A receives watch notification prior to B.
      • Dependent component can directly call an API method on a dependee component (because it can obtain the dependee reference during construction). Direct inverse calls are prohibited (this is enforced by only acquiring component references during the components construction). Nevertheless, inverse call can be implemented by means of listeners or callbacks: the dependent component installs a listener to a dependeee, which can be later invoked.

      Attachments

        There are no Sub-Tasks for this issue.

        Activity

          People

            alapin Alexander Lapin
            slava.koptilin Vyacheslav Koptilin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 5.5h
                5.5h