grpcmon

package
v0.0.0-...-678bb0e Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2017 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package grpcmon defines gRPC interceptors with monitoring instrumentation.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewUnaryClientInterceptor

func NewUnaryClientInterceptor(next grpc.UnaryClientInterceptor) grpc.UnaryClientInterceptor

NewUnaryClientInterceptor returns an interceptor that gathers RPC call metrics and sends them to tsmon.

It can be optionally chained with other interceptor. The reported metrics include time spent in this other interceptor too.

Can be passed to a gRPC client via WithUnaryInterceptor(...) dial option.

Use option.WithGRPCDialOption(grpc.WithUnaryInterceptor(...)) when instrumenting Google Cloud API clients.

It assumes the RPC context has tsmon initialized already.

func NewUnaryServerInterceptor

func NewUnaryServerInterceptor(next grpc.UnaryServerInterceptor) grpc.UnaryServerInterceptor

NewUnaryServerInterceptor returns an interceptor that gathers RPC handler metrics and sends them to tsmon.

It can be optionally chained with other interceptor. The reported metrics include time spent in this other interceptor too.

It assumes the RPC context has tsmon initialized already.

Types

This section is empty.

Jump to

Keyboard shortcuts

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