refactor: moved unused commitments kpi for vmware#774
Conversation
Co-authored-by: Copilot <copilot@github.com>
|
Warning Rate limit exceeded
To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThis pull request relocates and enhances the VMware resource commitments KPI from the compute layer to the infrastructure layer. The implementation is rewritten to handle both general-purpose compute commitments (CPU/RAM) and HANA instance commitments, with shared utility functions extracted for flavor classification and memory unit conversion. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~30 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ 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. Review rate limit: 0/1 reviews remaining, refill in 44 minutes and 43 seconds.Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
internal/knowledge/kpis/plugins/infrastructure/shared.go (1)
98-100: Comment references the wrong constant name.The doc says
vmwareDefaultCPUArch, but the actual constant isdefaultCPUArch. Please align the comment to avoid confusion.Proposed doc fix
-// The first matching rule wins; vmwareDefaultCPUArch is used when none match. +// The first matching rule wins; defaultCPUArch is used when none match.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@internal/knowledge/kpis/plugins/infrastructure/shared.go` around lines 98 - 100, The comment above flavorCPUArchitectureRules references a non-existent constant name vmwareDefaultCPUArch; update the doc comment to refer to the actual constant defaultCPUArch so it matches the code and avoids confusion (the comment is tied to the cpuArchRule mapping and the flavorCPUArchitectureRules variable).internal/knowledge/kpis/plugins/infrastructure/vmware_resource_commitments.go (1)
21-21: Fix typo in KPI docs comment.
speicficshould bespecificfor readability.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@internal/knowledge/kpis/plugins/infrastructure/vmware_resource_commitments.go` at line 21, Fix the typo in the package comment that reads "For general purpose workload customer can speicfic amounts of resources." — change "speicfic" to "specific" so the comment reads "For general purpose workload customer can specific amounts of resources." (Adjust surrounding grammar if desired.)
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In `@internal/knowledge/kpis/plugins/infrastructure/shared.go`:
- Around line 98-100: The comment above flavorCPUArchitectureRules references a
non-existent constant name vmwareDefaultCPUArch; update the doc comment to refer
to the actual constant defaultCPUArch so it matches the code and avoids
confusion (the comment is tied to the cpuArchRule mapping and the
flavorCPUArchitectureRules variable).
In
`@internal/knowledge/kpis/plugins/infrastructure/vmware_resource_commitments.go`:
- Line 21: Fix the typo in the package comment that reads "For general purpose
workload customer can speicfic amounts of resources." — change "speicfic" to
"specific" so the comment reads "For general purpose workload customer can
specific amounts of resources." (Adjust surrounding grammar if desired.)
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 6d522c40-1e29-4640-bfde-c0332f07d7d3
📒 Files selected for processing (9)
helm/bundles/cortex-nova/templates/kpis.yamlinternal/knowledge/kpis/plugins/compute/resource_commitments_vmware.gointernal/knowledge/kpis/plugins/compute/resource_commitments_vmware_test.gointernal/knowledge/kpis/plugins/infrastructure/shared.gointernal/knowledge/kpis/plugins/infrastructure/shared_test.gointernal/knowledge/kpis/plugins/infrastructure/vmware_project_utilization.gointernal/knowledge/kpis/plugins/infrastructure/vmware_resource_commitments.gointernal/knowledge/kpis/plugins/infrastructure/vmware_resource_commitments_test.gointernal/knowledge/kpis/supported_kpis.go
💤 Files with no reviewable changes (2)
- internal/knowledge/kpis/plugins/compute/resource_commitments_vmware_test.go
- internal/knowledge/kpis/plugins/compute/resource_commitments_vmware.go
…ix typo in VMware resource commitments comment Co-authored-by: Copilot <copilot@github.com>
Test Coverage ReportTest Coverage 📊: 69.4% |
Changes