Part of #8404 (AOF MVP). Design: Global-command barrier.
Scope:
- Extract the apply logic from
DflyShardReplica::ExecuteTx into a reusable JournalApplier,
used by replica stable sync and by AOF replay.
- Extend
MultiShardExecution (tx_executor.cc): the participant count is the number of chains
that have not reached end of log. A chain at end of log counts as arrived at every barrier and
wakes the fibers already waiting.
- Classify every global command journaled on all shards (FLUSH*, FT.CREATE / ALTER / DROPINDEX /
SYNUPDATE). One-copy records such as MOVE bypass the barrier. IsGlobalCmd only knows FLUSH*
today.
Done when: replication tests pass unchanged, and unit tests cover the end-of-log wakeup and
MOVE followed by FLUSHALL without deadlock.
Open edge cases to settle: verify the txid lockstep argument in code, or make txids unique
across restarts.
Part of #8404 (AOF MVP). Design: Global-command barrier.
Scope:
DflyShardReplica::ExecuteTxinto a reusableJournalApplier,used by replica stable sync and by AOF replay.
MultiShardExecution(tx_executor.cc): the participant count is the number of chainsthat have not reached end of log. A chain at end of log counts as arrived at every barrier and
wakes the fibers already waiting.
SYNUPDATE). One-copy records such as MOVE bypass the barrier.
IsGlobalCmdonly knows FLUSH*today.
Done when: replication tests pass unchanged, and unit tests cover the end-of-log wakeup and
MOVE followed by FLUSHALL without deadlock.
Open edge cases to settle: verify the txid lockstep argument in code, or make txids unique
across restarts.