-
Notifications
You must be signed in to change notification settings - Fork 451
WIP: Implementation 5800 kep exclude resources #7424
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
WIP: Implementation 5800 kep exclude resources #7424
Conversation
Implement Phase 1 of KEP-5800: ClusterQueue-level Resource Exclusion This commit adds the API infrastructure for per-ClusterQueue resource exclusions that work in union with global configuration exclusions. Changes: - Add excludeResourcePrefixes field to ClusterQueueSpec in v1beta2 API - Add ClusterQueueExcludeResources feature gate (alpha, disabled by default) - Add validation for excludeResourcePrefixes field in webhook - Reject empty prefix strings - Warn about excluding critical resources (cpu, memory, GPUs) - Run code generation to update: - CRD manifests with new field and validators - DeepCopy, conversion, and applyconfiguration code - API reference documentation The excludeResourcePrefixes field is marked as optional with a maximum of 64 prefixes and uses set semantics (no duplicates). Related to kubernetes-sigs#5800 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
Implement Phase 2 of KEP-5800: Core resource exclusion functionality This commit implements the union behavior for resource exclusions, merging global configuration exclusions with ClusterQueue-specific excludeResourcePrefixes when creating workload Info objects. Changes to pkg/cache/queue/cluster_queue.go: - Add excludeResourcePrefixes field to ClusterQueue struct - Update ClusterQueue.Update() to store CQ-level exclusions from API - Add GetExcludeResourcePrefixes() method for safe access Changes to pkg/cache/queue/manager.go: - Add globalExcludedResourcePrefixes field to Manager struct - Update WithExcludedResourcePrefixes() to store global exclusions - Add workloadInfoOptionsWithCQExclusions() to merge exclusions - Add mergeExclusions() helper for deduplicating prefixes - Update AddOrUpdateWorkloadWithoutLock() to use merged exclusions - Update AddLocalQueue() workload creation to use merged exclusions - Update queueSecondPass() to use merged exclusions The implementation uses the union strategy: a resource is excluded if it matches EITHER the global OR the ClusterQueue-specific prefixes. The feature is gated by ClusterQueueExcludeResources feature gate. Related to kubernetes-sigs#5800 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: kannon92 The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
✅ Deploy Preview for kubernetes-sigs-kueue ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
@kannon92: The following tests failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
|
PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
What type of PR is this?
/kind feature
What this PR does / why we need it:
Allow admins to specify excluded resources at the cluster queue level rather than a global configuration
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?