Clone
Murtadha Makki Al Hubail
committed
on 20 Sep 18
[NO ISSUE][REPL] Ensure Valid Component ID is Initialized On Replica Sync
- user model changes: no
- storage format changes: no
- interface … Show more
[NO ISSUE][REPL] Ensure Valid Component ID is Initialized On Replica Sync

- user model changes: no

- storage format changes: no

- interface changes: yes

Details:

- Currently, the first time a replica is synchronized from master,

 the valid component id on each replicated index's initial checkpoint

 will be the initial value of a component id (-1). This value is

 fixed when the the replica receives a flushed component from

 the index. However, if the master fails before any component is

 flushed to a replica and that replica is promoted to master, it

 will start from an invalid component id. This change ensures that

 the initial checkpoint of replicated indexes is initialized to

 the maximum component id that appears on master. This will ensure

 that if the replica is promoted, it will at least start from

 a component that wasn't previously used on master.

- Replace assertion of component ids validation by illegal state.

Change-Id: I85395ad823a630725c4cab4bead1c61546dc61ae

Reviewed-on: https://asterix-gerrit.ics.uci.edu/2973

Sonar-Qube: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Tested-by: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Reviewed-by: Michael Blow <mblow@apache.org>

Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Show less