These are chat archives for atomix/atomix

18th
Sep 2017
Andrew Audibert
@aaudiber
Sep 18 2017 22:25
Hey @kuujo, we talked a while back about how, after restarting, a Raft state machine could receive commands that came before the latest snapshot. For example, if the persistent state is [99-102.log, 100.snapshot], a fresh state machine will receive apply(99), then apply(100), then installSnapshot(100), then apply(101), etc. My question is whether it makes sense for the framework to skip applying 98 and 99 since they will be overwritten by a snapshot anyway. This comes up because going from zero-state to applying 99 and 100 may look suspicious from the state machine’s perspective, causing side effects such as logging warnings. Is there any reason to apply 99 and 100 to the state machine when it is known that a snapshot for 100 already exists?