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

fix: carry dbname from frontend to datanode #2520

Merged
merged 6 commits into from
Oct 8, 2023

Conversation

shuiyisong
Copy link
Contributor

@shuiyisong shuiyisong commented Sep 28, 2023

I hereby agree to the terms of the GreptimeDB CLA

What's changed and what's your intention?

We introduced region server since v0.4, which changed the api between frontend and datanode. This pr mainly fixes losing dbname from frontend to datanode.

  1. remove span_id in self.do_request signature since its all 0 now. We should use span_id in ctx if later come into usage.
  2. use dbname in task context within datafusion instead of trace_id. trace_id is now retrieved using task local.
  3. add back write_meter for logging inserts.

TODO:

Checklist

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

Refer to a related PR or issue link (optional)

@shuiyisong shuiyisong marked this pull request as ready for review October 7, 2023 08:29
@codecov
Copy link

codecov bot commented Oct 7, 2023

Codecov Report

Merging #2520 (81bd8dc) into develop (fe783c7) will decrease coverage by 0.35%.
Report is 2 commits behind head on develop.
The diff coverage is 94.00%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #2520      +/-   ##
===========================================
- Coverage    85.32%   84.98%   -0.35%     
===========================================
  Files          730      730              
  Lines       116311   116520     +209     
===========================================
- Hits         99240    99020     -220     
- Misses       17071    17500     +429     

Copy link
Member

@waynexia waynexia left a comment

Choose a reason for hiding this comment

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

LGTM

@zhongzc zhongzc added this pull request to the merge queue Oct 8, 2023
Merged via the queue into GreptimeTeam:develop with commit 0679178 Oct 8, 2023
@shuiyisong shuiyisong deleted the fix/dbname_in_region branch October 8, 2023 07:01
paomian pushed a commit to paomian/greptimedb that referenced this pull request Oct 19, 2023
* chore: add dbname in region request header for tracking purpose

* chore: fix handle read

* chore: add write meter

* chore: add meter-core to dep

* chore: add converter between RegionRequestHeader and QueryContext & update proto version
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.

4 participants