feat(otel): add OTLP/gRPC export support#247
Conversation
Honour OTEL_EXPORTER_OTLP_PROTOCOL so traces and logs can be exported over gRPC as well as OTLP/HTTP, fixing self-hosted deployments that point at gRPC-only collectors. Refs Flagsmith/flagsmith#7812 Co-authored-by: Cursor <cursoragent@cursor.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (6)
📝 WalkthroughWalkthroughAdds OTLP gRPC transport support alongside the existing HTTP transport in OpenTelemetry setup. Endpoint resolution and provider construction now use the configured protocol, with Estimated code review effort: 3 (Moderate) | ~25 minutes Comment |
Co-authored-by: Cursor <cursoragent@cursor.com>
|
@khvn26 Thanks for your review, I've pushed some updates which handle your requested changes |
khvn26
left a comment
There was a problem hiding this comment.
LGTM with two nitpicks — feel free to address them if you like.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #247 +/- ##
==========================================
+ Coverage 97.56% 97.58% +0.02%
==========================================
Files 108 109 +1
Lines 4757 4802 +45
==========================================
+ Hits 4641 4686 +45
Misses 116 116 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…le and update imports
@khvn26 Thanks! I made some minor adjustments |
Summary
OTEL_EXPORTER_OTLP_PROTOCOLwhen configuring OTLP trace and log exportopentelemetry-exporter-otlp-proto-grpcto theotelextra and select gRPC exporters whenOTEL_EXPORTER_OTLP_PROTOCOL=grpc/v1/tracesand/v1/logs; gRPC uses the base collector URL)Fixes Flagsmith/flagsmith#7812