Interface SnapshotStore

    • Method Detail

      • deleteAsync

        scala.concurrent.Future<scala.runtime.BoxedUnit> deleteAsync​(SnapshotMetadata metadata)
        Plugin API: deletes the snapshot identified by metadata.

        This call is protected with a circuit-breaker.

        Parameters:
        metadata - snapshot metadata.
      • deleteAsync

        scala.concurrent.Future<scala.runtime.BoxedUnit> deleteAsync​(java.lang.String persistenceId,
                                                                     SnapshotSelectionCriteria criteria)
        Plugin API: deletes all snapshots matching criteria.

        This call is protected with a circuit-breaker.

        Parameters:
        persistenceId - id of the persistent actor.
        criteria - selection criteria for deleting.
      • loadAsync

        scala.concurrent.Future<scala.Option<SelectedSnapshot>> loadAsync​(java.lang.String persistenceId,
                                                                          SnapshotSelectionCriteria criteria)
        Plugin API: asynchronously loads a snapshot.

        If the future Option is None then all events will be replayed, i.e. there was no snapshot. If snapshot could not be loaded the Future should be completed with failure. That is important because events may have been deleted and just replaying the events might not result in a valid state.

        This call is protected with a circuit-breaker.

        Parameters:
        persistenceId - id of the persistent actor.
        criteria - selection criteria for loading.
      • org$apache$pekko$persistence$snapshot$SnapshotStore$_setter_$receiveSnapshotStore_$eq

        void org$apache$pekko$persistence$snapshot$SnapshotStore$_setter_$receiveSnapshotStore_$eq​(scala.PartialFunction<java.lang.Object,​scala.runtime.BoxedUnit> x$1)
      • receive

        scala.PartialFunction<java.lang.Object,​scala.runtime.BoxedUnit> receive()
        Description copied from interface: Actor
        Scala API: This defines the initial actor behavior, it must return a partial function with the actor logic.
        Specified by:
        receive in interface Actor
      • receivePluginInternal

        scala.PartialFunction<java.lang.Object,​scala.runtime.BoxedUnit> receivePluginInternal()
        Plugin API Allows plugin implementers to use f pipeTo self and handle additional messages for implementing advanced features
      • receiveSnapshotStore

        scala.PartialFunction<java.lang.Object,​scala.runtime.BoxedUnit> receiveSnapshotStore()
      • saveAsync

        scala.concurrent.Future<scala.runtime.BoxedUnit> saveAsync​(SnapshotMetadata metadata,
                                                                   java.lang.Object snapshot)
        Plugin API: asynchronously saves a snapshot.

        This call is protected with a circuit-breaker.

        Parameters:
        metadata - snapshot metadata.
        snapshot - snapshot.
      • senderPersistentActor

        ActorRef senderPersistentActor()
        Documents intent that the sender() is expected to be the PersistentActor
      • tryReceivePluginInternal

        void tryReceivePluginInternal​(java.lang.Object evt)