labels

package
v0.0.0-...-54c47e7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 18, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReplacePrefixed

func ReplacePrefixed(prefix string, originalLabels map[string]string, newLabels map[string]string) (labels map[string]string, updated bool)

ReplacePrefixed returns a copy of originalLabels after:

  • removing all keys with the given prefix, or a subdomain of it;
  • merging newLabels.

Inputs are not modified. The returned labels map is guaranteed to be non-nil. Updated is true if the elements of labels do not match the elements of originalLabels.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL