انتقل إلى المحتوى الرئيسي

Type Alias: IdempotencyClaim

IdempotencyClaim = { outcome: "new"; } | { aggregate: AggregateRef | undefined; outcome: "replay"; responseHash: string; } | { outcome: "conflict"; }

Defined in: packages/persistence/src/idempotency.ts:67

The result of claimKey.

Union Members​

Type Literal​

{ outcome: "new"; }

First sight: run the mutation, then call completeKey, in this transaction.


Type Literal​

{ aggregate: AggregateRef | undefined; outcome: "replay"; responseHash: string; }

Already done: re-read the aggregate and answer; do not run the mutation.


Type Literal​

{ outcome: "conflict"; }

The key was used for a different request or contract. Refuse; do not run.