tracing

package module
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

README

tracing

A tracing library which integrates opentelemetry and GCP cloud tracing

Documentation

Overview

Package tracing provides handy helper functions for measuring API performance and debugging.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Finalize

func Finalize(ctx context.Context)

Finalize cleanup tracing

func Initialize

func Initialize(ctx context.Context, c *Config) error

Initialize setup for tracing

func Start

func Start(ctx context.Context, name string) trace.Span

Start creates a new span for a given name

Types

type Config

type Config struct {
	ProjectID             string `json:"project_id" yaml:"project_id"`
	TracerName            string `json:"tracer_name" yaml:"tracer_name"`
	ServiceName           string `json:"service_name" yaml:"service_name"`
	DeploymentEnvironment string `json:"deployment_environment" yaml:"deployment_environment"`
	TimeoutInSeconds      int64  `json:"timeout_in_seconds" yaml:"timeout_in_seconds"`
}

Config provides customization of tracing

Jump to

Keyboard shortcuts

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