internal

package
v1.999.0-beta.12 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2024 License: Apache-2.0, BSD-3-Clause, Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const DDTagsDelimiter = ":"

DDTagsDelimiter is the separator between key-val pairs for DD env vars

View Source
const OtelTagsDelimeter = "="

OtelTagsDelimeter is the separator between key-val pairs for OTEL env vars

Variables

This section is empty.

Functions

func BoolEnv added in v1.26.0

func BoolEnv(key string, def bool) bool

BoolEnv returns the parsed boolean value of an environment variable, or def otherwise.

func BoolVal added in v1.65.0

func BoolVal(val string, def bool) bool

BoolVal returns the parsed boolean value of string val, or def if not parseable

func DurationEnv added in v1.47.0

func DurationEnv(key string, def time.Duration) time.Duration

DurationEnv returns the parsed duration value of an environment variable, or def otherwise.

func FloatEnv added in v1.59.0

func FloatEnv(key string, def float64) float64

FloatEnv returns the parsed float64 value of an environment variable, or def otherwise.

func ForEachStringTag added in v1.48.0

func ForEachStringTag(str string, delimiter string, fn func(key string, val string))

ForEachStringTag runs fn on every key val pair encountered in str. str may contain multiple key val pairs separated by either space or comma (but not a mixture of both), and each key val pair is separated by a delimiter.

func IntEnv added in v1.36.0

func IntEnv(key string, def int) int

IntEnv returns the parsed int value of an environment variable, or def otherwise.

func ParseTagString added in v1.48.0

func ParseTagString(str string) map[string]string

ParseTagString returns tags parsed from string as map

Types

type LockMap added in v1.53.0

type LockMap struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

LockMap uses an RWMutex to synchronize map access to allow for concurrent access. This should not be used for cases with heavy write load and performance concerns.

func NewLockMap added in v1.53.0

func NewLockMap(m map[string]string) *LockMap

func (*LockMap) Clear added in v1.53.0

func (l *LockMap) Clear()

func (*LockMap) Get added in v1.53.0

func (l *LockMap) Get(k string) string

func (*LockMap) Iter added in v1.53.0

func (l *LockMap) Iter(f func(key string, val string))

Iter iterates over all the map entries passing in keys and values to provided func f. Note this is READ ONLY.

func (*LockMap) Len added in v1.53.0

func (l *LockMap) Len() int

func (*LockMap) Set added in v1.53.0

func (l *LockMap) Set(k, v string)

type MetaStructValue added in v1.63.0

type MetaStructValue struct {
	Value any // TODO: further constraining Value's type, especially if it becomes public
}

MetaStructValue is a custom type wrapper used to send metadata to the agent via the `meta_struct` field instead of the `meta` inside a span.

Directories

Path Synopsis
appsec
Package httpmem provides an in-memory HTTP server and client, for testing
Package httpmem provides an in-memory HTTP server and client, for testing
Package log provides logging utilities for the tracer.
Package log provides logging utilities for the tracer.
Package traceprof contains shared logic for cross-cutting tracer/profiler features.
Package traceprof contains shared logic for cross-cutting tracer/profiler features.
testapp
Package testapp has the protbuf/grpc definitions for the test application implemented in traceproftest.
Package testapp has the protbuf/grpc definitions for the test application implemented in traceproftest.
traceproftest
Package traceproftest contains test cases and test helpers for testing cross-cutting tracer/profiler features such as code hotspots and endpoints.
Package traceproftest contains test cases and test helpers for testing cross-cutting tracer/profiler features such as code hotspots and endpoints.

Jump to

Keyboard shortcuts

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