Class: SchedulerHealth
Defined in: server/bookings/scheduler-health.ts:176
Constructors
Constructor
new SchedulerHealth(repos: BookingRepositories, clock: ClockPort): SchedulerHealth;Defined in: server/bookings/scheduler-health.ts:177
Parameters
| Parameter | Type |
|---|---|
repos | BookingRepositories |
clock | ClockPort |
Returns
SchedulerHealth
Methods
staleBy()
staleBy(resourceId: string, opts: StaleByOptions): Promise<StaleByResult>;Defined in: server/bookings/scheduler-health.ts:263
Resource-scoped staleness: how far behind the required horizon is the availability materializer for a specific resource?
Returns the WORST (most-lagged) cursor across all active availability
series for the resource. When no series exist for the resource (no
availability configured), returns { stale: false, staleByMs: 0 } — the
absence of a series is not a "dead cron" signal; there is simply nothing
to materialize.
Parameters
| Parameter | Type |
|---|---|
resourceId | string |
opts | StaleByOptions |
Returns
Promise<StaleByResult>
staleness()
staleness(opts: StalenessOptions): Promise<StalenessReport>;Defined in: server/bookings/scheduler-health.ts:189
Assemble a full staleness report across all availability series, booking series, and lifecycle sweeper watermarks.
Calls opts.onAlert when any entry is stale; a throwing hook is caught
and silently dropped so it never prevents the report from being returned.
Parameters
| Parameter | Type |
|---|---|
opts | StalenessOptions |
Returns
Promise<StalenessReport>