OpenTelemetry Migration
This guide covers migrating from existing OpenTelemetry setups to LangWatch while maintaining all your custom configurations, instrumentations, and advanced features.Configuration Migration
Preserve all your OpenTelemetry NodeSDK configuration options and custom settings.
Migration Checklist
Step-by-step process to safely migrate your observability setup.
Overview
The LangWatch observability SDK is built on OpenTelemetry and passes through all NodeSDK configuration options, making it easy to migrate from existing OpenTelemetry setups while maintaining all your custom configuration.LangWatch supports all OpenTelemetry NodeSDK configuration options, so you can migrate without losing any functionality or custom settings.
For consistent attribute naming and semantic conventions, see our Semantic Conventions guide which covers both OpenTelemetry standards and LangWatch’s custom attributes.
Complete NodeSDK Configuration
LangWatch supports all OpenTelemetry NodeSDK configuration options:Migration Example: From NodeSDK to LangWatch
1
Before: Direct NodeSDK Usage
2
After: Using LangWatch with Same Configuration
Advanced Sampling Strategies
Implement sophisticated sampling strategies for different use cases:Custom Resource Detection
Configure custom resource detection for better service identification:Custom Instrumentations
Add custom instrumentations for specific libraries or frameworks:Context Propagation Configuration
Configure custom context propagation for distributed tracing:Environment-Specific Configuration
Create different configurations for different environments:Performance Tuning
Optimize performance for high-volume applications:Migration Checklist
1
Inventory Current Setup
Document all current instrumentations, exporters, and configurations in your OpenTelemetry setup.
2
Test in Development
Start with development environment migration to validate the configuration.
3
Verify Data Flow
Ensure traces are appearing in LangWatch dashboard with correct attributes and structure.
4
Performance Testing
Monitor application performance impact and adjust sampling/processing settings as needed.
5
Gradual Rollout
Migrate environments one at a time, starting with staging before production.
6
Fallback Plan
Keep existing OpenTelemetry setup as backup during transition period.
7
Documentation
Update team documentation and runbooks with new observability configuration.
Troubleshooting Migration Issues
Common Migration Problems
Duplicate Spans
Duplicate Spans
Problem: Spans appearing twice in your traces.Solution: Ensure only one observability setup is running. Check for multiple
setupObservability calls or conflicting OpenTelemetry initializations.Missing Traces
Missing Traces
Problem: No traces appearing in LangWatch dashboard.Solution: Verify API key configuration, check network connectivity to LangWatch endpoints, and ensure spans are being created and ended properly.
Performance Degradation
Performance Degradation
Problem: Application performance impacted after migration.Solution: Adjust sampling rates, optimize batch processing settings, and monitor memory usage of span processors.
Context Loss
Context Loss
Problem: Span context not propagating across async boundaries.Solution: Verify context propagation configuration and ensure proper async context management in your code.
Instrumentation Conflicts
Instrumentation Conflicts
Problem: Conflicting instrumentations causing errors or unexpected behavior.Solution: Review instrumentation configuration, check for duplicate instrumentations, and verify compatibility between different instrumentations.
Debugging Migration
Enable detailed logging during migration to identify issues:Migration Benefits
Zero Configuration Loss
All your existing OpenTelemetry configurations, instrumentations, and custom settings are preserved.
Enhanced Features
Gain access to LangWatch’s specialized LLM observability features while keeping your existing setup.
Gradual Migration
Migrate at your own pace with the ability to run both systems in parallel during transition.
Production Ready
LangWatch is built on OpenTelemetry standards, ensuring production-grade reliability and performance.
The migration process is designed to be non-disruptive. You can run your existing OpenTelemetry setup alongside LangWatch during the transition period to ensure everything works correctly.