traceclient

package
v0.0.0-...-52cecf4 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitTraceContext

func InitTraceContext(ctx context.Context) context.Context

Types

type AcquiredConnection

type AcquiredConnection struct {
	Time     time.Time
	IdleTime time.Duration
	Reused   bool
	WasIdle  bool
}

type ClientTrace

type ClientTrace struct {
	ConnectionGet      *GetConnection
	ConnectionAcquired *AcquiredConnection
}

func GetClientTraceFromContext

func GetClientTraceFromContext(ctx context.Context) *ClientTrace

type ClientTraceContextKey

type ClientTraceContextKey struct{}

type GetConnection

type GetConnection struct {
	Time     time.Time
	HostPort string
}

type TraceInjectingRoundTripper

type TraceInjectingRoundTripper struct {
	// contains filtered or unexported fields
}

func NewTraceInjectingRoundTripper

func NewTraceInjectingRoundTripper(
	base http.RoundTripper,
	connectionMetricStore metric.ConnectionMetricStore,
	reqContextValuesGetter func(ctx context.Context, req *http.Request) (*expr.Context, string),
) *TraceInjectingRoundTripper

func (*TraceInjectingRoundTripper) RoundTrip

func (t *TraceInjectingRoundTripper) RoundTrip(req *http.Request) (*http.Response, error)

Jump to

Keyboard shortcuts

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