fix(FN-703): fix overly broad usage limit pattern and add transient error retry

- Narrow 'insufficient' usage-limit regex to require quota/credit/balance/fund context
- Add transient error detection in executor and triage to retry instead of failing
- Improve scheduler pause/resume logging with actionable messages and resume confirmation
- Add SSE active connection counter for observability
- Add duplicate usage-limit pause suppression logging
This commit is contained in:
gsxdsm
2026-04-02 13:29:48 -07:00
parent 0518fdd977
commit 2acd2cfb17
5 changed files with 37 additions and 3 deletions

View File

@@ -331,21 +331,27 @@ export class Scheduler {
// Global pause (hard stop): halt all scheduling activity
if (settings.globalPause) {
if (!this.wasGlobalPaused) {
schedulerLog.log("Global pause active — scheduling halted");
schedulerLog.warn("Global pause active — scheduling halted. To resume: set globalPause to false in settings.");
this.wasGlobalPaused = true;
}
return;
}
if (this.wasGlobalPaused) {
schedulerLog.log("Global pause cleared — scheduling resumed");
}
this.wasGlobalPaused = false;
// Engine paused (soft pause): halt new work dispatch, but let agents finish
if (settings.enginePaused) {
if (!this.wasEnginePaused) {
schedulerLog.log("Engine paused — scheduling halted (in-flight agents continue)");
schedulerLog.warn("Engine paused — scheduling halted (in-flight agents continue). To resume: set enginePaused to false.");
this.wasEnginePaused = true;
}
return;
}
if (this.wasEnginePaused) {
schedulerLog.log("Engine pause cleared — scheduling resumed");
}
this.wasEnginePaused = false;
// Count only in-progress tasks toward the worktree limit.