Merge pull request #13230 from serathius/storage
Move storage bootstrap to its package
This commit is contained in:
@ -109,13 +109,13 @@ func CreateConfigChangeEnts(lg *zap.Logger, ids []uint64, self uint64, term, ind
|
||||
return ents
|
||||
}
|
||||
|
||||
// GetIDs returns an ordered set of IDs included in the given snapshot and
|
||||
// GetEffectiveNodeIDsFromWalEntries returns an ordered set of IDs included in the given snapshot and
|
||||
// the entries. The given snapshot/entries can contain three kinds of
|
||||
// ID-related entry:
|
||||
// - ConfChangeAddNode, in which case the contained ID will Be added into the set.
|
||||
// - ConfChangeRemoveNode, in which case the contained ID will Be removed from the set.
|
||||
// - ConfChangeAddLearnerNode, in which the contained ID will Be added into the set.
|
||||
func GetIDs(lg *zap.Logger, snap *raftpb.Snapshot, ents []raftpb.Entry) []uint64 {
|
||||
func GetEffectiveNodeIDsFromWalEntries(lg *zap.Logger, snap *raftpb.Snapshot, ents []raftpb.Entry) []uint64 {
|
||||
ids := make(map[uint64]bool)
|
||||
if snap != nil {
|
||||
for _, id := range snap.Metadata.ConfState.Voters {
|
||||
|
Reference in New Issue
Block a user