Class LocalSnapshotStore
- java.lang.Object
-
- akka.persistence.snapshot.japi.SnapshotStore
-
- org.opendaylight.controller.cluster.persistence.LocalSnapshotStore
-
- All Implemented Interfaces:
akka.actor.Actor,akka.actor.ActorLogging,akka.persistence.snapshot.SnapshotStore
public class LocalSnapshotStore extends akka.persistence.snapshot.japi.SnapshotStoreAkka SnapshotStore implementation backed by the local file system. This class was patterned after akka's LocalSnapshotStore class and exists because akka's version serializes to a byte[] before persisting to the file which will fail if the data reaches or exceeds Integer.MAX_VALUE in size. This class avoids that issue by serializing the data directly to the file.- Author:
- Thomas Pantelis
-
-
Constructor Summary
Constructors Constructor Description LocalSnapshotStore(com.typesafe.config.Config config)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description scala.concurrent.Future<Void>doDeleteAsync(akka.persistence.SnapshotMetadata metadata)scala.concurrent.Future<Void>doDeleteAsync(String persistenceId, akka.persistence.SnapshotSelectionCriteria criteria)scala.concurrent.Future<Optional<akka.persistence.SelectedSnapshot>>doLoadAsync(String persistenceId, akka.persistence.SnapshotSelectionCriteria criteria)scala.concurrent.Future<Void>doSaveAsync(akka.persistence.SnapshotMetadata metadata, Object snapshot)voidpreStart()-
Methods inherited from class akka.persistence.snapshot.japi.SnapshotStore
akka$actor$Actor$_setter_$context_$eq, akka$actor$Actor$_setter_$self_$eq, akka$actor$ActorLogging$$_log, akka$actor$ActorLogging$$_log_$eq, akka$persistence$snapshot$SnapshotStore$_setter_$akka$persistence$snapshot$SnapshotStore$$breaker_$eq, akka$persistence$snapshot$SnapshotStore$_setter_$akka$persistence$snapshot$SnapshotStore$$extension_$eq, akka$persistence$snapshot$SnapshotStore$_setter_$akka$persistence$snapshot$SnapshotStore$$publish_$eq, akka$persistence$snapshot$SnapshotStore$_setter_$receiveSnapshotStore_$eq, akka$persistence$snapshot$SnapshotStore$$breaker, akka$persistence$snapshot$SnapshotStore$$extension, akka$persistence$snapshot$SnapshotStore$$publish, aroundPostRestart, aroundPostStop, aroundPreRestart, aroundPreStart, aroundReceive, context, deleteAsync, deleteAsync, loadAsync, log, postRestart, postStop, preRestart, receive, receivePluginInternal, receiveSnapshotStore, saveAsync, self, sender, supervisorStrategy, unhandled
-
-
-
-
Method Detail
-
preStart
public void preStart() throws Exception- Specified by:
preStartin interfaceakka.actor.Actor- Overrides:
preStartin classakka.persistence.snapshot.japi.SnapshotStore- Throws:
Exception
-
doLoadAsync
public scala.concurrent.Future<Optional<akka.persistence.SelectedSnapshot>> doLoadAsync(String persistenceId, akka.persistence.SnapshotSelectionCriteria criteria)
-
doSaveAsync
public scala.concurrent.Future<Void> doSaveAsync(akka.persistence.SnapshotMetadata metadata, Object snapshot)
-
doDeleteAsync
public scala.concurrent.Future<Void> doDeleteAsync(akka.persistence.SnapshotMetadata metadata)
-
-