trail

package
v0.0.0-...-a8d3764 Latest Latest
Warning

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

Go to latest
Published: Jan 27, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const DebugReportMetadata = "trace-debug-report"

DebugReportMetadata is a key in metadata holding debug information about the error - stack traces and original error

Variables

This section is empty.

Functions

func DecodeDebugInfo

func DecodeDebugInfo(err error, meta metadata.MD) error

DecodeDebugInfo decodes debug information about error from the metadata and returns error with enriched metadata about it

func FromGRPC

func FromGRPC(err error, args ...interface{}) error

FromGRPC converts error from GRPC error back to trace.Error Debug information will be retrieved from the metadata if specified in args

func Send

func Send(ctx context.Context, err error) error

Send is a high level function that: * converts error to GRPC error * attaches debug metadata to existing metadata if possible * sends the header to GRPC

func SetDebugInfo

func SetDebugInfo(err error, meta metadata.MD)

SetDebugInfo adds debug metadata about error (traces, original error) to request metadata as encoded property

func ToGRPC

func ToGRPC(originalErr error) error

ToGRPC converts error to GRPC-compatible error

Types

This section is empty.

Jump to

Keyboard shortcuts

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