Skip to content

fix(podgrouper): skip WorkloadRunner wrapper when selecting the grouping plugin - #2070

Open
KaiPilotBot wants to merge 5 commits into
v0.17from
backport-2067-to-v0.17
Open

fix(podgrouper): skip WorkloadRunner wrapper when selecting the grouping plugin#2070
KaiPilotBot wants to merge 5 commits into
v0.17from
backport-2067-to-v0.17

Conversation

@KaiPilotBot

Copy link
Copy Markdown
Collaborator

Description

Backport of #2067 to v0.17.

…ing plugin

Wrapping a workload in a run.ai WorkloadRunner adds a level to the owner
chain (Pod -> ... -> DynamoGraphDeployment -> WorkloadRunner). Plugin
selection keys on the top owner's GVK, and WorkloadRunner had no entry,
so every wrapped workload fell through to the default grouper: a single
flat PodGroup with minMember 1 and group-wide topology constraints,
instead of the per-clique gangs the wrapped kind's plugin would build.

Register WorkloadRunner as a skip-top-owner kind, matching the legacy
run.ai wrappers.

That alone is not enough. skipTopOwnerGrouper resolved the next owner
through a raw exact-GVK map lookup, bypassing the hub's wildcard-version
fallback and the Karta fallback hub. The DGD is registered with a
wildcard version, so a WorkloadRunner -> DGD chain missed and dropped
back to the default grouper anyway. Resolve through the hub instead, so
a skipped owner picks the same plugin a top owner would.

Chained skips are now reachable, so guard the empty owner list that the
existing slice arithmetic would panic on.

Also add the missing RBAC for dynamographdeployments. Without it the
chain walk 403s at the DGD level and silently truncates, which happens
to still group correctly via PodCliqueSet but never propagates the DGD's
labels and annotations onto the PodGroup.

Signed-off-by: gshaibi <gshaibi@nvidia.com>
(cherry picked from commit ef66b09)
…osure

Both new branches were untested: the len(otherOwners) == 0 fallback in
skipTopOwnerGrouper and the closure that resolves a skipped owner through
the hub. The hub case exercises the real wiring end to end rather than a
stubbed resolver.

Signed-off-by: gshaibi <gshaibi@nvidia.com>
(cherry picked from commit 7409106)
The recursion always bottoms out at the pod, which resolves to the PodJob
grouper rather than back to this one, so the owner list is never exhausted
here. Carrying a branch for a state no caller can produce is noise.

Signed-off-by: gshaibi <gshaibi@nvidia.com>
(cherry picked from commit 3ea43fb)
Signed-off-by: gshaibi <gshaibi@nvidia.com>
(cherry picked from commit 9f16afd)
… filled

Signed-off-by: gshaibi <gshaibi@nvidia.com>
(cherry picked from commit 35b8090)
@coderabbitai

coderabbitai Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on this repository. 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: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 747f4d8f-6d70-4257-a002-456b2b830341

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

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.

❤️ Share

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

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.

2 participants