-
Notifications
You must be signed in to change notification settings - Fork 40.1k
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 selector to PersistentVolumeClaim #25298
Conversation
The change looks fine. I'm a little apprehensive about merging API changes without the underlying wiring. It would make for a slightly larger PR, but I prefer API change bundled with the business logic. |
GCE e2e build/test passed for commit b639c07. |
@pmorie This should only require an additional bit of logic in the binder. Start here: https://github.com/kubernetes/kubernetes/blob/master/pkg/controller/persistentvolume/types.go#L142 At this point, it's already filtered by AccessModes, the line above sorts and searches by Capacity. We just need an "if selector not nil, then apply selector to labels" as a 3rd filter on available volumes. This should be a relatively easy addition + unit test along with the API changes. |
@pmorie PR needs rebase |
I'm going to close this for now until the proposal that deals with it is merged and the refactor it's going to be on top of is merged. |
Refresh of #21308, original credit to @markturansky
@bgrant0607 for API changes.
@kubernetes/sig-storage