Table of Contents

Method CancelAsync

Namespace
MailFathom.Application.Emails.Embeddings.Generations
Assembly
MailFathom.Application.dll

CancelAsync(CancellationToken)

Abandons the generation being built, if one is.

public Task<EmbeddingReindexCancellationOutcome> CancelAsync(CancellationToken cancellationToken)

Parameters

cancellationToken CancellationToken

Cancels the read and the transition.

Returns

Task<EmbeddingReindexCancellationOutcome>

Whether a reindex was abandoned.

Exceptions

EmbeddingVectorIndexFailedException

Thrown when the abandonment committed but the database refused to remove the generation's approximate index. The reindex is stopped either way; the index goes on occupying storage for a generation nothing reads until the removal of its vectors reaches the end and drops it.

PersistenceConcurrencyConflictException

Thrown when a competing writer wins a race the bounded retries could not resolve.

OperationCanceledException

Thrown when the caller cancels.