grpc

package
v2.13.0 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StreamServerInterceptor added in v2.7.0

func StreamServerInterceptor(options ...Option) grpc.StreamServerInterceptor

StreamServerInterceptor returns a middleware that creates datadog-spans on incoming requests, and stores them in the requests' context.

func TraceStreamServerInterceptor deprecated added in v2.1.0

func TraceStreamServerInterceptor() grpc.StreamServerInterceptor

TraceStreamServerInterceptor for Datadog Log Integration, middleware will create span that can be used from context

Deprecated: Use StreamServerInterceptor instead. This function will be removed in a later version.

func TraceUnaryClientInterceptor deprecated added in v2.3.0

func TraceUnaryClientInterceptor() grpc.UnaryClientInterceptor

TraceUnaryClientInterceptor create a client-interceptor to automatically create child-spans, and append to gRPC metadata.

Deprecated: Use UnaryClientInterceptor instead. This function will be removed in a later version.

func TraceUnaryServerInterceptor deprecated

func TraceUnaryServerInterceptor() grpc.UnaryServerInterceptor

TraceUnaryServerInterceptor for Datadog Log Integration, middleware will create span that can be used from context

Deprecated: Use UnaryServerInterceptor instead. This function will be removed in a later version.

func UnaryClientInterceptor added in v2.7.0

func UnaryClientInterceptor(options ...Option) grpc.UnaryClientInterceptor

UnaryClientInterceptor create a client-interceptor to automatically create child-spans, and append to gRPC metadata. UnaryServerInterceptor returns a middleware that creates datadog-spans on outgoing requests, and adds them to the request's gRPC-metadata.

func UnaryServerInterceptor added in v2.7.0

func UnaryServerInterceptor(options ...Option) grpc.UnaryServerInterceptor

UnaryServerInterceptor returns a middleware that creates datadog-spans on incoming requests, and stores them in the requests' context.

Types

type Option added in v2.7.0

type Option func(cfg *config)

Option allows for overriding our default-config.

func WithCustomTag added in v2.7.0

func WithCustomTag(key string, value any) Option

WithCustomTag will attach the value to the span tagged by the key.

func WithNonErrorCodes added in v2.7.0

func WithNonErrorCodes(cs ...codes.Code) Option

WithNonErrorCodes determines the list of codes which will not be considered errors in instrumentation. This call overrides the default handling of codes.Canceled as a non-error.

func WithServiceName added in v2.7.0

func WithServiceName(serviceName string) Option

WithServiceName overrides the service-name set in environment-variable "DD_SERVICE".

func WithUntracedMethods added in v2.7.0

func WithUntracedMethods(methods ...string) Option

WithUntracedMethods specifies full methods to be ignored by the server side and client side interceptors. When a request's full method is in 'methods', no spans will be created.

Jump to

Keyboard shortcuts

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