perf(storage): eliminate swarm ledger full-scan hot path - #2040
Merged
Conversation
likun666661
force-pushed
the
fix/swarm-ledger-hot-path
branch
from
August 4, 2026 02:27
957b64f to
5567fde
Compare
likun666661
marked this pull request as ready for review
August 4, 2026 02:27
sunheyi6
added a commit
to sunheyi6/maka-agent
that referenced
this pull request
Aug 4, 2026
) conflicts - sandbox-boundary-path: adopt main realpath-space model (no followFinalSymlink) - builtin-tools ApplyPatch adapter: writes follow the canonical target (apache#2059), lstat/delete keep directory-entry semantics via realpathAllowMissing parents - filesystem worker client: entry-mode normalizer for delete/lstat/create; writable roots back to main narrow dirname form - operations: worker write resolves through followed path; delete/lstat operands stay entry-scoped with containment - storage: drop FileSessionStore per main apache#2040; restore editingProtocol persistence in buildSessionHeader + normalizeSessionHeader - tests: merge symlink suites (replace-mode now follow-final), keep PR lstat/ delete entry tests, add editingProtocol persistence regression
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
Performance
Measured against a copy of a real workspace database with 28,619 runtime events and 77.47 MB of payload JSON:
A real 32-way deepseek-flash-reader swarm spawned all 32 children. During the active swarm, renderer CDP latency was 28 ms median, 124 ms p95, and 166 ms max; the previous build reached 15.8 seconds. Main-process profiling no longer showed decodeStoredRuntimeEvent, scanToolLedger, or assertToolLedgerTransition as hotspots.
Validation