add stand alone pod annotation check in pod webhook #4109
+4
−1
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.
What type of PR is this?
/kind feature
This PR adds a check for a "kueue.x-k8s.io/standalone" annotation on plain pods. If this annotation exists, then these pods will be suspended even if their ownerReference is a known integration to Kueue.
Only a draft for now.
What this PR does / why we need it:
At a high level, this would give users more flexibility to process plain pods with Kueue. Currently, users are blocked from allowing Kueue to process any pods that are owned by a known integration to Kueue.
For example, in Spark Apps, the Driver Pod is the Owner of the Executor pods. This prevents the Executor pods from being processed by Kueue at all, because the pod_webhook sees that they are owned by a resource of "Kind: Pod". With this annotation, users would be able to process these executors as plain pods. See the linked issue for more details.
Which issue(s) this PR fixes:
Fixes # #4106
Special notes for your reviewer:
Does this PR introduce a user-facing change?