Feature flag service that delegates to a single FlagProvider.
Implements the synchronous IFeatureFlags contract; the provider owns a
cached snapshot and refreshes it out of band via its own async lifecycle.
FeatureFlagService(provider: FlagProvider)
isEnabled(flag: string,context?: FlagContext): boolean
Evaluates whether a flag is enabled.
isEnabledAsync(flag: string,context?: FlagContext): Promise<boolean>
Evaluates a flag, awaiting the provider when it can answer asynchronously.
Both entry points funnel through the SAME provider instance, so a
configured option — fallbackValue above all — governs identically whether
a caller reaches for the synchronous or the asynchronous method. A provider
with no async path resolves its synchronous evaluation, which for a purely
local snapshot is already the correct answer.
start(): Promise<void>
Starts the underlying provider (pulls initial state).
status(): FlagProviderStatus | undefined
Forwards the provider's optional health status.
stop(): Promise<void>
Stops the underlying provider (releases timers / connections).