This repository has been archived by the owner on Sep 14, 2020. It is now read-only.
Force annotations to end strictly with alphanumeric characters #353
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 do these changes do?
Force annotation names to end strictly with alphanumeric characters, not only to fit into 63 chars.
"Learning Kubernetes the hard way."
Description
The annotation names are not only limited to 63 characters, and not only to a specific alphabet, but also to the beginning/ending characters. Otherwise, it fails to patch:
Since base64 of a digest was used to make the shortened annotations names unique in #346, it can end with
=
characters, for example.In this case, we do not need the actual base64'ed value, we just need a persistent and unique suffix. So, cutting those special non-alphanumeric characters is fine.
The change is backward compatible (despite the hashing function change since 0.27rc4): first, it was never released beyond RC; second, it was not working for non-alphanumeric annotations anyway. Proper alphanumeric annotations will remain the same as in 0.27rc4.
Issues/PRs
Type of changes
Checklist
CONTRIBUTORS.txt