Table of Contents

Method RecordAsync

Namespace
MailFathom.Application.Mail.Delivery.Governance
Assembly
MailFathom.Application.dll

RecordAsync(AuthoredSendPermit, AuthoredSendAct, OutgoingEmailRecord, CancellationToken)

Records that the send was asked for, once its record is durable.

public Task RecordAsync(AuthoredSendPermit permit, AuthoredSendAct act, OutgoingEmailRecord record, CancellationToken cancellationToken)

Parameters

permit AuthoredSendPermit

What RequirePermittedAsync(IReadOnlyList<AuthoredEmailRecipient>, OutgoingEmailRequest, CancellationToken) admitted the send as.

act AuthoredSendAct

What the caller asked for.

record OutgoingEmailRecord

The durable record the message was written down as.

cancellationToken CancellationToken

Cancels writing the audit record.

Returns

Task

A task that completes once the send is recorded.

Remarks

It follows the write because a record is what the audit is about: an owner reading it back asks what was sent and under whose grant, which is answerable only once the send has an identity. The caller was charged where it was admitted, so nothing here decides whether the period has room.

Exceptions

ArgumentNullException

Thrown when permit or record is null.