Documentation
¶
Index ¶
- Constants
- func ContextWithTraceParent(ctx context.Context, traceparent string) context.Context
- func EndSpan(span trace.Span, err error)
- func NameRPCSpan(system, service, method string) (string, []attribute.KeyValue)
- func NewBaseTransport() *http.Transport
- func NewClient(timeout time.Duration) *http.Client
- func NewCollectorProxy(c Collector) (http.Handler, error)
- func NewTransport(base http.RoundTripper) http.RoundTripper
- func ParentEnv(ctx context.Context) []string
- func RedactText(s string) string
- func RouteTrace(id trace.TraceID, provider trace.TracerProvider) (remove func())
- func SetCollector(c Collector)
- func StepSpanID(call trace.SpanID, step []byte) trace.SpanID
- func TraceParent(ctx context.Context) string
- type Cmd
- func (c *Cmd) CombinedOutput() ([]byte, error)
- func (c *Cmd) IsExportingSpans() bool
- func (c *Cmd) Output() ([]byte, error)
- func (c *Cmd) Run() error
- func (c *Cmd) SetAttributes(attrs ...attribute.KeyValue)
- func (c *Cmd) Start() error
- func (c *Cmd) StderrPipe() (io.ReadCloser, error)
- func (c *Cmd) StdoutPipe() (io.ReadCloser, error)
- func (c *Cmd) Wait() error
- type Collector
- type Mode
- type SecretValues
- type Tail
- type Transport
Constants ¶
View Source
const ( CollectorURLEnvVar = "OCEL_TRACE_COLLECTOR_URL" CollectorTokenEnvVar = "OCEL_TRACE_COLLECTOR_TOKEN" CollectorPath = "/v1/traces" CollectorMediaType = "application/x-protobuf" )
View Source
const ( ExecutablePathKey attribute.Key = "process.executable.path" CommandArgsKey attribute.Key = "process.command_args" CommandLineKey attribute.Key = "process.command_line" WorkingDirectoryKey attribute.Key = "process.working_directory" PIDKey attribute.Key = "process.pid" ExitCodeKey attribute.Key = "process.exit.code" StdoutTailKey attribute.Key = "process.stdout.tail" StderrTailKey attribute.Key = "process.stderr.tail" StdinBytesKey attribute.Key = "process.stdin.bytes" )
View Source
const ModeEnvVar = "OCEL_TRACE"
View Source
const Redacted = "[secret]"
View Source
const Scope = "github.com/ocelhq/ocel/pkg/tracing"
View Source
const TailBytes = 8 << 10
View Source
const TraceParentEnvVar = "TRACEPARENT"
Variables ¶
This section is empty.
Functions ¶
func ContextWithTraceParent ¶
func NewBaseTransport ¶
func NewTransport ¶
func NewTransport(base http.RoundTripper) http.RoundTripper
func RedactText ¶
func RouteTrace ¶
func RouteTrace(id trace.TraceID, provider trace.TracerProvider) (remove func())
func SetCollector ¶
func SetCollector(c Collector)
func TraceParent ¶
Types ¶
type Cmd ¶
func (*Cmd) CombinedOutput ¶
func (*Cmd) IsExportingSpans ¶
func (*Cmd) SetAttributes ¶
func (*Cmd) StderrPipe ¶
func (c *Cmd) StderrPipe() (io.ReadCloser, error)
func (*Cmd) StdoutPipe ¶
func (c *Cmd) StdoutPipe() (io.ReadCloser, error)
type Collector ¶
func ReadCollector ¶
func ReadCollector() Collector
type SecretValues ¶
type SecretValues struct {
// contains filtered or unexported fields
}
func (*SecretValues) Add ¶
func (s *SecretValues) Add(values ...string)
func (*SecretValues) RedactAttributes ¶
func (s *SecretValues) RedactAttributes(attrs []attribute.KeyValue) []attribute.KeyValue
func (*SecretValues) RedactText ¶
func (s *SecretValues) RedactText(text string) string
type Tail ¶
type Tail struct {
Limit int
// contains filtered or unexported fields
}
func (*Tail) WholeLines ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.