kube-state-metrics icon indicating copy to clipboard operation
kube-state-metrics copied to clipboard

refactor: KSM Cyclomatic fix for Job and PV files

Open venkatbvc opened this issue 2 years ago • 16 comments

Fixed cyclomatic complexity for Job.go and persistentVolume.go files Changes to be committed: modified: internal/store/job.go modified: internal/store/persistentvolume.go

What this PR does / why we need it: Fix the cyclomatic complexity for job.go and persistentVolume.go How does this change affect the cardinality of KSM: (increases, decreases or does not change cardinality) No change to cardinality Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged): Fixes # Fixes partially 1887

venkatbvc avatar Jun 07 '23 14:06 venkatbvc

@rexagod Pushed changes for Job.go and persistentVolume.go. Please review

venkatbvc avatar Jun 07 '23 15:06 venkatbvc

/cc @rexagod

venkatbvc avatar Jun 07 '23 15:06 venkatbvc

@rexagod @CatherineF-dev @fpetkovski can you please review and share your comments

venkatbvc avatar Jun 12 '23 19:06 venkatbvc

Reviewed internal/store/job.go.

If you split this PR into two PRs (job and pv), I think the job one can be merged asap.

CatherineF-dev avatar Jun 14 '23 12:06 CatherineF-dev

@CatherineF-dev I reverted the pv changes. Please check.

venkatbvc avatar Jun 14 '23 17:06 venkatbvc

/triage accepted /assign @CatherineF-dev

logicalhan avatar Jun 15 '23 16:06 logicalhan

/assign @rexagod

logicalhan avatar Jun 15 '23 16:06 logicalhan

@rexagod @CatherineF-dev Can you please look at the changes?

venkatbvc avatar Jun 21 '23 13:06 venkatbvc

/lgtm

Waiting @rexagod's review

CatherineF-dev avatar Jun 21 '23 13:06 CatherineF-dev

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: CatherineF-dev, venkatbvc Once this PR has been reviewed and has the lgtm label, please ask for approval from rexagod. For more information see the Kubernetes Code Review Process.

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

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

k8s-ci-robot avatar Jun 21 '23 13:06 k8s-ci-robot

@rexagod can you please review?

venkatbvc avatar Jun 23 '23 03:06 venkatbvc

Hello, @venkatbvc. Thank you for the PR, however, there's some development recently that affects the areas covered by the parent issue. With the CEL and CRD changes planned for the near future, we are again going to need to check for any lint (warn-level, that do not block the CI) issues again once those changes are in.

I think it's better to stall this for now and resume this effort once that is done with to avoid repeating the same effort. In the meantime, if you're looking for a good-first-issue we've got this: https://github.com/kubernetes/kube-state-metrics/issues/1903 that's been there for a while, and I'd be happy to help with anything around it! 🙂

rexagod avatar Jun 23 '23 12:06 rexagod

/hold Until aforementioned factors clear up.

rexagod avatar Jun 23 '23 12:06 rexagod

@rexagod Sure we will wait. This week i am little busy. i will get in touch with you next week

venkatbvc avatar Jun 26 '23 05:06 venkatbvc

PR needs rebase.

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/test-infra repository.

k8s-ci-robot avatar Aug 22 '23 23:08 k8s-ci-robot

The Kubernetes project currently lacks enough contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle stale
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot avatar Jan 21 '24 03:01 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Mark this PR as fresh with /remove-lifecycle rotten
  • Close this PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten

k8s-triage-robot avatar Feb 20 '24 03:02 k8s-triage-robot

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Reopen this PR with /reopen
  • Mark this PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

k8s-triage-robot avatar Mar 21 '24 04:03 k8s-triage-robot

@k8s-triage-robot: Closed this PR.

In response to this:

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs.

This bot triages PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the PR is closed

You can:

  • Reopen this PR with /reopen
  • Mark this PR as fresh with /remove-lifecycle rotten
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/close

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/test-infra repository.

k8s-ci-robot avatar Mar 21 '24 04:03 k8s-ci-robot