Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed logging of unrelated PVCs #53

Merged

Conversation

jsafrane
Copy link
Contributor

@jsafrane jsafrane commented Aug 7, 2019

Reorder the handling, so claims in progress are used only for PVCs that "should" be processed (i.e. have the right provisioning annotation).

I moved most of the handling into syncClaim, leaving one silent claimsInProgress.Delete in processNextClaimWorkItem when err is nil to catch all the else branches where the PVC is ignored by the controller in syncClaimHandler / syncClaim.

Fixes #53

For every PVC in the cluster all provisioners in the cluster logged:

I0806 11:06:12.926999       1 controller.go:979] Final error received, removing PVC 33dc3c59-b83a-11e9-ab9f-0269002b1a92 from claims in progress
I0806 11:06:12.927129       1 controller.go:902] Provisioning succeeded, removing PVC 33dc3c59-b83a-11e9-ab9f-0269002b1a92 from claims in progress

This is confusing, as it was logged also for PVCs that were not provisioned
by the provisioner.

This patch reorders the handling, so claims in progress are used only for
PVCs that "should" be processed (i.e. have the right provisioning
annotation).
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Aug 7, 2019
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jsafrane

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

The pull request process is described 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 k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 7, 2019
@k8s-ci-robot k8s-ci-robot requested review from childsb and wongma7 August 7, 2019 14:05
@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Aug 7, 2019
@jsafrane jsafrane force-pushed the fix-unrelated-pvc-logging branch from 1b85d91 to aef7290 Compare August 7, 2019 14:05
@wongma7
Copy link
Contributor

wongma7 commented Aug 7, 2019

/lgtm
super

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 7, 2019
@k8s-ci-robot k8s-ci-robot merged commit c525773 into kubernetes-sigs:master Aug 7, 2019
humblec pushed a commit to humblec/sig-storage-lib-external-provisioner that referenced this pull request Jun 18, 2020
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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants