[Tarantool-patches] [PATCH 5/7] replication: send latest effective promote in initial join

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Wed Jun 16 00:00:25 MSK 2021


Thanks for working on this!

Hm. The patch makes me think why don't we send the Raft
checkpoint on join too?

Otherwise it might happen that a replica joined, didn't
get the most actual Raft term yet, then the leader died,
and the replica would start elections with term 1. Even if
the latest term was 1000.

Nothing critical, Raft will probably work, but it could
be an "optimization"? Also it would be consistent with the
libmo state - send all the snapshot data on join.

Btw, the limbo state contains a term. And it means
that after join, but before subscribe, the limbo's term
is bigger than raft's term. Even though in the comments
of the limbo we say:

	* It means the limbo's term might be smaller than the raft term, while
	* there are ongoing elections, or the leader is already known and this
	* instance hasn't read its PROMOTE request yet. During other times the
	* limbo and raft are in sync and the terms are the same.

which means the limbo term should be always <= raft term.
Can this break something? Is it possible to make a test confirming
that we can't send the limbo state before the raft state?


More information about the Tarantool-patches mailing list