Enhance OpenTelemetry with pinpointed code-level observability for Golang.
Baz on GitHub »
Install
go get github.com/baz-scm/falken-trace-go
Falken Trace extends OpenTelemetry and Datadog for Go by pinpointing file names, function names, and line numbers that generate spans. It addresses gaps in default observability implementations, making tracing faster and more actionable.
Discovered while building Baz, Falken Trace streamlines debugging and enhances insights into codebase behaviors.
go get github.com/baz-scm/falken-trace-go
Just replace the tracer.StartSpanFromContext
calls with falken.StartSpanFromContext
.
import (
"context"
- "gopkg.in/DataDog/dd-trace-go.v1/ddtrace/tracer"
+ falken "github.com/baz-scm/falken-trace-go/tracing/datadog"
)
func doSomething(ctx context.Context) {
- span, _ := tracer.StartSpanFromContext(ctx, "doSomething")
+ span, _ := falken.StartSpanFromContext(ctx, "doSomething")
defer span.Finish()
...
}
Just replace the otel.Tracer
calls with falken.Tracer
.
import (
"context"
- "go.opentelemetry.io/otel"
+ falken "github.com/baz-scm/falken-trace-go/tracing/opentelemetry"
)
var (
- tracer = otel.Tracer("tracer")
+ tracer = falken.Tracer("tracer")
)
func doSomething(ctx context.Context) {
_, span := falken.Start(ctx, "doSomething")
defer span.End()
...
}
Python library: https://github.com/baz-scm/falken-trace-py
Blog post: Extending OpenTelemetry to Pinpoint Code Elements