feat(notification-outbox): add dispatcher loop to NotificationOutboxActor
This commit is contained in:
@@ -26,4 +26,30 @@ internal static class InternalMessages
|
||||
IActorRef Sender,
|
||||
bool Succeeded,
|
||||
string? Error);
|
||||
|
||||
/// <summary>
|
||||
/// Periodic tick that triggers a dispatch sweep. Started as a periodic timer in
|
||||
/// <c>PreStart</c> at the configured <c>DispatchInterval</c>. A singleton instance is
|
||||
/// reused so the timer carries no per-tick state.
|
||||
/// </summary>
|
||||
internal sealed class DispatchTick
|
||||
{
|
||||
/// <summary>The shared singleton tick instance scheduled by the dispatch timer.</summary>
|
||||
internal static readonly DispatchTick Instance = new();
|
||||
|
||||
private DispatchTick() { }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Completion signal for an asynchronous dispatch sweep, piped back to the actor so the
|
||||
/// in-flight guard is cleared on the actor thread. Sent on both success and failure of
|
||||
/// the sweep — the actor only needs to know the sweep has finished.
|
||||
/// </summary>
|
||||
internal sealed class DispatchComplete
|
||||
{
|
||||
/// <summary>The shared singleton completion instance.</summary>
|
||||
internal static readonly DispatchComplete Instance = new();
|
||||
|
||||
private DispatchComplete() { }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user