OCPBUGS-78310: fix(cli): initialize controller-runtime logger in product-cli - #8955
Conversation
|
Pipeline controller notification For optional jobs, comment This repository is configured in: LGTM mode |
|
@hypershift-jira-solve-ci[bot]: This pull request references Jira Issue OCPBUGS-78310, which is invalid:
Comment The bug has been updated to refer to the pull request using the external bug tracker. DetailsIn response to this:
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. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Central YAML (inherited) Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthrough
🚥 Pre-merge checks | ✅ 11✅ Passed checks (11 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
/jira refresh |
|
@bryan-cox: This pull request references Jira Issue OCPBUGS-78310, which is valid. The bug has been moved to the POST state. 3 validation(s) were run on this bug
No GitHub users were found matching the public email listed for the QA contact in Jira (wewang@redhat.com), skipping review request. DetailsIn response to this:
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. |
|
/area cli |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #8955 +/- ##
==========================================
+ Coverage 43.28% 43.46% +0.18%
==========================================
Files 771 771
Lines 95506 95726 +220
==========================================
+ Hits 41335 41603 +268
+ Misses 51287 51236 -51
- Partials 2884 2887 +3
... and 13 files with indirect coverage changes
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
Codecov/patch is failing. You need to add unit tests. |
|
/test address-review-comments |
|
Review agent triggered. View job |
The hcp CLI (product-cli) never called ctrl.SetLogger() before using controller-runtime's client.New() via cmd/util.GetClient(). This caused a noisy "[controller-runtime] log.SetLogger(...) was never called" warning with a full goroutine stack trace on every hcp create cluster invocation, degrading the customer experience. Add the same ctrl.SetLogger(zap.New(zap.JSONEncoder(...))) call used by every other binary in the repo to product-cli/main.go, early in main() before any cobra command execution. Signed-off-by: OpenShift CI Bot <ci-bot@redhat.com> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
e2efcd9 to
9fa3dee
Compare
|
@hypershift-jira-solve-ci[bot]: This pull request references Jira Issue OCPBUGS-78310, which is valid. 3 validation(s) were run on this bug
No GitHub users were found matching the public email listed for the QA contact in Jira (wewang@redhat.com), skipping review request. DetailsIn response to this:
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. |
|
Scheduling tests matching the |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bryan-cox, hypershift-jira-solve-ci[bot] The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Test Resultse2e-aws
e2e-aks
|
AI Test Failure AnalysisJob: Generated by hypershift-analyze-e2e-failure post-step using Claude claude-opus-4-6 |
|
/retest |
AI Test Failure AnalysisJob: Generated by hypershift-analyze-e2e-failure post-step using Claude claude-opus-4-6 |
AI Test Failure AnalysisJob: Generated by hypershift-analyze-e2e-failure post-step using Claude claude-opus-4-6 |
|
/retest |
|
The PR only touches Now I have all the evidence needed. Here is the final report: Test Failure Analysis CompleteJob Information
Test Failure AnalysisErrorSummaryThe Root CauseThe root cause is a transient GitHub raw content CDN rate-limit combined with missing retry logic in the Failure chain:
Why this is not related to PR #8955:
Recommendations
Evidence
|
|
/retest |
|
needs verified label @bryan-cox |
|
/verified by @bryan-cox See test report here https://bryan-cox.github.io/architectural-artifact-sharing/test-verification-report-ocpbugs-78310/index.html |
|
@bryan-cox: This PR has been marked as verified by DetailsIn response to this:
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. |
|
@hypershift-jira-solve-ci: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions 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. |
|
@hypershift-jira-solve-ci[bot]: Jira Issue Verification Checks: Jira Issue OCPBUGS-78310 Jira Issue OCPBUGS-78310 has been moved to the MODIFIED state and will move to the VERIFIED state when the change is available in an accepted nightly payload. 🕓 DetailsIn response to this:
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. |
What this PR does / why we need it:
The
hcpCLI (product-cli) never calledctrl.SetLogger()before using controller-runtime'sclient.New()viacmd/util.GetClient(). This caused a noisy[controller-runtime] log.SetLogger(...) was never calledwarning with a full goroutine stack trace on everyhcp create clusterinvocation, degrading the customer experience.This PR adds the same
ctrl.SetLogger(zap.New(zap.JSONEncoder(...)))call used by every other binary in the repo (hypershift-operator, control-plane-operator, ignition-server, etc.) toproduct-cli/main.go, early inmain()before any cobra command execution.Which issue(s) this PR fixes:
Fixes https://redhat.atlassian.net/browse/OCPBUGS-78310
Special notes for your reviewer:
This follows the exact same logger initialization pattern already established in
hypershift-operator/main.go,control-plane-operator/main.go,ignition-server/cmd/start.go, and other binaries in this repo. The only binary that was missing it wasproduct-cli.Checklist:
Always review AI generated responses prior to use.
Generated with Claude Code via openshift-developer plugin
Summary by CodeRabbit