Skip to content

feat(enterprise): recover interrupted analysis runs#97

Draft
Gracker wants to merge 1 commit intofeature/enterprise-multi-tenant-lease-adminfrom
feature/enterprise-multi-tenant-run-recovery
Draft

feat(enterprise): recover interrupted analysis runs#97
Gracker wants to merge 1 commit intofeature/enterprise-multi-tenant-lease-adminfrom
feature/enterprise-multi-tenant-run-recovery

Conversation

@Gracker
Copy link
Copy Markdown
Owner

@Gracker Gracker commented May 8, 2026

Summary

  • Add startup recovery for enterprise analysis_runs: pending/running/awaiting_user rows left by a previous backend process are marked failed with backend_startup_recovery error metadata.
  • Invoke the recovery path during backend bootstrap only when enterprise mode is enabled.
  • Extend restart persistence tests so terminal runs stay completed while interrupted running runs become failed.

Scope notes

  • Advances README §11.11 / D9: backend restart now leaves analysis run state explicit instead of indefinitely running.
  • This does not close README §0.4.12; the full §11.11 checklist and final design-audit evidence are still incomplete.
  • README TODO state is unchanged.

Validation

  • cd backend && PATH="$HOME/.nvm/versions/node/v24.15.0/bin:$PATH" npx jest --runInBand --forceExit src/services/__tests__/analysisRunStore.test.ts src/routes/__tests__/enterpriseRestartPersistence.test.ts
  • cd backend && PATH="$HOME/.nvm/versions/node/v24.15.0/bin:$PATH" npm run typecheck
  • PATH="$HOME/.nvm/versions/node/v24.15.0/bin:$PATH" npm run verify:pr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant