Skip to content

Automated cherry pick of #14419: Record the pod scheduling gate removal metric with its ClusterQueue custom labels - #15391

Merged
kubernetes-prow[bot] merged 2 commits into
kubernetes-sigs:release-0.19from
mimowo:automated-cherry-pick-of-#14419-release-0.19
Sep 10, 2026
Merged

kubernetes-prow[bot] merged 2 commits into
kubernetes-sigs:release-0.19from
mimowo:automated-cherry-pick-of-#14419-release-0.19

Conversation

@mimowo

@mimowo mimowo commented Sep 10, 2026

Copy link
Copy Markdown
Contributor

Cherry pick of #14419 on release-0.19.

#14419: Record the pod scheduling gate removal metric with its ClusterQueue custom labels

For details on the cherry pick process, see the cherry pick requests page.

What type of PR is this?

/kind bug

Observability: Fixed a panic that could crash the manager when `CustomMetricLabels` is enabled with a ClusterQueue-sourced label and a Pod's Kueue scheduling gate is removed.

…ustom labels

The metric is registered with the ClusterQueue custom-label set, but RecordPodSchedulingGateRemovalSeconds passed only the fixed name, cluster_queue, is_group and replica_role values. With CustomMetricLabels enabled and a ClusterQueue-sourced label configured, WithLabelValues then received fewer values than the metric's label count and panicked, crashing the manager whenever a Pod's Kueue scheduling gate was removed. Thread the ClusterQueue's custom label values through to the record call, the way the other custom-labelled metrics already do, so the recorded and registered label sets agree.

Signed-off-by: thc1006 <84045975+thc1006@users.noreply.github.com>
@kubernetes-prow kubernetes-prow Bot added this to the v0.19 milestone Sep 10, 2026
@kubernetes-prow kubernetes-prow Bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/bug Categorizes issue or PR as related to a bug. labels Sep 10, 2026
@netlify

netlify Bot commented Sep 10, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for kubernetes-sigs-kueue canceled.

Name Link
🔨 Latest commit 8b51034
🔍 Latest deploy log https://app.netlify.com/projects/kubernetes-sigs-kueue/deploys/6aa26249ac9b310008b0fa01

@coderabbitai

coderabbitai Bot commented Sep 10, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

🗂️ Base branches to auto review (1)
  • main

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: Advanced

Run ID: 65c7214c-9f2c-44eb-adcc-6df6bc9f5a17

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

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

@kubernetes-prow kubernetes-prow Bot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. approved Indicates a PR has been approved by an approver from all required OWNERS files. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Sep 10, 2026

func (r *Reconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) {
return r.ReconcileGenericJob(ctx, req, NewPod(WithExcessPodExpectations(r.expectationsStore), WithClock(r.clock), WithRoleTracker(r.RoleTracker())))
return r.ReconcileGenericJob(ctx, req, NewPod(

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had conflic here due to reformattng

kueue "sigs.k8s.io/kueue/apis/kueue/v1beta2"
"sigs.k8s.io/kueue/pkg/constants"
"sigs.k8s.io/kueue/pkg/controller/core"
"sigs.k8s.io/kueue/pkg/metrics"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

conflict here due to imports changed between 0.18 and main

@mimowo

mimowo commented Sep 10, 2026 •

Copy link
Copy Markdown
Contributor Author

Some more fixes to align the PR to 0.19: 8b51034

@mimowo
mimowo force-pushed the automated-cherry-pick-of-#14419-release-0.19 branch from 235aeff to 8b51034 Compare September 10, 2026 07:54
@Singularity23x0

Copy link
Copy Markdown
Contributor

Thank you
/lgtm
/approve

@kubernetes-prow kubernetes-prow Bot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 10, 2026
@kubernetes-prow

Copy link
Copy Markdown

LGTM label has been added.

DetailsGit tree hash: f8e3442a2603a25e410bbc02083ce1f70ddf215e

@kubernetes-prow

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mimowo, Singularity23x0

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubernetes-prow
kubernetes-prow Bot merged commit 896766d into kubernetes-sigs:release-0.19 Sep 10, 2026
61 checks passed
@mimowo
mimowo deleted the automated-cherry-pick-of-#14419-release-0.19 branch October 4, 2026 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants