Label terminology - cloudfoundry/cloud_controller_ng GitHub Wiki
Label terminology
(This is broadly based on the k8s label document)
Labels are made up of key/value pairs.
For querying, a label_selector is used.
Label Keys
Label keys are made up of an (optional) prefix, and name. If a prefix is present, it is separated from the name by a /.
- without a prefix:
release - with a prefix:
example.com/release
Label key prefix
- Length restriction: 0-253 characters
- Character restriction: DNS subdomain format (series of subdomain labels separated by
.) - Valid examples:
beeblebroxexample.comfoo.bar.baz.somewhere.over.the.rainbow.capi.land- (literally empty)
- Invalid examples:
.fundope.foo..bar@#$(@(this.is.entirely.too.long.of.a.prefix.so.there.you.have.it.like.super.long.omg.it.repeats.this.is.entirely.too.long.of.a.prefix.so.there.you.have.it.like.super.long.omg.it.repeats.this.is.entirely.too.long.of.a.prefix.so.there.you.have.it.like.super.long
Label key name
- Length restriction: 1-63 characters
- Character restriction: alphanumeric with
-,_, and.allowed. Must begin and end with alphanumeric. - Valid examples:
release_v1_duhProduction-clusterbilling.system.1234.foo
- Invalid examples:
1DirectionyoooooooooooooooooooooooooooooooooooooooooooThisIsLikeTooLongBrahDatacenter-US-1Something~Or
Label Values
- Length restriction: 0-63 characters
- Character restriction: alphanumeric with
-,_, and.allowed. Must begin and end with alphanumeric. - Valid examples:
environment_v7_ultra- (literally empty)
Current-versionstate.county.wa.king
- Invalid examples:
98DegreesheyyoooooooooooooooooooooooooooooooooooooooooooWayTooLongMadameLets.count.to.10Legend~~Of&&The##Forbidden@@Characters
Label Selectors
Each label_selector consists of one or more requirements, separated by a comma.