-
Notifications
You must be signed in to change notification settings - Fork 183
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
feat!: truncate fullname after 22 characters #3248
Conversation
I actually think the limit for this wasn't determined by StatefulSets, but by label values. Can you make sure this test:
We also need a note about this change in the v4 migration doc. |
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.
This pull request contains invalid labels. Please remove all of the following labels: ['do-not-merge/hold']
f669dba
to
38d502f
Compare
Changes applies. But, please note that because this does not cause template rendering to fail, the test actually does not check anything more. |
@@ -7,14 +7,15 @@ Expand the name of the chart. | |||
|
|||
{{/* | |||
Create a default fully qualified app name. |
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.
I think we want to make the same change for sumologic.name
above.
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.
Is it used anywhere? I grepped for that name and it seems that it's not used anywhere
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.
Huh, we should delete it then.
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.
I'll do it in another pr
38d502f
to
51cca8f
Compare
The test checks the actual object names and label values. |
What about this then?
What should we check here if we're not failing the rendering? |
Maybe just delete that test? We're checking the limits on K8s objects here:
|
You should also remove the warning I added in #3054. Incidentally, does putting the |
51cca8f
to
76410fa
Compare
in |
Ok, I tested and |
Yeah, seems better all around. |
76410fa
to
51135b6
Compare
Warning removed and tests fixed. |
releaseName = "collection-test" | ||
releaseName = "col-test" |
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.
Why is this change necessary?
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.
Else we get such failures: https://github.com/SumoLogic/sumologic-kubernetes-collection/actions/runs/6109112931/job/16579492782
and I found it easier to modify the constant instead of modifying the tests
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.
But why does this change cause these failures. collection-test
is less than 22 characters, so it shouldn't make any difference, right?
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.
But -sumologic
is added to that. And as a result we truncate collection-test-sumologic
, which is more than 22 chars.
51135b6
to
6c65826
Compare
Fixes #3057
The longest name for a statefulset I found was
*-otelcloudwatch-logs-collector
, the suffix here is30
characters.According to kubernetes/kubernetes#64023 the statefulset name should be 52 characters or shorter.
I did not manage to fail rendering the template, I tried using both
fail
andrequired
function but without success. This is why I'm only truncating thesumologic.fullname
name.Checklist