Restore log-once guard for immediate mode deprecation warning

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2026-05-19 18:13:16 +02:00
parent ed2a9fe492
commit 4282877ba9
@@ -27,6 +27,8 @@ export type StitchingStrategy = {
stitchTimeout: HumanDuration;
};
let immediateDeprecationLogged = false;
export function stitchingStrategyFromConfig(
config: Config,
options?: { logger?: LoggerService },
@@ -35,7 +37,8 @@ export function stitchingStrategyFromConfig(
'catalog.stitchingStrategy.mode',
);
if (strategyMode === 'immediate') {
if (strategyMode === 'immediate' && !immediateDeprecationLogged) {
immediateDeprecationLogged = true;
options?.logger?.warn(
"The 'immediate' stitching strategy mode has been removed and is no longer supported. Falling back to deferred stitching. Please remove the 'catalog.stitchingStrategy.mode' configuration key.",
);