Skip to content

perf: optimize scan prepare memory and staleness checks#2

Closed
munsunouk wants to merge 2 commits into
codex/fix-codex-owned-reviewfrom
perf/scan-prepare-staleness
Closed

perf: optimize scan prepare memory and staleness checks#2
munsunouk wants to merge 2 commits into
codex/fix-codex-owned-reviewfrom
perf/scan-prepare-staleness

Conversation

@munsunouk

Copy link
Copy Markdown
Owner

Summary

  • Reduce scan prepare peak memory by reading each file once, releasing batch item content after bundle build, and streaming manifest JSON to output files.
  • Verify scan bundle staleness with streaming on-disk hashes instead of loading full file content during validate and context readiness checks.

Dependency

Stacked on codex/fix-codex-owned-review (host-agent PR). Retarget to main after the host-agent branch lands.

Test plan

  • go test ./internal/reviewbundle/... ./internal/scan/... ./cmd/opencodereview/...
  • Compare scan prepare memory on a large repo before/after
  • Confirm stale scan bundle still reports stale_bundle after file mutation

Made with Cursor

munsunouk added 2 commits July 3, 2026 21:01
Read each scan file once, release batch item content after bundle build,
and stream manifest JSON directly to output files.
Verify scan bundle freshness by hashing on-disk files without loading
full content during validate and context readiness checks.
@munsunouk

Copy link
Copy Markdown
Owner Author

Reverted split: perf commits merged back into codex/fix-codex-owned-review for PR alibaba#276.

@munsunouk munsunouk closed this Jul 3, 2026
@munsunouk munsunouk deleted the perf/scan-prepare-staleness branch July 3, 2026 19:15
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