Skip to content

InMemoryOffsetStore

Defined in: src/persistence/projection/OffsetStore.ts:38

Reference offset store — keeps cursors in a process-local Map. Use this for tests or for projections whose offsets you’re happy to lose on restart (i.e. the projection always replays the full stream). Not thread-safe across processes.

new InMemoryOffsetStore(): InMemoryOffsetStore

InMemoryOffsetStore

clear(projection): Promise<void>

Defined in: src/persistence/projection/OffsetStore.ts:60

Forget every cursor for projectionName. Used by tests + reset tooling.

string

Promise<void>

OffsetStore.clear


loadOffset(projection, tag): Promise<Offset>

Defined in: src/persistence/projection/OffsetStore.ts:51

string

string

Promise<Offset>

OffsetStore.loadOffset


loadSequence(projection, pid): Promise<number>

Defined in: src/persistence/projection/OffsetStore.ts:42

string

string

Promise<number>

OffsetStore.loadSequence


saveOffset(projection, tag, offset): Promise<void>

Defined in: src/persistence/projection/OffsetStore.ts:54

string

string

Offset

Promise<void>

OffsetStore.saveOffset


saveSequence(projection, pid, seqNr): Promise<void>

Defined in: src/persistence/projection/OffsetStore.ts:45

string

string

number

Promise<void>

OffsetStore.saveSequence