helper

package module
v0.81.2 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2026 License: Apache-2.0 Imports: 10 Imported by: 2

Documentation

Overview

Package helper has helpers for using Viper config

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetViperCombine

func GetViperCombine(cfg model.Reader, key string) interface{}

GetViperCombine returns the value at this key, with all layers combined meant to be used by viper as a work-around for .Get(key) not working

func IsNilValue

func IsNilValue(a interface{}) bool

IsNilValue returns true if a is nil, or a is an interface with nil data

func ParseEnvCSVSplit added in v0.80.0

func ParseEnvCSVSplit(key string, config model.Setup)

ParseEnvCSVSplit is a custom helper for the 'apm_config.ignore_resources' setting.

This implements the env_parser 'csv_coma_separated' from the from the configuration schema.

func ParseEnvJSONOrComma added in v0.80.0

func ParseEnvJSONOrComma(key string, config model.Setup)

ParseEnvJSONOrComma is a custom helper for the following settings:

- private_action_runner.restricted_shell.allowed_commands - private_action_runner.restricted_shell.allowed_paths - process_config.custom_sensitive_words

This implements the env_parser 'json_list_or_comma_separated'

func ParseEnvJSONOrSpace added in v0.80.0

func ParseEnvJSONOrSpace(key string, config model.Setup)

ParseEnvJSONOrSpace is a custom helper for the following settings:

- apm_config.filter_tags.require - apm_config.filter_tags.reject - apm_config.filter_tags_regex.require - apm_config.filter_tags_regex.reject - apm_config.obfuscation.credit_cards.keep_values

This implements the env_parser ”json_list_or_space_separated”

func ParseEnvSplitCommaAndSpace added in v0.80.0

func ParseEnvSplitCommaAndSpace(key string, config model.Setup)

ParseEnvSplitCommaAndSpace is a custom helper for the 'otelcollector.converter.features' setting.

This implements the env_parser 'comma_and_space_separated'

func ParseEnvSplitCommaThenSpace added in v0.80.0

func ParseEnvSplitCommaThenSpace(key string, config model.Setup)

ParseEnvSplitCommaThenSpace is a custom helper for the 'apm_config.features' setting.

This implements the env_parser 'comma_then_space_separated'

func ParseEnvTraceSpan added in v0.80.0

func ParseEnvTraceSpan(key string, config model.Setup)

ParseEnvTraceSpan is a custom helper for the 'apm_config.analyzed_spans' setting.

This implements the env_parser 'traces_span' from the configuration schema

func SetTree added in v0.79.0

func SetTree(cfg model.ReaderWriter, key string, value interface{}, source model.Source)

Types

This section is empty.

Jump to

Keyboard shortcuts

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