Repository navigation
perf: harden memory usage and runtime performance - #87
Merged
Merged
Conversation
perf: stream and bound runtime history
fix: own the LSP process lifecycle
fix: bound subprocess output capture
fix: bound cache and persistent retention
fix: bound MCP payloads and pagination
fix: bound and sanitize hook traces
perf: bound and share semantic analysis
vinilana
marked this pull request as ready for review
July 12, 2026 19:38
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR consolidates the memory and performance remediation work for dotcontext.
Why
Several runtime paths could retain or materialize unbounded data, keep child processes alive, or rescan large repositories. Together these behaviors could cause memory exhaustion and degraded performance in long-running CLI, harness, MCP, and host-integration processes.
The remediation introduces explicit byte/count/retention budgets, bounded streaming, lifecycle cleanup, cache eviction, and regression coverage while preserving the repository's CLI → harness ← MCP/integrations boundaries.
Impact
Large repositories and long-running sessions now degrade through explicit partial results, pagination, rotation, eviction, and bounded diagnostics instead of unbounded allocation. Existing small-input behavior remains compatible.
Validation
npm run buildnpm test -- --runInBand --silentnpm run build:packagesnpm run smoke:packages(5 bundles)Integration status
PR #80 (shared semantic analysis) has had its conflicts resolved and is mergeable against
fix/performance-issues. It is not yet merged into the feature branch; once merged, this PR will update automatically.