Confirmed provider unload remains deduplicated after model demand reload #52

Closed
opened 2026-10-20 08:26:15 +08:00 by Breadway · 2 comments
Owner

Found during RAM-30 extended single-mill investigation. Confidence: high for code mechanism, medium for desired retry semantics. Coordinator::execute checks journal.has_confirmed(ActionId::for_target(workload, kind)) before applying. A successful UnloadIdleModel remains confirmed indefinitely for the same workload generation; a later demand reload changes model state but not router workload identity and does not re-arm the action. Even the legacy breadmill (without queries_served) had no second unload in a 135s query window after an initial idle unload, so that result cannot establish serving protection. The contention benchmark starts with a fresh journal and did expose the busy-unload failure. Expected: define provider lifecycle re-arming using confirmed model residency transitions while retaining idempotency and protection from flapping. Do not simply delete duplicate guards. Test unload, demand reload, true idle grace/cooldown, then eligible second unload; also repeated ticks while still unloaded remain duplicates. Current benchmark workaround for protection experiments: restart only the disposable daemon with a fresh state directory after the initial efficacy/reload phase. This does not change product behavior or pretend the limitation is solved.

Found during RAM-30 extended single-mill investigation. Confidence: high for code mechanism, medium for desired retry semantics. Coordinator::execute checks journal.has_confirmed(ActionId::for_target(workload, kind)) before applying. A successful UnloadIdleModel remains confirmed indefinitely for the same workload generation; a later demand reload changes model state but not router workload identity and does not re-arm the action. Even the legacy breadmill (without queries_served) had no second unload in a 135s query window after an initial idle unload, so that result cannot establish serving protection. The contention benchmark starts with a fresh journal and did expose the busy-unload failure. Expected: define provider lifecycle re-arming using confirmed model residency transitions while retaining idempotency and protection from flapping. Do not simply delete duplicate guards. Test unload, demand reload, true idle grace/cooldown, then eligible second unload; also repeated ticks while still unloaded remain duplicates. Current benchmark workaround for protection experiments: restart only the disposable daemon with a fresh state directory after the initial efficacy/reload phase. This does not change product behavior or pretend the limitation is solved.
Author
Owner

Independent review of PR 53 exact head 37289b053f: pass. Review comment: #53 (comment)

Repeated ticks while unloaded or unknown stay duplicates. A later unload is allowed only for UnloadIdleModel when fresh breadsearch status proves a resident idle model through resolve(), which still enforces capability, socket owner, target generation, and the 30s idle grace. Planner cooldown is unchanged. Generic cgroup actions do not rearm. A denied retry does not clear has_confirmed.

Required check CPU checks / check (push) is success on this SHA. Independent ci/check.sh exited 0. Live two-unload evidence is external to this SHA and is not integrated verification. Coordinator verifies after merge. This card is not marked done.

Independent review of PR 53 exact head 37289b053fe680d2a8de702e5f707c01c7a040b6: pass. Review comment: https://git.breadway.dev/Breadway/breadram/pulls/53#issuecomment-5560 Repeated ticks while unloaded or unknown stay duplicates. A later unload is allowed only for UnloadIdleModel when fresh breadsearch status proves a resident idle model through resolve(), which still enforces capability, socket owner, target generation, and the 30s idle grace. Planner cooldown is unchanged. Generic cgroup actions do not rearm. A denied retry does not clear has_confirmed. Required check CPU checks / check (push) is success on this SHA. Independent ci/check.sh exited 0. Live two-unload evidence is external to this SHA and is not integrated verification. Coordinator verifies after merge. This card is not marked done.
Author
Owner

Merged as fast-forward 99eea2ba09, which is the reviewed head 37289b053f. Base at merge time was 4f4cc4d673 (RAM-78 stall sample clock in daemon.rs only). No overlap with this diff, so the reviewed head was merged without a new commit. Integrated verification is still the coordinator's; this card is not marked done.

Merged as fast-forward 99eea2ba099ae8f27dce180d1f202444f7f77dbc, which is the reviewed head 37289b053fe680d2a8de702e5f707c01c7a040b6. Base at merge time was 4f4cc4d673aff244b5701f681a9ed526e3f7819b (RAM-78 stall sample clock in daemon.rs only). No overlap with this diff, so the reviewed head was merged without a new commit. Integrated verification is still the coordinator's; this card is not marked done.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Breadway/breadram#52
No description provided.