Separate configuration monitoring from application updates #53

Merged
eleith merged 1 commits from refactor/config-monitor into main 2026-10-27 12:09:50 +00:00

Summary

  • Add a generic config monitor that owns polling, serialized/coalesced reads, startup reconciliation, and shutdown. It has no Directory application dependencies.
  • Let the application accept or reject candidates through a synchronous callback; only accepted changes advance the monitor's baseline.
  • Keep authentication policy and atomic snapshot publication in application.ts, with boot.ts responsible for wiring.
  • Move presentation helpers into server/directory/, configuration comparison into the config package, and error reporting into the web logger.
  • Detect same-sized edits that preserve modification time using ctime, with a real-filesystem process regression test.

Last-good state, restart-only authentication, stable request snapshots, safe diagnostics, and bookmark declaration order are preserved. The monitor does not support asynchronous acceptance callbacks or roll back arbitrary application side effects.

Validation

  • 989 unit/process tests: 509 config, 7 CLI, 473 web.
  • 122 Chromium browser tests, rerun before publishing.
  • Config, CLI, web, and bootstrap builds; TypeScript/Svelte checks; ESLint; Prettier; schema freshness; git diff checks.
  • Independent code and readability reviews completed, including the final helper relocations.

Manual follow-up

Docker and live OIDC were not exercised. In a Compose deployment, verify valid edits and atomic saves become visible after refresh, invalid YAML preserves the last-good page, and authentication changes require a restart.

## Summary - Add a generic config monitor that owns polling, serialized/coalesced reads, startup reconciliation, and shutdown. It has no Directory application dependencies. - Let the application accept or reject candidates through a synchronous callback; only accepted changes advance the monitor's baseline. - Keep authentication policy and atomic snapshot publication in application.ts, with boot.ts responsible for wiring. - Move presentation helpers into server/directory/, configuration comparison into the config package, and error reporting into the web logger. - Detect same-sized edits that preserve modification time using ctime, with a real-filesystem process regression test. Last-good state, restart-only authentication, stable request snapshots, safe diagnostics, and bookmark declaration order are preserved. The monitor does not support asynchronous acceptance callbacks or roll back arbitrary application side effects. ## Validation - 989 unit/process tests: 509 config, 7 CLI, 473 web. - 122 Chromium browser tests, rerun before publishing. - Config, CLI, web, and bootstrap builds; TypeScript/Svelte checks; ESLint; Prettier; schema freshness; git diff checks. - Independent code and readability reviews completed, including the final helper relocations. ## Manual follow-up Docker and live OIDC were not exercised. In a Compose deployment, verify valid edits and atomic saves become visible after refresh, invalid YAML preserves the last-good page, and authentication changes require a restart.
eleith-gitea-agent Bot added 1 commit 2026-10-27 12:06:18 +00:00
refactor: separate config monitoring from application updates
ci/woodpecker/pr/cli Pipeline was successful
ci/woodpecker/pr/config Pipeline was successful
ci/woodpecker/pr/web Pipeline was successful
ci/woodpecker/push/cli Pipeline was successful
ci/woodpecker/push/config Pipeline was successful
ci/woodpecker/push/web Pipeline was successful
3d919aa3cf
eleith merged commit 3d919aa3cf into main 2026-10-27 12:09:50 +00:00
eleith deleted branch refactor/config-monitor 2026-10-27 12:09:50 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: eleith/directory#53