Skip to content

feat: add TraceID and SpanID in request header#59

Merged
waynexia merged 2 commits intomainfrom
add-header
Jul 11, 2023
Merged

feat: add TraceID and SpanID in request header#59
waynexia merged 2 commits intomainfrom
add-header

Conversation

@waynexia
Copy link
Copy Markdown
Member

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

Add TraceID and SpanID in the request header as distributed context. Related to GreptimeTeam/greptimedb#1312

The opentelemetry protocol definition is at https://opentelemetry.io/docs/specs/otel/trace/api/#spancontext. From its spec, trace id's max type is uint128. But it's not supported in protobuf (doc). Thus I fallback to uint64 instead.

Checklist

  • I have written the necessary comments.
  • I have added the necessary unit tests and integration tests.

Refer to a related PR or issue link (optional)

Signed-off-by: Ruihang Xia <waynestxia@gmail.com>
@waynexia waynexia requested review from shuiyisong and v0y4g3r July 11, 2023 07:15
@shuiyisong shuiyisong requested a review from sunng87 July 11, 2023 07:19
Copy link
Copy Markdown
Contributor

@shuiyisong shuiyisong left a comment

Choose a reason for hiding this comment

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

LGTM
note: run make all before commit and push 😏

@waynexia
Copy link
Copy Markdown
Member Author

LGTM note: run make all before commit and push 😏

I'm currently on a temporary env 😖 All I can do is begging to the make suparman @evenyag to make it for me

@waynexia waynexia enabled auto-merge (squash) July 11, 2023 07:33
@waynexia waynexia merged commit 53d0a7c into main Jul 11, 2023
@waynexia waynexia deleted the add-header branch July 11, 2023 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants