import { type ProjectContext, type RuntimeLeaseStateInspection, type RuntimeReadLease } from '@opensip-cli/core'; import { type SessionRetentionPolicy } from '../bootstrap/session-retention.js'; import { type RuntimePromotionStatusInspection } from './init/runtime-promotion-status.js'; import { type RuntimeStatusSizeLimits } from './runtime-status-filesystem.js'; import type { RuntimeCacheLocationProjection, RuntimeLeaseActivity, RuntimeStatusResult } from '@opensip-cli/contracts'; /** A status read is bounded even when the runtime contains hostile content. */ export declare const RUNTIME_STATUS_MAX_ENTRIES = 10000; export declare const RUNTIME_STATUS_MAX_BYTES: number; /** Status observes maintenance rather than waiting behind a long promotion. */ export declare const RUNTIME_STATUS_LEASE_WAIT_MS = 250; export type RuntimeStatusCoordinationRootPresence = 'absent' | 'present' | 'unsafe'; /** Injectable bounded coordination seams used by race-focused status tests. */ export interface RuntimeStatusCoordination { readonly rootPresence: () => RuntimeStatusCoordinationRootPresence; readonly inspect: (projectDir: string) => Promise; readonly inspectPromotion: (projectRoot: string, coordinationKey: string) => RuntimePromotionStatusInspection; readonly acquireRead: (projectDir: string) => Promise; } export interface ExecuteRuntimeStatusInput { readonly cwd: string; readonly cwdExplicit: boolean; /** Preserve the customer's exact `--config` authority across lease re-resolution. */ readonly explicitConfigPath?: string; /** Preserve bootstrap's explicit-config authority when it is available. */ readonly projectContext?: ProjectContext; /** Test seam for proving traversal caps without creating a huge fixture. */ readonly sizeLimits?: Partial; /** Test seam for deterministic coordination races and timeouts. */ readonly coordination?: Partial; } export interface RuntimeStatusContext { readonly project: ProjectContext; readonly coordinationKey: string; readonly limits: RuntimeStatusSizeLimits; readonly projectInitialized: boolean; readonly cacheIdentityStrength: RuntimeCacheLocationProjection['identityStrength']; readonly retention: SessionRetentionPolicy; } /** Resolve production coordination behavior with optional deterministic test seams. */ export declare function resolveStatusCoordination(override: Partial | undefined): RuntimeStatusCoordination; /** Resolve the project and bounded storage limits protected by a status read. */ export declare function buildRuntimeStatusContext(input: ExecuteRuntimeStatusInput, reuseBootstrapContext?: boolean): RuntimeStatusContext; /** Project a bounded busy response when storage cannot be inspected safely. */ export declare function busyStatus(context: RuntimeStatusContext, leaseActivity?: RuntimeLeaseActivity): RuntimeStatusResult; /** Project an explicit promotion-recovery response. */ export declare function recoveryStatus(context: RuntimeStatusContext, projection: Extract, leaseActivity: RuntimeLeaseActivity): RuntimeStatusResult; //# sourceMappingURL=runtime-status-context.d.ts.map