package spans

import "github.com/ydb-platform/ydb-go-sdk/v3/spans"

Index

Constants

const (
	IntType      = kv.IntType
	Int64Type    = kv.Int64Type
	StringType   = kv.StringType
	BoolType     = kv.BoolType
	StringsType  = kv.StringsType
	StringerType = kv.StringerType
)

Functions

func Retry

func Retry(adapter Adapter) (t trace.Retry)

func WithTraces

func WithTraces(adapter Adapter) ydb.Option

Types

type Adapter

type Adapter interface {
	trace.Detailer

	SpanFromContext(ctx context.Context) Span
	Start(ctx context.Context, operationName string, attributes ...KeyValue) (context.Context, Span)
}

Adapter is interface of specific tracing system adapters

Experimental: https://github.com/ydb-platform/ydb-go-sdk/blob/master/VERSIONING.md#experimental

type Field

type Field = kv.KeyValue

type KeyValue

type KeyValue = kv.KeyValue

KeyValue is key-value attribute for attaching into span

type Span

type Span interface {
	TraceID() (_ string, valid bool)

	Link(link Span, attributes ...KeyValue)

	Log(msg string, attributes ...KeyValue)
	Warn(err error, attributes ...KeyValue)
	Error(err error, attributes ...KeyValue)

	End(attributes ...KeyValue)
}

Span is an interface of spans in specific tracing system

Experimental: https://github.com/ydb-platform/ydb-go-sdk/blob/master/VERSIONING.md#experimental

Source Files

coordination.go discovery.go driver.go errors.go field.go helpers.go query.go ratelimiter.go retry.go safe.go scheme.go scripting.go spans.go sql.go table.go traces.go

Version
v3.89.5
Published
Nov 5, 2024
Platform
darwin/amd64
Imports
15 packages
Last checked
4 seconds ago

Tools for package owners.