Skip to content

feat(api): add core marker to SubGroup - #25

Draft
SiorMeir wants to merge 2 commits into
mainfrom
siormeir/core-subgroup
Draft

SiorMeir wants to merge 2 commits into
mainfrom
siormeir/core-subgroup

Conversation

@SiorMeir

Copy link
Copy Markdown
Contributor

Description

Adds an optional core marker to SubGroup (v2alpha2) so users choose which children of a SubGroupSet are part of a semi-preemptible PodGroup's core. Implements phase P1 of the HLD in kai-scheduler/KAI-Scheduler#2380.

  • New SubGroup.Core bool (json:"core,omitempty"), CRD regenerated.
  • PodGroup webhook rules (HLD "Validation"):
    • reject when core children under a parent exceed that parent's effective minSubGroup (unset = number of children; root uses the root minSubGroup);
    • reject adding, removing or moving core on update of a semi-preemptible PodGroup (not enforced when the update leaves semi-preemptible);
    • admission warning when core: true is set and preemptibility is not semi-preemptible (ignored; marks are not counted in that case);
    • redundant marks are accepted.
  • Table-driven tests incl. nested trees and update immutability.

No scheduler behavior change here; that is phase P2.

Related Issues

HLD: kai-scheduler/KAI-Scheduler#2380

Checklist

  • Self-reviewed
  • Added/updated tests (if needed)
  • Updated documentation (if needed)
  • Added a changelog fragment via make changelog (or applied the skip-changelog label). Do not edit CHANGELOG.md directly — pending fragments are folded into it at release time.

Breaking Changes

None. The field is optional and ignored when unset.

Additional Notes

make generate, make manifests, make validate, make build, go test ./... pass. make clients was not needed (no new types). Follow-up: a KAI-Scheduler PR repins to this commit until a tag is cut.

@SiorMeir SiorMeir added skip-changelog No changelog entry required and removed skip-changelog No changelog entry required labels Oct 13, 2026
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