google.golang.org/grpc
The Go implementation of gRPC.
Add gRPC client interceptors
One of
- Call to
google.golang.org/grpc
.Dial
Append the following
google.golang.org/grpc.DialOption
arguments to the function call:// Using the following synthetic imports: import ( grpc "google.golang.org/grpc" grpctrace "gopkg.in/DataDog/dd-trace-go.v1/contrib/google.golang.org/grpc" )
grpc.WithStreamInterceptor(grpctrace.StreamClientInterceptor())
// Using the following synthetic imports: import ( grpc "google.golang.org/grpc" grpctrace "gopkg.in/DataDog/dd-trace-go.v1/contrib/google.golang.org/grpc" )
grpc.WithUnaryInterceptor(grpctrace.UnaryClientInterceptor())
Add gRPC server interceptors
Append the following
google.golang.org/grpc.ServerOption
arguments to the function call:// Using the following synthetic imports: import ( grpc "google.golang.org/grpc" grpctrace "gopkg.in/DataDog/dd-trace-go.v1/contrib/google.golang.org/grpc" )
grpc.StreamInterceptor(grpctrace.StreamServerInterceptor())
// Using the following synthetic imports: import ( grpc "google.golang.org/grpc" grpctrace "gopkg.in/DataDog/dd-trace-go.v1/contrib/google.golang.org/grpc" )
grpc.UnaryInterceptor(grpctrace.UnaryServerInterceptor())