Search Results for

    Show / Hide Table of Contents

    Class PersistenceTestKit

    This class represents an Akka.NET Persistence TestKit that uses xUnit as its testing framework.

    Inheritance
    object
    TestKitBase
    TestKit
    PersistenceTestKit
    Implements
    IActorRefFactory
    IDisposable
    Inherited Members
    TestKit.Output
    TestKit.DefaultConfig
    TestKit.FullDebugConfig
    TestKit.Assertions
    TestKit.AfterAll()
    TestKit.InitializeLogger(ActorSystem)
    TestKit.InitializeLogger(ActorSystem, string)
    TestKit.Dispose(bool)
    TestKit.Dispose()
    TestKitBase.InitializeTest(ActorSystem, ActorSystemSetup, string, string)
    TestKitBase.InitializeTest(ActorSystem, Config, string, string)
    TestKitBase.Sys
    TestKitBase.TestKitSettings
    TestKitBase.LastSender
    TestKitBase.Now
    TestKitBase.Log
    TestKitBase.LastMessage
    TestKitBase.TestActor
    TestKitBase.EventFilter
    TestKitBase.CreateEventFilter(ActorSystem)
    TestKitBase.HasMessages
    TestKitBase.IgnoreMessages(Func<object, bool>)
    TestKitBase.IgnoreMessages<TMsg>(Func<TMsg, bool>)
    TestKitBase.IgnoreMessages<TMsg>()
    TestKitBase.IgnoreNoMessages()
    TestKitBase.Watch(IActorRef)
    TestKitBase.WatchAsync(IActorRef)
    TestKitBase.Unwatch(IActorRef)
    TestKitBase.UnwatchAsync(IActorRef)
    TestKitBase.SetAutoPilot(AutoPilot)
    TestKitBase.RemainingOrDefault
    TestKitBase.Remaining
    TestKitBase.RemainingOr(TimeSpan)
    TestKitBase.RemainingOrDilated(TimeSpan?)
    TestKitBase.Dilated(TimeSpan)
    TestKitBase.GetTimeoutOrDefault(TimeSpan?)
    TestKitBase.Shutdown(TimeSpan?, bool)
    TestKitBase.Shutdown(ActorSystem, TimeSpan?, bool)
    TestKitBase.ChildActorOf(Props, string, SupervisorStrategy, CancellationToken)
    TestKitBase.ChildActorOfAsync(Props, string, SupervisorStrategy, CancellationToken)
    TestKitBase.ChildActorOf(Props, SupervisorStrategy, CancellationToken)
    TestKitBase.ChildActorOfAsync(Props, SupervisorStrategy, CancellationToken)
    TestKitBase.ChildActorOf(Props, string, CancellationToken)
    TestKitBase.ChildActorOfAsync(Props, string, CancellationToken)
    TestKitBase.ChildActorOf(Props, CancellationToken)
    TestKitBase.ChildActorOfAsync(Props, CancellationToken)
    TestKitBase.CreateTestActor(string)
    TestKitBase.CreateTestProbe(string)
    TestKitBase.CreateTestProbe(ActorSystem, string)
    TestKitBase.CreateTestLatch(int)
    TestKitBase.CreateTestBarrier(int)
    TestKitBase.ActorOf(Props)
    TestKitBase.ActorOf(Props, string)
    TestKitBase.ActorOf<TActor>()
    TestKitBase.ActorOf<TActor>(string)
    TestKitBase.ActorOf<TActor>(Expression<Func<TActor>>)
    TestKitBase.ActorOf<TActor>(Expression<Func<TActor>>, string)
    TestKitBase.ActorOf(Action<IActorDsl, IActorContext>, string)
    TestKitBase.ActorOf(Action<IActorDsl>, string)
    TestKitBase.ActorSelection(ActorPath)
    TestKitBase.ActorSelection(string)
    TestKitBase.ActorSelection(IActorRef, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(Props, IActorRef, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(Props, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(Expression<Func<TActor>>, IActorRef, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(Expression<Func<TActor>>, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(IActorRef, string)
    TestKitBase.ActorOfAsTestActorRef<TActor>(string)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(Props, IActorRef, string, bool)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(Props, string, bool)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(IActorRef, string, bool)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(string, bool)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(Expression<Func<TFsmActor>>, IActorRef, string, bool)
    TestKitBase.ActorOfAsTestFSMRef<TFsmActor, TState, TData>(Expression<Func<TFsmActor>>, string, bool)
    TestKitBase.AwaitAssert(Action, TimeSpan?, TimeSpan?, CancellationToken)
    TestKitBase.AwaitAssertAsync(Action, TimeSpan?, TimeSpan?, CancellationToken)
    TestKitBase.AwaitAssertAsync(Func<Task>, TimeSpan?, TimeSpan?, CancellationToken)
    TestKitBase.AwaitCondition(Func<bool>, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<Task<bool>>, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<bool>, CancellationToken)
    TestKitBase.AwaitCondition(Func<bool>, TimeSpan?, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<Task<bool>>, TimeSpan?, CancellationToken)
    TestKitBase.AwaitCondition(Func<bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<Task<bool>>, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitCondition(Func<bool>, TimeSpan?, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<Task<bool>>, TimeSpan?, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitConditionAsync(Func<bool>, TimeSpan?, TimeSpan?, string, CancellationToken)
    TestKitBase.AwaitConditionNoThrow(Func<bool>, TimeSpan, TimeSpan?, CancellationToken)
    TestKitBase.AwaitConditionNoThrowAsync(Func<Task<bool>>, TimeSpan, TimeSpan?, CancellationToken)
    TestKitBase.AwaitConditionNoThrowAsync(Func<bool>, TimeSpan, TimeSpan?, CancellationToken)
    TestKitBase.InternalAwaitCondition(Func<bool>, TimeSpan, TimeSpan?, Action<string, object[]>, CancellationToken)
    TestKitBase.InternalAwaitConditionAsync(Func<Task<bool>>, TimeSpan, TimeSpan?, Action<string, object[]>, CancellationToken)
    TestKitBase.InternalAwaitCondition(Func<bool>, TimeSpan, TimeSpan?, Action<string, object[]>, ILoggingAdapter, CancellationToken)
    TestKitBase.InternalAwaitConditionAsync(Func<Task<bool>>, TimeSpan, TimeSpan?, Action<string, object[]>, ILoggingAdapter, CancellationToken)
    TestKitBase.ExpectMsg<T>(TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(T, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(T, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(Func<T, IActorRef, bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(Func<T, IActorRef, bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(Action<T, IActorRef>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(Action<T, IActorRef>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsg<T>(T, Func<T, T, bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgAsync<T>(T, Func<T, T, bool>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectTerminated(IActorRef, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectTerminatedAsync(IActorRef, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectNoMsg(CancellationToken)
    TestKitBase.ExpectNoMsgAsync(CancellationToken)
    TestKitBase.ExpectNoMsg(TimeSpan, CancellationToken)
    TestKitBase.ExpectNoMsgAsync(TimeSpan, CancellationToken)
    TestKitBase.ExpectNoMsg(int, CancellationToken)
    TestKitBase.ExpectNoMsgAsync(int, CancellationToken)
    TestKitBase.ExpectMsgAnyOf<T>(IEnumerable<T>, CancellationToken)
    TestKitBase.ExpectMsgAnyOfAsync<T>(IEnumerable<T>, CancellationToken)
    TestKitBase.ExpectMsgAllOf<T>(params T[])
    TestKitBase.ExpectMsgAllOf<T>(IReadOnlyCollection<T>, CancellationToken)
    TestKitBase.ExpectMsgAllOfAsync<T>(IReadOnlyCollection<T>, CancellationToken)
    TestKitBase.ExpectMsgAllOf<T>(TimeSpan, params T[])
    TestKitBase.ExpectMsgAllOf<T>(TimeSpan, IReadOnlyCollection<T>, CancellationToken)
    TestKitBase.ExpectMsgAllOfAsync<T>(TimeSpan, IReadOnlyCollection<T>, CancellationToken)
    TestKitBase.ExpectMsgAllOfMatchingPredicates(params PredicateInfo[])
    TestKitBase.ExpectMsgAllOfMatchingPredicates(IReadOnlyCollection<PredicateInfo>, CancellationToken)
    TestKitBase.ExpectMsgAllOfMatchingPredicatesAsync(IReadOnlyCollection<PredicateInfo>, CancellationToken)
    TestKitBase.ExpectMsgAllOfMatchingPredicates(TimeSpan, params PredicateInfo[])
    TestKitBase.ExpectMsgAllOfMatchingPredicates(TimeSpan, IReadOnlyCollection<PredicateInfo>, CancellationToken)
    TestKitBase.ExpectMsgAllOfMatchingPredicatesAsync(TimeSpan, IReadOnlyCollection<PredicateInfo>, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(IActorRef, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(IActorRef, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(IActorRef, T, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(IActorRef, T, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(IActorRef, Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(IActorRef, Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(Predicate<IActorRef>, Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(Predicate<IActorRef>, Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(IActorRef, Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(IActorRef, Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFrom<T>(Action<IActorRef>, Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.ExpectMsgFromAsync<T>(Action<IActorRef>, Action<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessage(Predicate<object>, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessageAsync(Predicate<object>, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessage<T>(Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessageAsync<T>(Predicate<T>, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessage<T>(Predicate<T>, ArrayList, TimeSpan?, string, CancellationToken)
    TestKitBase.FishForMessageAsync<T>(Predicate<T>, ArrayList, TimeSpan?, string, CancellationToken)
    TestKitBase.FishUntilMessageAsync<T>(TimeSpan?, CancellationToken)
    TestKitBase.WaitForRadioSilenceAsync(TimeSpan?, uint?, CancellationToken)
    TestKitBase.ReceiveOne(TimeSpan?, CancellationToken)
    TestKitBase.ReceiveOneAsync(TimeSpan?, CancellationToken)
    TestKitBase.TryReceiveOne(out MessageEnvelope, TimeSpan?, CancellationToken)
    TestKitBase.TryReceiveOneAsync(TimeSpan?, CancellationToken)
    TestKitBase.PeekOne(TimeSpan?, CancellationToken)
    TestKitBase.PeekOneAsync(TimeSpan?, CancellationToken)
    TestKitBase.PeekOne(CancellationToken)
    TestKitBase.PeekOneAsync(CancellationToken)
    TestKitBase.TryPeekOne(out MessageEnvelope, TimeSpan?, CancellationToken)
    TestKitBase.TryPeekOneAsync(TimeSpan?, CancellationToken)
    TestKitBase.ReceiveWhile<T>(TimeSpan?, Func<object, T>, int, CancellationToken)
    TestKitBase.ReceiveWhileAsync<T>(TimeSpan?, Func<object, T>, int, CancellationToken)
    TestKitBase.ReceiveWhile<T>(TimeSpan?, TimeSpan?, Func<object, T>, int, CancellationToken)
    TestKitBase.ReceiveWhileAsync<T>(TimeSpan?, TimeSpan?, Func<object, T>, int, CancellationToken)
    TestKitBase.ReceiveWhile<T>(Func<object, T>, TimeSpan?, TimeSpan?, int, CancellationToken)
    TestKitBase.ReceiveWhileAsync<T>(Func<object, T>, TimeSpan?, TimeSpan?, int, CancellationToken)
    TestKitBase.ReceiveWhile<T>(Predicate<T>, TimeSpan?, TimeSpan?, int, bool, CancellationToken)
    TestKitBase.ReceiveWhileAsync<T>(Predicate<T>, TimeSpan?, TimeSpan?, int, bool, CancellationToken)
    TestKitBase.ReceiveN(int, CancellationToken)
    TestKitBase.ReceiveNAsync(int, CancellationToken)
    TestKitBase.ReceiveN(int, TimeSpan, CancellationToken)
    TestKitBase.ReceiveNAsync(int, TimeSpan, CancellationToken)
    TestKitBase.Within(TimeSpan, Action, TimeSpan?, CancellationToken)
    TestKitBase.WithinAsync(TimeSpan, Func<Task>, TimeSpan?, CancellationToken)
    TestKitBase.Within(TimeSpan, TimeSpan, Action, string, TimeSpan?, CancellationToken)
    TestKitBase.WithinAsync(TimeSpan, TimeSpan, Func<Task>, string, TimeSpan?, CancellationToken)
    TestKitBase.Within<T>(TimeSpan, Func<T>, TimeSpan?, CancellationToken)
    TestKitBase.WithinAsync<T>(TimeSpan, Func<Task<T>>, TimeSpan?, CancellationToken)
    TestKitBase.Within<T>(TimeSpan, TimeSpan, Func<T>, string, TimeSpan?, CancellationToken)
    TestKitBase.WithinAsync<T>(TimeSpan, TimeSpan, Func<Task<T>>, string, TimeSpan?, CancellationToken)
    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.Xunit2.dll
    Syntax
    public class PersistenceTestKit : TestKit, IActorRefFactory, IDisposable

    Constructors

    | Edit this page View Source

    PersistenceTestKit(ActorSystem, ITestOutputHelper)

    Declaration
    public PersistenceTestKit(ActorSystem actorSystem, ITestOutputHelper output = null)
    Parameters
    Type Name Description
    ActorSystem actorSystem
    ITestOutputHelper output
    | Edit this page View Source

    PersistenceTestKit(ActorSystemSetup, string, ITestOutputHelper)

    Create a new instance of the PersistenceTestKit class. A new system with the specified configuration will be created.

    Declaration
    public PersistenceTestKit(ActorSystemSetup setup, string actorSystemName = null, ITestOutputHelper output = null)
    Parameters
    Type Name Description
    ActorSystemSetup setup

    Test ActorSystem configuration

    string actorSystemName

    Optional: The name of the actor system

    ITestOutputHelper output

    TBD

    | Edit this page View Source

    PersistenceTestKit(Config, string, ITestOutputHelper)

    Create a new instance of the PersistenceTestKit class. A new system with the specified configuration will be created.

    Declaration
    public PersistenceTestKit(Config config, string actorSystemName = null, ITestOutputHelper output = null)
    Parameters
    Type Name Description
    Config config

    Test ActorSystem configuration

    string actorSystemName

    Optional: The name of the actor system

    ITestOutputHelper output

    TBD

    | Edit this page View Source

    PersistenceTestKit(string, ITestOutputHelper)

    Create a new instance of the PersistenceTestKit class. A new system with the default configuration will be created.

    Declaration
    public PersistenceTestKit(string actorSystemName = null, ITestOutputHelper output = null)
    Parameters
    Type Name Description
    string actorSystemName

    Optional: The name of the actor system

    ITestOutputHelper output

    TBD

    Properties

    | Edit this page View Source

    Journal

    Declaration
    public ITestJournal Journal { get; }
    Property Value
    Type Description
    ITestJournal
    | Edit this page View Source

    JournalActorRef

    Actor reference to persistence Journal used by current actor system.

    Declaration
    public IActorRef JournalActorRef { get; }
    Property Value
    Type Description
    IActorRef
    | Edit this page View Source

    Snapshots

    Declaration
    public ITestSnapshotStore Snapshots { get; }
    Property Value
    Type Description
    ITestSnapshotStore
    | Edit this page View Source

    SnapshotsActorRef

    Actor reference to persistence Snapshot Store used by current actor system.

    Declaration
    public IActorRef SnapshotsActorRef { get; }
    Property Value
    Type Description
    IActorRef

    Methods

    | Edit this page View Source

    WithJournalRecovery(Func<JournalRecoveryBehavior, Task>, Action)

    Execute execution delegate with Journal Behavior applied to Recovery operation.

    Declaration
    public Task WithJournalRecovery(Func<JournalRecoveryBehavior, Task> behaviorSelector, Action execution)
    Parameters
    Type Name Description
    Func<JournalRecoveryBehavior, Task> behaviorSelector

    Delegate which will select Journal behavior.

    Action execution

    Delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Recovery behavior will be reverted back to normal.

    | Edit this page View Source

    WithJournalRecovery(Func<JournalRecoveryBehavior, Task>, Func<Task>)

    Execute execution delegate with Journal Behavior applied to Recovery operation.

    Declaration
    public Task WithJournalRecovery(Func<JournalRecoveryBehavior, Task> behaviorSelector, Func<Task> execution)
    Parameters
    Type Name Description
    Func<JournalRecoveryBehavior, Task> behaviorSelector

    Delegate which will select Journal behavior.

    Func<Task> execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Recovery behavior will be reverted back to normal.

    | Edit this page View Source

    WithJournalWrite(Func<JournalWriteBehavior, Task>, Action)

    Execute execution delegate with Journal Behavior applied to Write operation.

    Declaration
    public Task WithJournalWrite(Func<JournalWriteBehavior, Task> behaviorSelector, Action execution)
    Parameters
    Type Name Description
    Func<JournalWriteBehavior, Task> behaviorSelector

    Delegate which will select Journal behavior.

    Action execution

    Delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Write behavior will be reverted back to normal.

    | Edit this page View Source

    WithJournalWrite(Func<JournalWriteBehavior, Task>, Func<Task>)

    Execute execution delegate with Journal Behavior applied to Write operation.

    Declaration
    public Task WithJournalWrite(Func<JournalWriteBehavior, Task> behaviorSelector, Func<Task> execution)
    Parameters
    Type Name Description
    Func<JournalWriteBehavior, Task> behaviorSelector

    Delegate which will select Journal behavior.

    Func<Task> execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Write behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotDelete(Func<SnapshotStoreDeleteBehavior, Task>, Action)

    Execute execution delegate with Snapshot Store Behavior applied to Delete operation.

    Declaration
    public Task WithSnapshotDelete(Func<SnapshotStoreDeleteBehavior, Task> behaviorSelector, Action execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreDeleteBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Action execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Delete behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotDelete(Func<SnapshotStoreDeleteBehavior, Task>, Func<Task>)

    Execute execution delegate with Snapshot Store Behavior applied to Delete operation.

    Declaration
    public Task WithSnapshotDelete(Func<SnapshotStoreDeleteBehavior, Task> behaviorSelector, Func<Task> execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreDeleteBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Func<Task> execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Delete behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotLoad(Func<SnapshotStoreLoadBehavior, Task>, Action)

    Execute execution delegate with Snapshot Store Behavior applied to Load operation.

    Declaration
    public Task WithSnapshotLoad(Func<SnapshotStoreLoadBehavior, Task> behaviorSelector, Action execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreLoadBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Action execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Load behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotLoad(Func<SnapshotStoreLoadBehavior, Task>, Func<Task>)

    Execute execution delegate with Snapshot Store Behavior applied to Load operation.

    Declaration
    public Task WithSnapshotLoad(Func<SnapshotStoreLoadBehavior, Task> behaviorSelector, Func<Task> execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreLoadBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Func<Task> execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Load behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotSave(Func<SnapshotStoreSaveBehavior, Task>, Action)

    Execute execution delegate with Snapshot Store Behavior applied to Save operation.

    Declaration
    public Task WithSnapshotSave(Func<SnapshotStoreSaveBehavior, Task> behaviorSelector, Action execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreSaveBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Action execution

    Delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Save behavior will be reverted back to normal.

    | Edit this page View Source

    WithSnapshotSave(Func<SnapshotStoreSaveBehavior, Task>, Func<Task>)

    Execute execution delegate with Snapshot Store Behavior applied to Save operation.

    Declaration
    public Task WithSnapshotSave(Func<SnapshotStoreSaveBehavior, Task> behaviorSelector, Func<Task> execution)
    Parameters
    Type Name Description
    Func<SnapshotStoreSaveBehavior, Task> behaviorSelector

    Delegate which will select Snapshot Store behavior.

    Func<Task> execution

    Async delegate which will be executed with applied Journal behavior.

    Returns
    Type Description
    Task

    Task which must be awaited.

    Remarks

    After execution will be executed, Save behavior will be reverted back to normal.

    Implements

    IActorRefFactory
    IDisposable

    Extension Methods

    ActorRefFactoryExtensions.ActorOf<TActor>(IActorRefFactory, string)
    ActorRefFactoryExtensions.ActorSelection(IActorRefFactory, IActorRef, string)
    ActExtensions.ActorOf(IActorRefFactory, Action<IActorDsl, IActorContext>, string)
    ActExtensions.ActorOf(IActorRefFactory, Action<IActorDsl>, string)
    ActorMaterializerExtensions.Materializer(IActorRefFactory, ActorMaterializerSettings, string)
    ObjectExtensions.IsDefaultForType<T>(T)
    ObjectExtensions.AsOption<T>(T)
    TestPublisher.CreateManualPublisherProbe<T>(TestKitBase, bool)
    TestPublisher.CreatePublisherProbe<T>(TestKitBase, long)
    TestSink.SinkProbe<T>(TestKitBase)
    TestSource.SourceProbe<T>(TestKitBase)
    TestSubscriber.CreateManualSubscriberProbe<T>(TestKitBase)
    TestSubscriber.CreateSubscriberProbe<T>(TestKitBase)
    Utils.AssertAllStagesStopped(TestKitBase, Action, IMaterializer, TimeSpan?, CancellationToken)
    Utils.AssertAllStagesStoppedAsync(TestKitBase, Func<Task>, IMaterializer, TimeSpan?, CancellationToken)
    Utils.AssertAllStagesStoppedAsync<T>(TestKitBase, Func<Task<T>>, IMaterializer, TimeSpan?, CancellationToken)
    Utils.AssertAllStagesStopped<T>(TestKitBase, Func<T>, IMaterializer, TimeSpan?, CancellationToken)
    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