Skip to content

storage: Make uninitialized replicas distinct types #6144

@bdarnell

Description

@bdarnell

Uninitialized Replicas are currently just a Replica with an incomplete RangeDescriptor. However, nearly all methods on uninitialized replicas are invalid and result in often-subtle failures like #6027. We should create a separate uninitializedReplica type which only contains a raftGroup and converts to a full replica when it gets its snapshot. The raft-related functionality in Store will need to change to look in both Store.replicas and Store.uninitReplicas instead of assuming the latter to be a subset of the former.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions