Graphorin API reference v0.12.1
Graphorin API reference / @graphorin/store-sqlite / / SqliteIdempotencyStore
Class: SqliteIdempotencyStore
Defined in: packages/store-sqlite/src/idempotency-store.ts:49
Default IdempotencyStore implementation.
Stable
Implements
Constructors
Constructor
new SqliteIdempotencyStore(conn): SqliteIdempotencyStore;Defined in: packages/store-sqlite/src/idempotency-store.ts:51
Parameters
| Parameter | Type |
|---|---|
conn | SqliteConnection |
Returns
SqliteIdempotencyStore
Methods
delete()
delete(key): Promise<void>;Defined in: packages/store-sqlite/src/idempotency-store.ts:92
Parameters
| Parameter | Type |
|---|---|
key | string |
Returns
Promise<void>
Implementation of
get()
get(key): Promise<
| IdempotencyRecord
| null>;Defined in: packages/store-sqlite/src/idempotency-store.ts:73
Parameters
| Parameter | Type |
|---|---|
key | string |
Returns
Promise< | IdempotencyRecord | null>
Implementation of
prune()
prune(olderThan): Promise<number>;Defined in: packages/store-sqlite/src/idempotency-store.ts:96
Delete records whose expiry is older than the supplied epoch-ms instant. Production caller: the server's hourly scheduleIdempotencyPruning sweep (started by app-lifecycle), so expired rows no longer accumulate forever (W-065).
Parameters
| Parameter | Type |
|---|---|
olderThan | number |
Returns
Promise<number>
Implementation of
put()
put(record): Promise<void>;Defined in: packages/store-sqlite/src/idempotency-store.ts:55
Parameters
| Parameter | Type |
|---|---|
record | IdempotencyRecord |
Returns
Promise<void>