feat(notification-outbox): add NotificationOutboxActor ingest
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
using Akka.Actor;
|
||||
|
||||
namespace ScadaLink.NotificationOutbox.Messages;
|
||||
|
||||
/// <summary>
|
||||
/// Actor-internal message types for the <see cref="NotificationOutboxActor"/>. These are
|
||||
/// never sent across the network — they bridge the actor's async repository/delivery work
|
||||
/// back onto the actor's own mailbox so handlers run single-threaded on the actor.
|
||||
/// </summary>
|
||||
internal static class InternalMessages
|
||||
{
|
||||
/// <summary>
|
||||
/// Result of an asynchronous ingest persistence attempt, piped back to the actor.
|
||||
/// Carries the original <paramref name="Sender"/> so the actor can ack the site that
|
||||
/// submitted the notification once the insert completes.
|
||||
/// </summary>
|
||||
/// <param name="NotificationId">Id of the notification that was submitted.</param>
|
||||
/// <param name="Sender">Original submitter to receive the ack.</param>
|
||||
/// <param name="Succeeded">
|
||||
/// True if persistence completed without error — covers both a fresh insert and an
|
||||
/// already-existing row (idempotent re-submission). False only when the repository threw.
|
||||
/// </param>
|
||||
/// <param name="Error">Failure detail when <paramref name="Succeeded"/> is false; otherwise null.</param>
|
||||
internal sealed record IngestPersisted(
|
||||
string NotificationId,
|
||||
IActorRef Sender,
|
||||
bool Succeeded,
|
||||
string? Error);
|
||||
}
|
||||
Reference in New Issue
Block a user