Engine timings move to FLOW_* settings

NODE_STOP_TIMEOUT, REBUILD_WAIT, FLOW_REBUILD_WAIT, BACKOFF and
CANCEL_GRACE keep their defaults and are read from Settings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WgBfkm4rCmtd1T4vHWjEPx
This commit is contained in:
2026-10-15 09:50:18 +02:00
co-authored by Claude Opus 5.5
parent 2dc9295c26
commit 025123a219
5 changed files with 39 additions and 5 deletions
+3 -2
View File
@@ -26,11 +26,12 @@ from collections import deque
from collections.abc import Callable, Coroutine
from typing import Any
from fluksio.core.config import settings
from fluksio.flow.events import EventBus
logger = logging.getLogger(__name__)
BACKOFF = (1.0, 5.0, 30.0, 60.0)
BACKOFF = settings.FLOW_RESTART_BACKOFF
# A task that burns through this many restarts in the window is not going to
# recover by being restarted again *now*.
#
@@ -49,7 +50,7 @@ QUARANTINE_BACKOFF = (300.0, 900.0, 3600.0)
# this is not going to stop on its own — a client closing a socket the broker
# no longer answers on is the case seen in the wild — and the rebuild asking
# for it must not wait on that forever.
CANCEL_GRACE = 5.0
CANCEL_GRACE = settings.FLOW_CANCEL_GRACE
TaskFactory = Callable[[], Coroutine[Any, Any, None]]