Table of Contents

Method Create

Namespace
MailFathom.Application.Jobs
Assembly
MailFathom.Application.dll

Create(JobFailureClassification, string)

States what one failed attempt records against its job.

public static JobFailureRecord Create(JobFailureClassification classification, string reason)

Parameters

classification JobFailureClassification

Whether repeating the work could succeed.

reason string

The operator-safe name of what failed, free of mail content.

Returns

JobFailureRecord

The record the job's row keeps.

Remarks

A reason longer than the column allows is shortened rather than refused. It is composed here from a type name and a code, so the bound is unreachable in practice, and failing the one write whose purpose is to record a failure would leave the job held until its lease ran out with nothing said about why.

Exceptions

ArgumentException

Thrown when reason is blank.

ArgumentOutOfRangeException

Thrown when classification is not a defined member.