Search Results for

    Show / Hide Table of Contents

    Class TestSnapshotStore

    In-memory persistence snapshot store implementation which behavior could be controlled by interceptors.

    Inheritance
    object
    ActorBase
    SnapshotStore
    MemorySnapshotStore
    TestSnapshotStore
    Implements
    IInternalActor
    Inherited Members
    MemorySnapshotStore.Snapshots
    SnapshotStore.Receive(object)
    ActorBase.Sender
    ActorBase.Self
    ActorBase.Context
    ActorBase.AroundReceive(Receive, object)
    ActorBase.EmptyReceive
    ActorBase.Unhandled(object)
    ActorBase.Become(Receive)
    ActorBase.BecomeStacked(Receive)
    ActorBase.UnbecomeStacked()
    ActorBase.SetReceiveTimeout(TimeSpan?)
    ActorBase.AroundPreRestart(Exception, object)
    ActorBase.AroundPreStart()
    ActorBase.PreStart()
    ActorBase.AroundPostRestart(Exception, object)
    ActorBase.PreRestart(Exception, object)
    ActorBase.PostRestart(Exception)
    ActorBase.AroundPostStop()
    ActorBase.PostStop()
    ActorBase.SupervisorStrategy()
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Akka.Persistence.TestKit
    Assembly: Akka.Persistence.TestKit.dll
    Syntax
    public class TestSnapshotStore : MemorySnapshotStore, IInternalActor

    Methods

    | Edit this page View Source

    DeleteAsync(SnapshotMetadata, CancellationToken)

    Plugin API: Deletes the snapshot identified by metadata.

    This call is protected with a circuit-breaker

    Declaration
    protected override Task DeleteAsync(SnapshotMetadata metadata, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    SnapshotMetadata metadata

    Snapshot metadata.

    CancellationToken cancellationToken

    CancellationToken used to signal cancelled snapshot operation

    Returns
    Type Description
    Task
    Overrides
    MemorySnapshotStore.DeleteAsync(SnapshotMetadata, CancellationToken)
    | Edit this page View Source

    DeleteAsync(string, SnapshotSelectionCriteria, CancellationToken)

    Plugin API: Deletes all snapshots matching provided criteria.

    This call is protected with a circuit-breaker

    Declaration
    protected override Task DeleteAsync(string persistenceId, SnapshotSelectionCriteria criteria, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    string persistenceId

    Id of the persistent actor.

    SnapshotSelectionCriteria criteria

    Selection criteria for deleting.

    CancellationToken cancellationToken

    CancellationToken used to signal cancelled snapshot operation

    Returns
    Type Description
    Task
    Overrides
    MemorySnapshotStore.DeleteAsync(string, SnapshotSelectionCriteria, CancellationToken)
    | Edit this page View Source

    FromRef(IActorRef)

    Create proxy object from snapshot store actor reference which can alter behavior of snapshot store.

    Declaration
    public static ITestSnapshotStore FromRef(IActorRef actor)
    Parameters
    Type Name Description
    IActorRef actor

    Journal actor reference.

    Returns
    Type Description
    ITestSnapshotStore

    Proxy object to control TestSnapshotStore.

    Remarks

    Snapshot store actor must be of TestSnapshotStore type.

    | Edit this page View Source

    LoadAsync(string, SnapshotSelectionCriteria, CancellationToken)

    Plugin API: Asynchronously loads a snapshot.

    This call is protected with a circuit-breaker

    Declaration
    protected override Task<SelectedSnapshot> LoadAsync(string persistenceId, SnapshotSelectionCriteria criteria, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    string persistenceId

    Id of the persistent actor.

    SnapshotSelectionCriteria criteria

    Selection criteria for loading.

    CancellationToken cancellationToken

    CancellationToken used to signal cancelled snapshot operation

    Returns
    Type Description
    Task<SelectedSnapshot>
    Overrides
    MemorySnapshotStore.LoadAsync(string, SnapshotSelectionCriteria, CancellationToken)
    | Edit this page View Source

    ReceivePluginInternal(object)

    Plugin API: Allows plugin implementers to use f.PipeTo(Self) and handle additional messages for implementing advanced features

    Declaration
    protected override bool ReceivePluginInternal(object message)
    Parameters
    Type Name Description
    object message

    TBD

    Returns
    Type Description
    bool

    TBD

    Overrides
    SnapshotStore.ReceivePluginInternal(object)
    | Edit this page View Source

    SaveAsync(SnapshotMetadata, object, CancellationToken)

    Plugin API: Asynchronously saves a snapshot.

    This call is protected with a circuit-breaker

    Declaration
    protected override Task SaveAsync(SnapshotMetadata metadata, object snapshot, CancellationToken cancellationToken)
    Parameters
    Type Name Description
    SnapshotMetadata metadata

    Snapshot metadata.

    object snapshot

    Snapshot.

    CancellationToken cancellationToken

    CancellationToken used to signal cancelled snapshot operation

    Returns
    Type Description
    Task
    Overrides
    MemorySnapshotStore.SaveAsync(SnapshotMetadata, object, CancellationToken)

    Implements

    IInternalActor

    Extension Methods

    ObjectExtensions.IsDefaultForType<T>(T)
    ObjectExtensions.AsOption<T>(T)
    Extensions.AsInstanceOf<T>(object)
    In this article
    • githubEdit this page
    • View Source
    Back to top
    Contribute
    • Project Chat
    • Discussion Forum
    • Source Code
    Support
    • Akka.NET Support Plans
    • Akka.NET Observability Tools
    • Akka.NET Training & Consulting
    Maintained By
    • Petabridge - The Akka.NET Company
    • Learn Akka.NET