-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Truncate long service names to 63 characters
In some environments, the combination of cluster name and hostname can get long enough that a service name exceeds 63 characters. This is not allowed by the dns library, so we need to ensure that we never pass it such long names. This change shortens the name by hashing it to 32 characters, then sandwiching that between the first 15 and last 16 characters of the original name. This way the likely unique parts of the name are preserved, but the total length of the name is shortened to an allowable length. Something similar to kubernetes->k8s.
- Loading branch information
Showing
2 changed files
with
39 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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
This file contains 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