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

Outline csi-prefixed parameters included by --extra-create-metadata #372

Merged

Conversation

chrishenzie
Copy link
Contributor

@chrishenzie chrishenzie commented Oct 14, 2020

Outline

  • Updates external-provisioner and external-snapshotter docs to clarify behavior around prefixed parameter keys and include keys added by the --extra-create-metadata flag.

Resources

NOTE: Do not merge this until the above PR is merged and a release is cut.

@k8s-ci-robot k8s-ci-robot added do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Oct 14, 2020
@k8s-ci-robot
Copy link
Contributor

Welcome @chrishenzie!

It looks like this is your first PR to kubernetes-csi/docs 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-csi/docs has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Oct 14, 2020

#### VolumeSnapshot and VolumeSnapshotContent Parameters

The CSI `external-snapshotter` (TODO: Fill version here) introduces the `--extra-create-metadata` flag, which automatically sets the following `map<string, string> parameters` in the CSI `CreateSnapshotRequest`:
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe you can split this into 2 PRs, one includes features already released, and the other one should not be merged until there's a release that contains the extra-create-metadata?

@fejta-bot
Copy link

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jan 30, 2021
@xing-yang
Copy link
Contributor

@chrishenzie can you update this PR?

@chrishenzie
Copy link
Contributor Author

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 8, 2021
@chrishenzie chrishenzie force-pushed the extra-create-metadata branch from 0059ea1 to b2ff2ef Compare February 8, 2021 20:50
@chrishenzie
Copy link
Contributor Author

@xing-yang Rebased and removed the TODO, this flag is now available in external-snapshotter v4.0.0+.

The following reserved `VolumeSnapshotClass` parameter keys trigger behavior in the CSI `external-snapshotter`:

* `csi.storage.k8s.io/snapshotter-secret-name`
* `csi.storage.k8s.io/snapshotter-secret-namespace`
Copy link
Contributor

Choose a reason for hiding this comment

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

csi.storage.k8s.io/snapshotter-secret-name and csi.storage.k8s.io/snapshotter-secret-namespace were added in v1.0.1 for delete snapshot secrets.

* `csi.storage.k8s.io/snapshotter-secret-name`
* `csi.storage.k8s.io/snapshotter-secret-namespace`
* `csi.storage.k8s.io/snapshotter-list-secret-name`
* `csi.storage.k8s.io/snapshotter-list-secret-namespace`
Copy link
Contributor

Choose a reason for hiding this comment

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

csi.storage.k8s.io/snapshotter-list-secret-name and csi.storage.k8s.io/snapshotter-list-secret-namespace were added in v2.1.0 for list snapshots secrets.


When provisioning a new volume snapshot, the CSI `external-snapshotter` sets the `map<string, string> parameters` field in the CSI `CreateSnapshotRequest` call to the key/values specified in the `VolumeSnapshotClass` it is handling.

The CSI `external-snapshotter` (v2.1.0+) also reserves the parameter keys prefixed with `csi.storage.k8s.io/`. Any `VolumeSnapshotClass` keys prefixed with `csi.storage.k8s.io/` are not passed to the CSI driver as an opaque `parameter`.
Copy link
Contributor

Choose a reason for hiding this comment

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

Some keys were added in v1.0.1 and some were added in v2.1.0.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Would you prefer I remove the parentheses on line 30 and then put the versions next to the corresponding parameter keys below?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, that sounds good.

@chrishenzie chrishenzie force-pushed the extra-create-metadata branch from b2ff2ef to b613048 Compare February 10, 2021 20:13
@xing-yang
Copy link
Contributor

/release-note-none

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Feb 18, 2021
@xing-yang
Copy link
Contributor

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 18, 2021
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: chrishenzie, xing-yang

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 Feb 18, 2021
@k8s-ci-robot k8s-ci-robot merged commit fb81397 into kubernetes-csi:master Feb 18, 2021
@chrishenzie chrishenzie deleted the extra-create-metadata branch February 18, 2021 03:12
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. release-note-none Denotes a PR that doesn't merit a release note. 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.

4 participants