Important
This is a work in progress and not ready for production use. 🚨
This project provides a tool to automatically instrument Go applications with OpenTelemetry at compile-time. It modifies the Go build process to inject OpenTelemetry code into the application without requiring manual changes to the source code.
Highlights:
- Zero Runtime Overhead - Instrumentation is baked into your binary at compile time
- Zero Code Changes - Automatically instrument entire applications and dependencies
- Third-Party Library Support - Instrument libraries you don't control
- Complete Decoupling - Keep your codebase free from instrumentation concerns
- Flexible Deployment - Integrate at development time or in your CI/CD pipeline
git clone https://github.com/open-telemetry/opentelemetry-go-compile-instrumentation.git
cd opentelemetry-go-compile-instrumentation
make buildThe otelc binary will be built in the root directory.
Just prefix the original go build command with otelc.
cd demo/app/basic
../../otelc go build
./basic
[... output ...]make test- Getting Started Guide - Setup and usage
- UX Design - Configuration options
- Implementation Details - Technical architecture
- API Design - API structure
- Semantic Conventions - Managing semantic conventions
- Instrumentation Guide - Add instrumentation hook for new libraries
- Instrumentation Rules - Rule types and YAML format reference
- Testing - Testing strategy, categories, and how to run tests
- GitHub Discussions - Ask questions
- GitHub Issues - Report bugs
- Slack Channel - Real-time chat
We welcome contributions! See our contributing guide and development docs.
This project follows the OpenTelemetry Code of Conduct. Please also review our AI usage policy if you use AI tools in your workflow.
