utils

package
v1.20.4 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2026 License: Apache-2.0 Imports: 3 Imported by: 3 modules, 8 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultIfEmpty added in v1.4.0

func DefaultIfEmpty(m map[string]string, def map[string]string) map[string]string

func EnrichLoggerWithLabels added in v1.5.0

func EnrichLoggerWithLabels(logger *log.Logger, labelsMaps ...map[string]string) *log.Logger

func IsSubset added in v1.4.10

func IsSubset(a, b []string) bool

IsSubset checks if a set contains b subset

func LabelNames

func LabelNames(labels map[string]string) []string

LabelNames returns sorted label keys

func LabelValues

func LabelValues(labels map[string]string, labelNames []string) []string

func MergeLabels

func MergeLabels(labelsMaps ...map[string]string) map[string]string

MergeLabels merges several maps into one. Last map keys overrides keys from first maps.

Can be used to copy a map if just one argument is used.

Types

This section is empty.

Jump to

Keyboard shortcuts

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