Skip to main content

ActLifecycleEvents

@rotorsoft/act-root


@rotorsoft/act-root / act/src / ActLifecycleEvents

Type Alias: ActLifecycleEvents<TSchemaReg, TEvents, TActions>

ActLifecycleEvents<TSchemaReg, TEvents, TActions> = object

Defined in: libs/act/src/act.ts:127

Lifecycle events emitted by Act, mapped to their payload type. Drives the typing of emit / on / off โ€” the event-name argument narrows its payload at the call site.

Type Parametersโ€‹

TSchemaRegโ€‹

TSchemaReg extends SchemaRegister<TActions>

TEventsโ€‹

TEvents extends Schemas

TActionsโ€‹

TActions extends Schemas

Propertiesโ€‹

ackedโ€‹

acked: Lease[]

Defined in: libs/act/src/act.ts:133


blockedโ€‹

blocked: BlockedLease[]

Defined in: libs/act/src/act.ts:134


closedโ€‹

closed: CloseResult

Defined in: libs/act/src/act.ts:136


committedโ€‹

committed: Snapshot<TSchemaReg, TEvents>[]

Defined in: libs/act/src/act.ts:132


forgottenโ€‹

forgotten: object

Defined in: libs/act/src/act.ts:162

A stream's sensitive-data payload was wiped via Act.forget. Fires exactly once per successful forget(stream) call โ€” idempotent second calls (no PII left on the stream) return eventCount: 0 and do NOT re-emit. Apps that never call forget() never see this event.

Listeners use it for the compliance side of GDPR / CCPA: audit log, downstream cache busts, projection-side wipes that the framework doesn't reach (e.g., search indexes, ETL caches). The framework's own cache is invalidated by forget() itself before the event fires.

atโ€‹

at: Date

eventCountโ€‹

eventCount: number

streamโ€‹

stream: string


notifiedโ€‹

notified: StoreNotification

Defined in: libs/act/src/act.ts:150

A different process committed an event to the same backing store.

Fires only when the configured store implements Store.notify and there is at least one registered reaction. The orchestrator uses the same signal internally to wake settle() โ€” listeners get the raw payload for SSE fan-out, dashboards, and audit logs.

Local commits do not fire notified (use committed for those): stores self-filter their own writes so this channel has a clean cross-process semantic.


settledโ€‹

settled: Drain<TEvents>

Defined in: libs/act/src/act.ts:135