Skip to content

Revert "Use patch to replace update"#157

Merged
k8s-ci-robot merged 2 commits intokubernetes-csi:masterfrom
jsafrane:revert-patch
Jun 20, 2019
Merged

Revert "Use patch to replace update"#157
k8s-ci-robot merged 2 commits intokubernetes-csi:masterfrom
jsafrane:revert-patch

Conversation

@jsafrane
Copy link
Copy Markdown
Contributor

This reverts commit f953647.

PATCH usage introduced in #149 needs new RBAC rules and that effectively breaks API. We don't want to bump the image to v2.0 (yet).

ddebroy @davidz627 PTAL, I think I fixed in-line attachment unit tests correctly.

@cwdsuzhou, sorry, your contribution is great, however we'd prefer to be on the safe side. We'll keep your patch around when v2.0 time comes.

/kind api-change
(?)

Does this PR introduce a user-facing change?:

NONE

This reverts commit f953647.

PATCH needs new RBAC rules and that effectively breaks API.
@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API labels Jun 18, 2019
@k8s-ci-robot
Copy link
Copy Markdown
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

Details 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 requested review from davidz627 and msau42 June 18, 2019 09:04
@k8s-ci-robot k8s-ci-robot added 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. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Jun 18, 2019
@msau42
Copy link
Copy Markdown
Collaborator

msau42 commented Jun 18, 2019

/assign @davidz627 @ddebroy

Copy link
Copy Markdown
Contributor

@davidz627 davidz627 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM mod comment fix. Odd that we don't retry Update errors but I remember something about just letting the caller retry the whole attach operation (?) Anyway it's not related to this revert.

Comment thread pkg/controller/csi_handler.go Outdated
func (h *csiHandler) saveVA(va *storage.VolumeAttachment, patch []byte) (*storage.VolumeAttachment, error) {
newVA, err := h.client.StorageV1beta1().VolumeAttachments().Patch(va.Name, types.MergePatchType, patch)
func (h *csiHandler) saveVA(va *storage.VolumeAttachment) (*storage.VolumeAttachment, error) {
// TODO: use patch to save us from VersionError
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you link an issue (with a link to the original reverted Patch PR) for context

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added links to #158 and #157

@msau42 msau42 mentioned this pull request Jun 19, 2019
@msau42
Copy link
Copy Markdown
Collaborator

msau42 commented Jun 19, 2019

BTW, opened #158 to keep track of changes we should do when we're ready for a 2.0

@msau42
Copy link
Copy Markdown
Collaborator

msau42 commented Jun 20, 2019

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jun 20, 2019
@k8s-ci-robot k8s-ci-robot merged commit 7ebc037 into kubernetes-csi:master Jun 20, 2019
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. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants