Interface RaftActorSnapshotCohort<T extends Snapshot.State>

Type Parameters:
T - type of state
All Known Implementing Classes:
NoopRaftActorSnapshotCohort

@NonNullByDefault public interface RaftActorSnapshotCohort<T extends Snapshot.State>
Interface for a class that participates in raft actor snapshotting.
Author:
Thomas Pantelis
  • Method Details

    • takeSnapshot

      @NonNull T takeSnapshot()
      Take a snapshot of current state.
      Returns:
      current snapshot state
    • applySnapshot

      void applySnapshot(@NonNull T snapshotState)
      This method is called to apply a snapshot installed by the leader.
      Parameters:
      snapshotState - a snapshot of the state of the actor
    • support

      Returns the StateSnapshot.
      Returns:
      the StateSnapshot