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

Function: completeKey()

completeKey<DB>(tx, key, outcome): Promise<void>

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

Records what a claimed mutation produced, in the same transaction as the mutation. Without it the commit is refused by the table's deferred trigger.

Type Parameters​

DB​

DB extends IdempotencyTables

Parameters​

tx​

Open<DB>

The same transaction passed to claimKey.

key​

string

The key that was claimed.

outcome​

IdempotencyOutcome

A response hash and an aggregate reference.

Returns​

Promise<void>

Throws​

invalid_input for a malformed hash or reference, or when no claimed row exists for this actor and key.