Skip to content

NO-JIRA: Hypershift missing count storage classes metrics#716

Open
dfajmon wants to merge 1 commit into
openshift:mainfrom
dfajmon:hypershift-count-storageclasses
Open

NO-JIRA: Hypershift missing count storage classes metrics#716
dfajmon wants to merge 1 commit into
openshift:mainfrom
dfajmon:hypershift-count-storageclasses

Conversation

@dfajmon

@dfajmon dfajmon commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

I found out that operators in Hypershift don't count storage classes

Summary by CodeRabbit

  • New Features
    • Added storage-class metric collection during operator startup, improving monitoring and visibility into cluster storage configuration.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@dfajmon: This pull request explicitly references no jira issue.

Details

In response to this:

I found out that Hypershift doesn't count storage classes

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 openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jun 30, 2026
@coderabbitai

coderabbitai Bot commented Jun 30, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 300108c9-e94e-4d29-b744-f53bb9f14ed2

📥 Commits

Reviewing files that changed from the base of the PR and between 1715686 and 868183c.

📒 Files selected for processing (1)
  • pkg/operator/operator_starter.go

Walkthrough

In pkg/operator/operator_starter.go, a single call to metrics.CountStorageClasses(hsr.commonClients) is added inside HyperShiftStarter.StartOperator, immediately after the existing metrics.InitializeVACMismatchMetrics call.

Changes

HyperShift Storage Class Metrics

Layer / File(s) Summary
CountStorageClasses call in HyperShift startup
pkg/operator/operator_starter.go
Adds metrics.CountStorageClasses(hsr.commonClients) to the HyperShift operator startup sequence after InitializeVACMismatchMetrics.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 15
✅ Passed checks (15 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the added Hypershift storage-class metrics counting change.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Stable And Deterministic Test Names ✅ Passed The PR only adds a metrics call in pkg/operator/operator_starter.go; no test files or Ginkgo titles were modified.
Test Structure And Quality ✅ Passed No Ginkgo test files were changed; the PR only adds a startup metric call in operator_starter.go, so this test-quality check is not applicable.
Microshift Test Compatibility ✅ Passed Only pkg/operator/operator_starter.go changed; no Ginkgo tests or MicroShift-unsupported APIs were added.
Single Node Openshift (Sno) Test Compatibility ✅ Passed Only operator_starter.go changed to add CountStorageClasses; no It/Describe/Context/When additions or SNO-assuming tests found.
Topology-Aware Scheduling Compatibility ✅ Passed The PR only adds a storage-class metric call in HyperShift startup; it introduces no pod scheduling, affinity, replica, or node-selector changes.
Ote Binary Stdout Contract ✅ Passed No stdout writes were added; the new startup call only uses klog, which defaults to stderr, and the operator path initializes logs before StartOperator.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed PR only changes pkg/operator/operator_starter.go to add metrics.CountStorageClasses; no new Ginkgo e2e tests or IP/network assumptions were introduced.
No-Weak-Crypto ✅ Passed Change only adds metrics.CountStorageClasses in startup; inspected metrics/storageclass.go and found no weak-crypto algorithms or secret comparisons.
Container-Privileges ✅ Passed PR only adds a storage-class metrics call; no changed manifest or code sets privileged/hostPID/hostNetwork/hostIPC/SYS_ADMIN/root, and HyperShift deploy stays allowPrivilegeEscalation:false with ru...
No-Sensitive-Data-In-Logs ✅ Passed PASS: The only new call reuses an existing helper; no new logs or sensitive fields (secrets/tokens/PII/hostnames/customer data) were added.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@openshift-ci openshift-ci Bot requested review from mpatlasov and tsmetana June 30, 2026 18:02
@openshift-ci

openshift-ci Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dfajmon

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

@openshift-ci openshift-ci Bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 30, 2026
@openshift-ci

openshift-ci Bot commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

@dfajmon: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-csi 868183c link true /test e2e-aws-csi
ci/prow/hypershift-e2e-aks 868183c link false /test hypershift-e2e-aks
ci/prow/e2e-aws-ovn-upgrade 868183c link true /test e2e-aws-ovn-upgrade

Full PR test history. Your PR dashboard.

Details

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.

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. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants