namingschema

package
v1.63.0 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: Apache-2.0, BSD-3-Clause, Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package namingschema allows to use the naming schema from the integrations to set different service and span/operation names based on the value of the DD_TRACE_SPAN_ATTRIBUTE_SCHEMA environment variable.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AWSOpName added in v1.61.0

func AWSOpName(awsService, awsOp, overrideV0 string) string

func DBOpName added in v1.61.0

func DBOpName(system string, overrideV0 string) string

func OpName added in v1.61.0

func OpName(t IntegrationType) string

func OpNameOverrideV0 added in v1.61.0

func OpNameOverrideV0(t IntegrationType, overrideV0 string) string

func ServiceName added in v1.61.0

func ServiceName(fallback string) string

func ServiceNameOverrideV0 added in v1.61.0

func ServiceNameOverrideV0(fallback, overrideV0 string) string

func SetUseGlobalServiceName added in v1.52.0

func SetUseGlobalServiceName(v bool)

SetUseGlobalServiceName sets the value of the useGlobalServiceName setting used for this application.

func SetVersion

func SetVersion(v Version)

SetVersion sets the global naming schema version used for this application.

func UseGlobalServiceName added in v1.52.0

func UseGlobalServiceName() bool

UseGlobalServiceName returns the value of the useGlobalServiceName setting for this application.

Types

type IntegrationType added in v1.61.0

type IntegrationType int
const (
	// client/server
	HTTPClient IntegrationType = iota
	HTTPServer
	GRPCClient
	GRPCServer
	GraphqlServer
	TwirpClient
	TwirpServer

	// messaging
	KafkaOutbound
	KafkaInbound
	GCPPubSubInbound
	GCPPubSubOutbound

	// cache
	MemcachedOutbound
	RedisOutbound

	// db
	ElasticSearchOutbound
	MongoDBOutbound
	CassandraOutbound
	LevelDBOutbound
	BuntDBOutbound
	ConsulOutbound
	VaultOutbound
)

type Version

type Version int

Version represents the available naming schema versions.

const (
	// SchemaV0 represents naming schema v0.
	SchemaV0 Version = iota
	// SchemaV1 represents naming schema v1.
	SchemaV1
)

func GetVersion

func GetVersion() Version

GetVersion returns the global naming schema version used for this application.

func ParseVersion

func ParseVersion(v string) (Version, bool)

ParseVersion attempts to parse the version string.

func SetDefaultVersion

func SetDefaultVersion() Version

SetDefaultVersion sets the default global naming schema version.

Jump to

Keyboard shortcuts

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