Skip to content

fix(git-cli-proxy): bound concurrent page serves so blob-heavy windows cannot stack past the memory limit - #3033

Merged
aleksdotbar merged 1 commit into
release-2026.08from
fix/proxy-serve-concurrency-2026.08
Sep 2, 2026
Merged

fix(git-cli-proxy): bound concurrent page serves so blob-heavy windows cannot stack past the memory limit#3033
aleksdotbar merged 1 commit into
release-2026.08from
fix/proxy-serve-concurrency-2026.08

Conversation

@aleksdotbar

Copy link
Copy Markdown
Contributor

Cherry-pick of #3032 into release-2026.08.

Why. Nothing bounds how many page serves run at once: heavyOpsConcurrency caps clones/fetches/repacks, but each serve spawns git children whose memory scales with the window's blob bytes, so enough concurrent blob-heavy windows OOM-kill the pod — and now that long preparations are held instead of bounced, heavy serves actually run long enough to stack.

What changed. A serve_concurrency semaphore (config-required like its heavy sibling; chart value cache.serveConcurrency, default 4) gates the serve phase of every data endpoint at the shared read_snapshot choke point. The permit is taken after open() so a slot is never spent waiting on a preparation, and excess requests wait in-connection; a wait that outlives the preparation ceiling answers a typed 429 with its own quota subject and rejection metric.

Verified. Clean cherry-pick. cargo test -p git-cli-proxy on this branch (215 lib + 20 boot), helm contract suite (27).

…s cannot stack past the memory limit

Signed-off-by: Aleksandr Barkhatov <pm@aleks.bar>
@aleksdotbar
aleksdotbar requested a review from a team as a code owner September 2, 2026 03:44
@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: 180d54aa-49fb-450c-862c-3e13e6277901

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Comment @coderabbitai help to get the list of available commands.

@aleksdotbar
aleksdotbar merged commit f5a32d1 into release-2026.08 Sep 2, 2026
21 checks passed
@aleksdotbar
aleksdotbar deleted the fix/proxy-serve-concurrency-2026.08 branch September 2, 2026 03:45
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