-
Notifications
You must be signed in to change notification settings - Fork 38.7k
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
Automated cherry pick of #48326 #53172
Automated cherry pick of #48326 #53172
Conversation
Hi @andyzhangx. Thanks for your PR. I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
/ok-to-test |
/release-note |
@andyzhangx please refer old PR #48326 in the title, e.g. |
/retest |
name := volume.GenerateVolumeName(a.options.ClusterName, a.options.PVName, 75) | ||
// File share name has a length limit of 63, and it cannot contain two consecutive '-'s. | ||
name := volume.GenerateVolumeName(a.options.ClusterName, a.options.PVName, 63) | ||
name = strings.Replace(name, "--", "-", -1) | ||
capacity := a.options.PVC.Spec.Resources.Requests[v1.ResourceName(v1.ResourceStorage)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some test/docs would be nice about why we are doing what we are doing and also making sure it doesn't regress.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, I will add azure file test case in master branch first, since this is only a cherry pick, shall we merge this PR first?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gnufied agreed with andy, this is a cherry-pick aimed to fix a critical bug.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The original PR was opened without cherry-pick title I think, so I didn't think it was a cherry-pick.
/lgtm |
/test pull-kubernetes-e2e-gce-bazel |
/approve |
@andyzhangx can you link the github issue this PR fixes? |
/test pull-kubernetes-e2e-gce-bazel |
2 similar comments
/test pull-kubernetes-e2e-gce-bazel |
/test pull-kubernetes-e2e-gce-bazel |
@gnufied I have updated the |
/approve no-issue |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: andyzhangx, gnufied Associated issue requirement bypassed by: gnufied The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these OWNERS Files:
You can indicate your approval by writing |
@brendanburns could you approve, thx |
/assign @wojtek-t |
@wojtek-t could you help to approve the cherry-pick? thanks. |
Approved. |
@wojtek-t thanks |
/retest |
/test all [submit-queue is verifying that this PR is safe to merge] |
Automatic merge from submit-queue. |
What this PR does / why we need it:
Azure file share name has a length limit of 63, but currently the code is using data volume's limit 75.
Which issue this PR fixes
cherry-pick fix of #48326
With current implementation, when the cluster name is long, the resulting file share name could have a length of 75.
Also function GenerateVolumeName would produce double '-' when clusterName containing '-' is to be truncated.
In both cases, service would reject the creating file share request.
Special notes for your reviewer:
Please refer to:
https://docs.microsoft.com/en-us/rest/api/storageservices/naming-and-referencing-shares--directories--files--and-metadata#share-names
Share names must be from 3 through 63 characters long.
The name cannot contain two consecutive hyphens.
Release note: