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

Add PublishedNodes field to ListVolumes Response #374

Merged

Conversation

davidz627
Copy link
Contributor

@davidz627 davidz627 commented Aug 7, 2019

Helps the CO reconcile the actual state when the volume may have been Unpublished from the node out of band from the CO.

/assign @saad-ali
/cc @xing-yang @gnufied @julian-hj
/cc @msau42

PTAL Discussion: https://docs.google.com/document/d/1-oiNg5V_GtS_JBAEViVBhZ3BYVFlbSz70hreyaD7c5Y/edit#heading=h.z24362cngqjs

@saad-ali saad-ali self-requested a review August 7, 2019 21:04
@saad-ali
Copy link
Member

saad-ali commented Aug 7, 2019

CC @julian-hj @ddebroy

@jieyu
Copy link
Member

jieyu commented Aug 7, 2019

Can you make sure the protobuf file is also updated accordingly. There's a makefile target for the generation.

@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch from f91bed5 to 1f3fea5 Compare August 7, 2019 22:15
@davidz627
Copy link
Contributor Author

How do we feel about adding something like:

List nodes published MAY return volumes not published or created by the driver. The CO MUST be resilient to that

@jieyu
Copy link
Member

jieyu commented Aug 9, 2019

@davidz627 that sounds reasonable to me

Copy link
Contributor

@ddebroy ddebroy left a comment

Choose a reason for hiding this comment

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

LGTM based on discussion during CSI meeting.

One (tangential) q I have around this: Is there a reason NodeGetInfoResponse does not report the list of volumes that has been published to the node?

csi.proto Outdated Show resolved Hide resolved
@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch 2 times, most recently from 817e7dd to 417ad69 Compare August 13, 2019 18:55
@davidz627
Copy link
Contributor Author

@saad-ali @jieyu resolved comments, checks passing, improved wording, PTAL

@davidz627
Copy link
Contributor Author

One (tangential) q I have around this: Is there a reason NodeGetInfoResponse does not report the list of volumes that has been published to the node?

I don't think that there's a particular reason it doesn't. But for this proposal IMO it is more efficient to have the one list volumes call give back all volumes and where they're attached. Also for some reason it states specifically: The result of this call will be used by CO in ControllerPublishVolume. which is not what we'll be using it for.

csi.proto Show resolved Hide resolved
csi.proto Outdated Show resolved Hide resolved
@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch from 417ad69 to 9fec488 Compare August 13, 2019 23:03
spec.md Outdated Show resolved Hide resolved
@gnufied
Copy link
Contributor

gnufied commented Aug 14, 2019

LGTM apart from the minor nit above.

@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch from 9fec488 to 7b15d3e Compare August 14, 2019 17:24
csi.proto Outdated Show resolved Hide resolved
csi.proto Outdated Show resolved Hide resolved
csi.proto Show resolved Hide resolved
@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch 2 times, most recently from 41dbb3a to f9402a6 Compare August 26, 2019 23:48
@davidz627
Copy link
Contributor Author

davidz627 commented Aug 26, 2019

@jdef @jieyu @julian-hj @ddebroy @saad-ali
Anything else needed for approval/review?

@gnufied
Copy link
Contributor

gnufied commented Aug 27, 2019

One thing worth mentioning here is - depending on SP, the published_node_ids field value might be out of date(stale). For example - on AWS because of eventual consistent nature of read api calls, the describe_volume API calls could return stale attachment information. In kubernetes - we handle this by processing out of band attach/detaches as "uncertain", because only a mutable api call guarantees that volume information was accurate.

So, if a CSI driver returns stale data in published_node_ids, is that non-compliant/buggy? What actions CO should take in that case?

Copy link
Member

@saad-ali saad-ali left a comment

Choose a reason for hiding this comment

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

/lgtm
/approve
This looks reasonable to me.

If there are no other objections, I'll go ahead and merge this.

spec.md Show resolved Hide resolved
spec.md Show resolved Hide resolved
csi.proto Show resolved Hide resolved
@davidz627 davidz627 force-pushed the feature/VerifyVolumes branch from f9402a6 to 97b40cb Compare August 28, 2019 20:08
@jdef jdef merged commit 9e773d2 into container-storage-interface:master Aug 28, 2019
@davidz627 davidz627 deleted the feature/VerifyVolumes branch August 28, 2019 22:20
timoreimann pushed a commit to digitalocean/csi-digitalocean that referenced this pull request Dec 19, 2021
According to [1], this "helps the CO [container orchestrator] reconcile
the actual state when the volume may have been Unpublished from the node
out of band from the CO".

[1] container-storage-interface/spec#374
timoreimann pushed a commit to digitalocean/csi-digitalocean that referenced this pull request Dec 19, 2021
According to [1], this "helps the CO [container orchestrator] reconcile
the actual state when the volume may have been Unpublished from the node
out of band from the CO".

[1] container-storage-interface/spec#374
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants