fix(binder): prevent duplicate reservation pods for a single gpu-group (#1693) [v0.12]#1702
Merged
Conversation
Contributor
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
enoodle
approved these changes
Jun 15, 2026
2f868d1 to
bac70d5
Compare
#1693) Signed-off-by: Guy Shaibi <gshaibi@gmail.com>
bac70d5 to
964e8b6
Compare
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.
Description
Backport of #1693 to the
v0.12release branch.At scale with fractional GPU workloads, multiple GPU reservation pods could be created for a single
runai-gpu-groupon a node, each reserving a different physical GPU. Since the scheduler tracks fractional-GPU capacity by gpu-group, a group spanning two devices corrupts accounting — affected GPUs appear full, fractional pods stay pending, and the state does not self-correct.Fix: reservation pods are named deterministically per
(node, gpu-group)(hashed) andAlreadyExistson create is treated as success (reuse the existing pod), so concurrent, retried, and multi-replica creates collide on a single API-server object instead of duplicating. Existing reservation pods (old random-suffix names) are unaffected — they are still resolved by gpu-group label, so no migration is needed.Related Issues
Fixes #1673
Checklist
Breaking Changes
None.
Additional Notes
Cherry-pick of
73298061from #1693 ontov0.12(manual adjustments limited to conflict resolution: dropping the unusedrandimport and placing the new test / changelog entry into this branch's layout). Verified locally onv0.12:go build,go vet,gofmt, and theresourcereservationpackage tests (including the new duplicate-gpu-group race test) pass.🤖 Generated with Claude Code