internal

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2019 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

AllViews has the views for the metrics provided by the agent.

View Source
var ViewExportedSpans = &view.View{
	Name:        "oc.io/receiver/exported_spans",
	Description: "Tracks the number of exported spans",
	Measure:     mExportedSpans,
	Aggregation: itemsDistribution,
	TagKeys:     []tag.Key{tagKeyExporterName},
}

ViewExportedSpans defines the view for exported spans metric.

View Source
var ViewReceivedSpansReceiver = &view.View{
	Name:        "oc.io/receiver/received_spans",
	Description: "The number of spans received by the receiver",
	Measure:     mReceivedSpans,
	Aggregation: itemsDistribution,
	TagKeys:     []tag.Key{tagKeyReceiverName},
}

ViewReceivedSpansReceiver defines the view for the received spans metric.

Functions

func CombineErrors added in v0.0.3

func CombineErrors(errs []error) error

CombineErrors converts a list of errors into one error.

func ContextWithReceiverName added in v0.0.2

func ContextWithReceiverName(ctx context.Context, receiverName string) context.Context

ContextWithReceiverName adds the tag "opencensus_receiver" and the name of the receiver as the value, and returns the newly created context.

func GRPCServerWithObservabilityEnabled

func GRPCServerWithObservabilityEnabled(extraOpts ...grpc.ServerOption) *grpc.Server

GRPCServerWithObservabilityEnabled creates a gRPC server that at a bare minimum has the OpenCensus ocgrpc server stats handler enabled for tracing and stats. Use it instead of invoking grpc.NewServer directly.

func NewExportedSpansRecorder

func NewExportedSpansRecorder(exporterName string) func(context.Context, *commonpb.Node, []*tracepb.Span)

NewExportedSpansRecorder creates a helper function that'll add the name of the creating exporter as a tag value in the context that will be used to count the the number of spans exported.

func NewReceivedSpansRecorderStreaming

func NewReceivedSpansRecorderStreaming(lifetimeCtx context.Context, receiverName string) func(*commonpb.Node, []*tracepb.Span)

NewReceivedSpansRecorderStreaming creates a function that uses a context created from the name of the receiver to record the number of the spans received by the receiver.

func SetParentLink(sideCtx context.Context, span *trace.Span) bool

SetParentLink tries to retrieve a span from sideCtx and if one exists sets its SpanID, TraceID as a link in the span provided. It returns true only if it retrieved a parent span from the context.

func TimeToTimestamp

func TimeToTimestamp(t time.Time) *timestamp.Timestamp

TimeToTimestamp converts a time.Time to a timestamp.Timestamp pointer.

Types

type Service

type Service struct {
	Endpoint string `json:"endpoint"`
}

Service contains metadata about the exporter service.

func ParseEndpointFile

func ParseEndpointFile() (*Service, error)

ParseEndpointFile reads and parses the canonical endpoint file for metadata.

func (*Service) WriteToEndpointFile

func (s *Service) WriteToEndpointFile() (path string, err error)

WriteToEndpointFile writes service metadata to canonical endpoint file.

Directories

Path Synopsis
collector
jaeger
Package jaegerreceiver wraps the functionality to start the end-point that receives Jaeger data sent by the jaeger-agent in jaeger.thrift format over TChannel and directly from clients in jaeger.thrift format over binary thrift protocol (HTTP transport).
Package jaegerreceiver wraps the functionality to start the end-point that receives Jaeger data sent by the jaeger-agent in jaeger.thrift format over TChannel and directly from clients in jaeger.thrift format over binary thrift protocol (HTTP transport).
opencensus
Package ocreceiver wraps the functionality to start the end-point that receives data directly in the OpenCensus format.
Package ocreceiver wraps the functionality to start the end-point that receives data directly in the OpenCensus format.
processor
Package processor is the central point on the collector processing: it aggregates and performs any operation that applies to all traces in the pipeline.
Package processor is the central point on the collector processing: it aggregates and performs any operation that applies to all traces in the pipeline.
processor/idbatcher
Package idbatcher defines a pipeline of fixed size in which the elements are batches of ids.
Package idbatcher defines a pipeline of fixed size in which the elements are batches of ids.
telemetry
Package telemetry controls the telemetry settings to be used in the collector.
Package telemetry controls the telemetry settings to be used in the collector.
zipkin
Package zipkinreceiver wraps the functionality to start the end-point that receives Zipkin traces.
Package zipkinreceiver wraps the functionality to start the end-point that receives Zipkin traces.

Jump to

Keyboard shortcuts

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