tags

package
v0.15.2 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2021 License: BSD-2-Clause Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractTags

func ExtractTags(s string) map[string]string

ExtractTags extracts all graphite-style tags out of metric name E.x. cpu.usage_idle;cpu=cpu-total;host=test => {"name": "cpu.usage_idle", "cpu": "cpu-total", "host": "test"} There are some differences between how we handle tags and how graphite-web can do that. In our case it is possible to have empty value as it doesn't make sense to skip tag in that case but can be potentially useful Also we do not fail on invalid cases, but rather than silently skipping broken tags as some backends might accept invalid tag and store it and one of the purposes of carbonapi is to keep working even if backends gives us slightly broken replies.

Types

This section is empty.

Jump to

Keyboard shortcuts

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