Documentation ¶
Index ¶
- Constants
- func EndAndRecord(span trace.Span, err error)
- func GetWorkload(c context.Context, name, namespace, workloadKind string) (obj k8sapi.Workload, err error)
- func GetWorkloadFromCache(ctx context.Context, workloadCache map[string]k8sapi.Workload, ...) (k8sapi.Workload, error)
- func NewWrapperFunc() transport.WrapperFunc
- func RecordInterceptInfo(span trace.Span, info *manager.InterceptInfo)
- func RecordInterceptSpec(span trace.Span, spec *manager.InterceptSpec)
- func RecordWorkloadInfo(span trace.Span, wl k8sapi.Workload)
- type ProtoReader
- type ProtoWriter
- type TraceServer
Constants ¶
View Source
const MaxTraceSize = 10 * 1024 * 1024 // 10 MB
Variables ¶
This section is empty.
Functions ¶
func EndAndRecord ¶ added in v2.7.2
func GetWorkload ¶ added in v2.9.4
func GetWorkload(c context.Context, name, namespace, workloadKind string) (obj k8sapi.Workload, err error)
GetWorkload returns a workload for the given name, namespace, and workloadKind. The workloadKind is optional. A search is performed in the following order if it is empty:
- Deployments
- ReplicaSets
- StatefulSets
The first match is returned.
func GetWorkloadFromCache ¶ added in v2.13.0
func NewWrapperFunc ¶ added in v2.7.2
func NewWrapperFunc() transport.WrapperFunc
This code is modified from https://github.com/signalfx/splunk-otel-go/blob/main/instrumentation/k8s.io/client-go/splunkclient-go/transport/transport.go which is licensed under Apache 2.0 NewWrapperFunc returns a Kubernetes WrapperFunc that can be used with a client configuration to trace all communication the client makes.
func RecordInterceptInfo ¶
func RecordInterceptInfo(span trace.Span, info *manager.InterceptInfo)
func RecordInterceptSpec ¶
func RecordInterceptSpec(span trace.Span, spec *manager.InterceptSpec)
Types ¶
type ProtoReader ¶
func NewProtoReader ¶
func NewProtoReader[T proto.Message](in io.Reader, allocator func() T) *ProtoReader[T]
type ProtoWriter ¶
type ProtoWriter struct {
// contains filtered or unexported fields
}
func NewProtoWriter ¶
func NewProtoWriter(out io.Writer) *ProtoWriter
func (*ProtoWriter) SetWriter ¶
func (p *ProtoWriter) SetWriter(out io.Writer)
type TraceServer ¶
type TraceServer struct { common.UnimplementedTracingServer // contains filtered or unexported fields }
func NewTraceServer ¶
func (*TraceServer) DumpTraces ¶
func (*TraceServer) ServeGrpc ¶
func (ts *TraceServer) ServeGrpc(ctx context.Context, port uint16) error
func (*TraceServer) Shutdown ¶
func (ts *TraceServer) Shutdown(ctx context.Context)
Click to show internal directories.
Click to hide internal directories.