Documentation ¶
Overview ¶
Package telemetry provides functionality for tracing with AWS X-Ray and logging information related to the current web request.
Index ¶
- func AppendMiddlewares(list *[]func(*middleware.Stack) error)
- func NewSlogHandler(h slog.Handler) slog.Handler
- func Setup(ctx context.Context, resource *resource.Resource, ...) (func(context.Context) error, error)
- func SetupLambda(ctx context.Context, apiOptions *[]func(*middleware.Stack) error) (*sdktrace.TracerProvider, error)
- func WrapHandler(handler http.Handler) http.HandlerFunc
- type CloudwatchClient
- type MetricsClient
- type SlogHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AppendMiddlewares ¶ added in v0.1506.0
func AppendMiddlewares(list *[]func(*middleware.Stack) error)
func SetupLambda ¶ added in v0.1512.0
func SetupLambda(ctx context.Context, apiOptions *[]func(*middleware.Stack) error) (*sdktrace.TracerProvider, error)
SetupLambda requires an ADOT collector lambda extension to be included in the deployed lambda image for the below instrumentation to work
func WrapHandler ¶
func WrapHandler(handler http.Handler) http.HandlerFunc
Types ¶
type CloudwatchClient ¶ added in v0.1561.0
type CloudwatchClient interface {
PutMetricData(ctx context.Context, params *cloudwatch.PutMetricDataInput, optFns ...func(*cloudwatch.Options)) (*cloudwatch.PutMetricDataOutput, error)
}
type MetricsClient ¶ added in v0.1561.0
type MetricsClient struct {
// contains filtered or unexported fields
}
func NewMetricsClient ¶ added in v0.1561.0
func NewMetricsClient(cloudwatchClient CloudwatchClient, versionTag string) *MetricsClient
func (*MetricsClient) PutMetrics ¶ added in v0.1561.0
func (c *MetricsClient) PutMetrics(ctx context.Context, input *cloudwatch.PutMetricDataInput) error
type SlogHandler ¶ added in v0.1178.0
type SlogHandler struct {
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.