-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(deps): add OTEL tracing and span logging for GRPC server (#361)
### TL;DR Removed `trace.WithNewRoot()` from OpenTelemetry span creation and added tracing to GRPC requests. ### What changed? - Removed `trace.WithNewRoot()` parameter from all `otel.Tracer(TracerName).Start()` calls across multiple files. - Added OpenTelemetry tracing to GRPC requests in the `logGRPC` function. - Updated the context in `logGRPC` to include trace and span IDs. ### How to test? 1. Run the CSI driver with OpenTelemetry tracing enabled. 2. Perform various CSI operations (e.g., CreateVolume, DeleteVolume, NodePublishVolume). 3. Verify that the traces are correctly propagated and that GRPC requests are now included in the trace. 4. Ensure that removing `trace.WithNewRoot()` doesn't negatively impact the existing tracing functionality. ### Why make this change? This change improves the tracing capabilities of the CSI driver: 1. Removing `trace.WithNewRoot()` allows for better trace continuity across operations, potentially providing more context in distributed tracing scenarios. 2. Adding tracing to GRPC requests provides more granular insights into the communication between components, helping with debugging and performance analysis. These improvements will enhance observability and make it easier to diagnose issues in production environments.
- Loading branch information
Showing
4 changed files
with
16 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters