add length limits to API name#602
Open
LiZhenCheng9527 wants to merge 1 commit intokurator-dev:mainfrom
Open
Conversation
Collaborator
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
✅ Deploy Preview for kurator-dev canceled.
|
462df79 to
f843110
Compare
f843110 to
6348727
Compare
hzxuzhonghu
reviewed
Feb 20, 2024
| name := customCluster.Name + "-" + ClusterHostsName | ||
| name = strings.ToLower(name) | ||
| if len(name) > 63 { | ||
| name = name[:63] |
Member
There was a problem hiding this comment.
Two cents:
- donot hardcode
- If we strip, could we get duplicate resource names?
Signed-off-by: LiZhenCheng9527 <lizhencheng6@huawei.com>
6348727 to
141b1fd
Compare
hzxuzhonghu
reviewed
Feb 21, 2024
Member
hzxuzhonghu
left a comment
There was a problem hiding this comment.
iirc, this is not right, if the name is suffixed with random chars, when we reconcile delete, we could not cleanup the generated resources
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What type of PR is this?
/kind feature
Which issue(s) this PR fixes:
a part of #544