Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP]Redesign Tracing and Transport Middleware for Enhanced Observability and Extensibility #2302

Open
wants to merge 5 commits into
base: dev-tracing-fix
Choose a base branch
from

Conversation

kexiongliu123
Copy link

@kexiongliu123 kexiongliu123 commented Oct 7, 2024

This PR introduces a high-level redesign of the tracing and transport middleware systems, focusing on enhancing observability, error handling, and extendability in YARPC. The key components included in this redesign are:

  1. Tracing Interceptor Introduction:

Implemented a comprehensive tracing interceptor (tracinginterceptor) that supports tracing across all RPC types (Unary, Oneway, and Stream).
The interceptor ensures accurate span creation, propagation, and error annotation across inbound and outbound RPC calls.

  1. Transport Middleware Overhaul:

Introduced transportinterceptor, encompassing both inbound and outbound middleware (UnaryInbound, OnewayInbound, StreamInbound, UnaryOutbound, OnewayOutbound, StreamOutbound).
This new middleware layer enhances the flexibility and maintainability of transport handling by separating concerns for different RPC types.

  1. Enhanced Tagging and Error Annotation:

Unified and extended tracing tag management to capture key metadata and error details for all types of RPC interactions.
Refined the mechanism for capturing and reporting application errors, ensuring consistency across spans for improved trace analysis.

  1. Unit Testing and Coverage:

Introduced unit tests for the new tracing and transport middleware components, ensuring robustness and validating the functionality of inbound, outbound, and tracing interceptors.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

)

// ExtractTracingTags extracts common tracing tags from a transport request.
func ExtractTracingTags(req *transport.Request) opentracing.Tags {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may worth further discussion to determine the best location as well as avoid dup

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants