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

pass down tracing context for region requests #4670

Open
lyang24 opened this issue Sep 4, 2024 · 2 comments
Open

pass down tracing context for region requests #4670

lyang24 opened this issue Sep 4, 2024 · 2 comments
Labels
C-enhancement Category Enhancements

Comments

@lyang24
Copy link
Contributor

lyang24 commented Sep 4, 2024

What type of enhancement is this?

API improvement

What does the enhancement do?

Mito Engine spawns regional worker to handle request in another thread with a loop. The trace span is not continuous with current impl.

The goal of this issues is to pass down ctx with requests defined in src/store-api/src/region_request.rs so tracing spans are continious.

examples of fragmented spans:
This is the main span with write requests
image
Ideally when we adding more tracing to the write path on mito engine level the spans should be attached the above trace.
Today the new spans are separated from main trace.
image

Implementation challenges

No response

@lyang24 lyang24 added the C-enhancement Category Enhancements label Sep 4, 2024
@killme2008
Copy link
Contributor

@evenyag LGTM. What do you think?

@evenyag
Copy link
Contributor

evenyag commented Sep 6, 2024

Adding this to the request should be helpful for troubleshooting. We can add a header struct to the request like our gRPC request.
https://github.com/GreptimeTeam/greptime-proto/blob/c437b55725b7f5224fe9d46db21072b4a682ee4b/proto/greptime/v1/common.proto#L31-L45

The region request header mainly contains the tracing context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category Enhancements
Projects
None yet
Development

No branches or pull requests

3 participants