Skip to content

fix(v0.9.5): single-flight status polling, lock-free chunk count cache, and MajorUpgrade bump - #104

Merged
oyesanyf merged 1 commit into
mainfrom
pr/solo-quorumrag-20261125-153856
Nov 25, 2026
Merged

oyesanyf merged 1 commit into
mainfrom
pr/solo-quorumrag-20261125-153856

Conversation

@oyesanyf

Copy link
Copy Markdown
Owner

Summary

Fixes live WebUI Settings -> Cloud Drives hangs observed on busy 2M+ chunk nodes (2,289,988 chunks / 43,063 active indexer files) and bumps the package version from 0.9.4 to 0.9.5 so Windows Installer executes a guaranteed MajorUpgrade that stops and restarts QuorumRAGDaemon cleanly.

Root Causes Addressed

  1. Browser HTTP/1.1 Connection-Pool Starvation (crates/quorum-ui/assets/app.js):
    • app.js previously ran two competing unguarded setInterval(checkReindexStatus) timers (1 s and 2 s) with no in-flight deduplication and no timeout, plus an unguarded refreshCacheStats interval and an unbounded fetch('/api/cloud-drives').
    • Under heavy continuous indexing on 2M+ chunks, overlapping GET /api/reindex/status requests filled Chromium's 6-connection-per-origin HTTP/1.1 pool (25+ queued requests at status: 0), starving GET /api/cloud-drives and GET /api/fs/browse-folders and freezing Cloud Drives on "Loading cloud drive discovery status...".
  2. LanceDB Row-Count & Async-Worker Contention (vector_store.rs, engine.rs, reindex.rs, health.rs, cloud_drives.rs):
    • GET /api/reindex/status and GET /api/health executed full LanceDB table.count_rows(None).await on every poll tick, and health_handler ran HardwareTelemetry::probe() synchronously on the Tokio worker thread.
    • build_cloud_drives_status_response_with_context executed dir_exists_live synchronously inside an async loop on the Tokio worker pool and waited without timeout on SQLite list_catalog_file_identities() during active indexer writes.
  3. Same-Version MSI Maintenance No-Op (0.9.4 -> 0.9.5):
    • Re-installing an updated 0.9.4 MSI over an already-installed 0.9.4 service skipped replacing and restarting QuorumRAGDaemon. Bumping all cross-OS packaging manifests to 0.9.5 triggers a guaranteed WiX MajorUpgrade.

Changes

  • Lock-Free / Bounded Row Count Cache: Added AtomicUsize cached row count + count_fast() (instant within 5 s, 200 ms bounded LanceDB refresh fallback) in VectorStore & StorageEngine, updated on open, insert, delete, and count; wired into /api/reindex/status and /api/health (plus spawn_blocking for HardwareTelemetry::probe()).
  • Non-Blocking Cloud Drives Status: Offloaded deduplicated dir_exists_live checks into a single tokio::task::spawn_blocking pass and bounded list_catalog_file_identities() to 2 s in build_cloud_drives_status_response_with_context.
  • Single-Flight Guarded UI Polling & Instant Settings Tab Switching: Unified checkReindexStatus onto one adaptive guarded timer (2 s active / 6 s idle, reindexStatusInFlight, 5 s timeout), guarded refreshCacheStats (cacheStatsInFlight, 5 s timeout), bounded fetchCloudDrivesData to 15 s with clear Retry fallback, painted selected Settings tabs immediately on click, and bumped asset cache-busters to ?v=20261125a.
  • Cross-OS Version Bump (0.9.4 -> 0.9.5): Synced Cargo.toml, wix/QuorumRAG.wxs, scripts/package.ps1, packaging/linux/build_packages.sh, and packaging/macos/build_packages.sh.
  • Regression Tests: Added count_fast_tracks_inserts_and_deletes_without_blocking (quorum-storage) and test_single_flight_status_polling_and_bounded_cloud_drives_fetch (quorum-ui).

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[PASS] QuorumRAG Solo-Developer Invariant Gate & Review Bot: Verified repository owner (@oyesanyf, OWNER), commit bf7751a (14 file(s)), Zero-Touch PATH compliance, zero private keys, and hermetic build scripts.

@oyesanyf
oyesanyf merged commit cc44a7d into main Nov 25, 2026
6 checks passed
@oyesanyf
oyesanyf deleted the pr/solo-quorumrag-20261125-153856 branch November 25, 2026 21:47
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