package org.opendaylight.controller.cluster.raft;
+import java.io.OutputStream;
+import java.util.Optional;
import org.opendaylight.controller.cluster.raft.base.messages.ApplySnapshot;
+import org.opendaylight.controller.cluster.raft.persisted.Snapshot;
/**
* Interface for a snapshot phase state.
/**
* Persists a snapshot.
*
- * @param snapshotBytes the snapshot bytes
+ * @param snapshotState the snapshot State
+ * @param installSnapshotStream Optional OutputStream that is present if the snapshot is to also be installed
+ * on a follower.
* @param totalMemory the total memory threshold
*/
- void persist(byte[] snapshotBytes, long totalMemory);
+ void persist(Snapshot.State snapshotState, Optional<OutputStream> installSnapshotStream, long totalMemory);
/**
* Commit the snapshot by trimming the log.