Skip to main content
Version: Current

StreamPosition

@rotorsoft/act-root


@rotorsoft/act-root / act/src / StreamPosition

Type Alias: StreamPosition

StreamPosition = object

Defined in: libs/act/src/types/ports.ts:192

Subscription position for a registered stream.

Streamed by Store.query_streams to power operational dashboards (projection lag, blocked subscriptions, in-flight leases). The shape mirrors what every adapter already tracks on its streams table.

Properties​

at​

readonly at: number

Defined in: libs/act/src/types/ports.ts:195

Last processed event id watermark (-1 for fresh streams)


blocked​

readonly blocked: boolean

Defined in: libs/act/src/types/ports.ts:197

True when the stream is blocked by a poison message


correlated_at?​

readonly optional correlated_at?: number

Defined in: libs/act/src/types/ports.ts:211

The stream's work mark — see SubscribeInput.correlated_at. at < correlated_at is the same predicate Store.claim applies, so a reader can tell "behind the head" (at lags an event id) from "has unconsumed work" without probing the event log. undefined means the row carries no mark yet: unknown, not "no work".


deferred_at?​

readonly optional deferred_at?: number

Defined in: libs/act/src/types/ports.ts:203

Persisted next-visit time (ms since epoch) when the stream is held out of claim by a defer outcome; omitted when the stream carries no active defer schedule. Read at cold start to re-seed the in-process defer timer so an idle deferred stream re-arms its drain across a restart — the schedule outlives the process memory it was derived from.


error​

readonly error: string

Defined in: libs/act/src/types/ports.ts:198

Last error message (empty string when none)


lane?​

readonly optional lane?: string

Defined in: libs/act/src/types/ports.ts:202

Drain lane bound to the stream


leased_by?​

readonly optional leased_by?: string

Defined in: libs/act/src/types/ports.ts:200

Current lease holder UUID (when leased)


leased_until?​

readonly optional leased_until?: Date

Defined in: libs/act/src/types/ports.ts:201

Lease expiration timestamp (when leased)


priority​

readonly priority: number

Defined in: libs/act/src/types/ports.ts:199

Scheduling priority (default 0). Biases the lagging-frontier claim() ordering — see Store.prioritize.


retry​

readonly retry: number

Defined in: libs/act/src/types/ports.ts:196

Current retry counter


source?​

readonly optional source?: string

Defined in: libs/act/src/types/ports.ts:194

Optional source (literal name or regex pattern) the reaction consumes from


stream​

readonly stream: string

Defined in: libs/act/src/types/ports.ts:193

The subscription target (projection or reaction stream)