chore(metrics): remove leftover client_golang tutorial scaffolding - #2263
Conversation
Signed-off-by: Shridhar Panigrahi <198173519+veyron-kairo@users.noreply.github.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
💤 Files with no reviewable changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThe change removes obsolete example code and comments from the vGPU monitor. It updates documentation for monitor state, metric collection, shared-informer lookups, and zone-labeling registration. It also removes the mock assessment method. ChangesvGPU monitor documentation cleanup
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related issues
Possibly related PRs
Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
mesutoezdil
left a comment
There was a problem hiding this comment.
lgtm. nit: two more tutorial scraps remain, the commented NewClusterManager("ca") in main.go and the "Prometheus-ignorant" comment above NewClusterManager, mind sweeping those too?
Removes the commented-out NewClusterManager("ca", reg) call and the
"in real code" preamble above it, and rewrites the NewClusterManager doc
comment, which described a tutorial-era constructor that no longer matches
the function.
No functional change.
Signed-off-by: Shridhar Panigrahi <198173519+veyron-kairo@users.noreply.github.com>
|
@mesutoezdil done, swept both. |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: archlitchi, veyron-kairo 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 |
Codecov Report✅ All modified and coverable lines are covered by tests.
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Removes dead scaffolding left over from the client_golang tutorial in
cmd/vGPUmonitor/metrics.go: the unusedReallyExpensiveAssessmentOfTheSystemStatemock function (returned fabricated data, no callers), a block of commented-out functions (parseidstr,gettotalusage,getTotalUtilization), and two stale doc comments referencing them. No functional change — theZonefield and all metric output are untouched.Which issue(s) this PR fixes:
Addresses the dead-code item of #2249 (per-scrape descriptor hoisting will follow as a separate PR).
Special notes for your reviewer:
No behavior change.
make verifyandgo build ./cmd/vGPUmonitor/pass locally.AI assistance disclosure:
I used AI assistance (Claude Code) to identify the dead code . I reviewed and verified the change (confirmed zero callers), wrote the commit message myself, ran
make verifylocally, and take responsibility for it.Does this PR introduce a user-facing change?:
NONE
Summary by CodeRabbit