Table of Contents

Method PerformAsync

Namespace
MailFathom.Application.Mail.Mutations
Assembly
MailFathom.Application.dll

PerformAsync(MailboxMutationRequest, MailFolderResolution, MailTransportSecurityPolicy, CancellationToken)

Writes the change down and carries it as far as it can get.

Task<MailboxMutationOutcome> PerformAsync(MailboxMutationRequest request, MailFolderResolution folder, MailTransportSecurityPolicy transportSecurityPolicy, CancellationToken cancellationToken)

Parameters

request MailboxMutationRequest

The change being asked for.

folder MailFolderResolution

The alias binding the occurrence belongs to, whose remote folder is selected for writing.

transportSecurityPolicy MailTransportSecurityPolicy

The connection and authentication policy the write session must obey.

cancellationToken CancellationToken

Cancels the durable writes, opening the session, and the mail server commands.

Returns

Task<MailboxMutationOutcome>

What this call did, and where the record of it can be read.

Remarks

A failure that leaves attempts remaining is raised, because the caller decides whether to ask again and when. A failure that spends the last attempt is recorded as terminal first and then raised, so the next call is answered from the record rather than opening a connection for a change nothing will make.

Exceptions

ArgumentNullException

Thrown when request, folder, or transportSecurityPolicy is null.

ArgumentException

Thrown when folder does not name the binding the request's occurrence belongs to.

MailboxUnavailableException

Thrown when the mail server did not serve the mutation within its configured resilience budget and attempts remain.

PersistenceConcurrencyConflictException

Thrown when the durable record could not be written because another writer changed it first.