agent-ecosystem/test/main/services/infrastructure
777genius aa9a1bba8c perf: debounce team watcher rebuilds during dir-event bursts
A team launch creates many directories/files in quick succession (worktrees,
inboxes, session logs), and each addDir/unlinkDir event triggered a full
TeamTaskWatchRegistry reconcile that tore down and recreated the entire chokidar
watcher (re-opening a kqueue fd per watched file on macOS). Profiling a 6-member
mixed-team launch showed kqueue churn (kevent) as a top native cost and watcher
rebuild as the top remaining main-thread JS cost after the transcript fix.

Debounce the event-driven reconcile (250ms) so a burst collapses into one rebuild.
collectTargets re-reads the current directory state and emitExistingFilesForNewTargets
backfills files created before the rebuild, so no change is missed; requestReconcile,
startup, and the periodic 30s reconcile stay immediate. Adds a test asserting a
burst of addDir events yields a single rebuild.
2026-05-30 09:46:16 +03:00
..
CliInstallerService.healthCheck.test.ts chore(release): lock runtime 0.0.37 2026-05-18 22:28:24 +03:00
CliInstallerService.test.ts perf(startup): avoid provider refresh version probe 2026-05-25 23:37:12 +03:00
ConfigManager.claudeRoot.test.ts feat(team): expand opencode review and release support 2026-04-24 12:05:54 +03:00
ConfigManager.codexMigration.test.ts feat(runtime): support anthropic compatible endpoints 2026-05-22 00:16:52 +03:00
ConfigManager.notifications.test.ts feat(team): expand opencode review and release support 2026-04-24 12:05:54 +03:00
CrossPlatformFileChangeSource.test.ts perf(startup): defer heavy startup work 2026-05-25 23:14:59 +03:00
FileWatcher.test.ts perf(startup): defer heavy startup work 2026-05-25 23:14:59 +03:00
LocalFileSystemProvider.test.ts chore: commit remaining workspace updates 2026-05-21 16:43:00 +03:00
NotificationManager.migration.test.ts fix(notifications): recover corrupted history writes 2026-04-24 12:24:21 +03:00
NotificationManager.team.test.ts fix(ci): handle windows-only test behavior 2026-05-04 09:37:58 +03:00
OpenCodeRuntimeInstallerService.test.ts fix(startup): ignore stale opencode probe results 2026-05-26 10:39:50 +03:00
TeamTaskWatchRegistry.test.ts perf: debounce team watcher rebuilds during dir-event bursts 2026-05-30 09:46:16 +03:00
teamWatchScope.test.ts perf: scope team file watching to active and engaged teams 2026-05-30 00:25:55 +03:00
updaterReleaseMetadata.test.ts fix: harden provider management and updater flows 2026-05-16 23:23:27 +03:00