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

Raft client should get leader metadata along while getting leader itself

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None

    Description

      Motivation

      This ticket is about TopologyAwareRaftGroupService which can subscribe on leader change. Necessary metadata is last log index and last applied index in leader's storage. 

      This will allow to remove readIndex requests on acceptance of a lease on leaseholder candidate. As we know that no write commands in replication group can happen in absence of leaseholder, this means that leaseholder should just catch up leader's last log index received with leader metadata to make sure that its local storage is up-to-date. Applied index can be not reliable as leader may be being recovered and applied index maybe in progress of catch-up with log index, but it might be useful to know applied index on leaseholder candidate to justify time of waiting for actual storage state.

      Definition of done

      readIndex call is removed from Replica#waitForActualState.

      Attachments

        Issue Links

          Activity

            People

              v.pyatkov Vladislav Pyatkov
              Denis Chudov Denis Chudov
              Alexander Lapin Alexander Lapin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:

                Time Tracking

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