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

ISSUE-3605: Replace arrow flight with gRPC #3606

Merged
merged 19 commits into from Dec 30, 2021

Conversation

ariesdevil
Copy link
Member

@ariesdevil ariesdevil commented Dec 22, 2021

I hereby agree to the terms of the CLA available at: https://databend.rs/dev/policies/cla/

Summary

Replace arrow flight with gRPC

Changelog

  • Improvement

Related Issues

Fixes #3605

Test Plan

Unit Tests

Stateless Tests

@databend-bot
Copy link
Member

Thanks for the contribution!
I have applied any labels matching special text in your PR Changelog.

Please review the labels and make any necessary changes.

@vercel
Copy link

vercel bot commented Dec 22, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/databend/databend/EkBEd7STmjW79WZYdpyTic3Ld177
✅ Preview: Canceled

[Deployment for d4e6cec canceled]

Copy link
Member

@drmingdrmer drmingdrmer left a comment

Choose a reason for hiding this comment

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

not bad~

common/flight-rpc/src/dns_resolver.rs Outdated Show resolved Hide resolved
common/meta/raft-store/src/grpc/grpc_action.rs Outdated Show resolved Hide resolved
common/meta/raft-store/src/grpc/grpc_action.rs Outdated Show resolved Hide resolved
@mergify
Copy link
Contributor

mergify bot commented Dec 24, 2021

This pull request has merge conflicts that must be resolved before it can be merged. @ariesdevil please rebase it 🙏

@codecov-commenter
Copy link

codecov-commenter commented Dec 29, 2021

Codecov Report

Merging #3606 (d4e6cec) into main (a2529db) will increase coverage by 0%.
The diff coverage is 66%.

Impacted file tree graph

@@          Coverage Diff           @@
##            main   #3606    +/-   ##
======================================
  Coverage     60%     60%            
======================================
  Files        706     707     +1     
  Lines      37901   38003   +102     
======================================
+ Hits       22806   22891    +85     
- Misses     15095   15112    +17     
Impacted Files Coverage Δ
common/meta/raft-store/src/grpc/grpc_client.rs 0% <0%> (ø)
...ommon/meta/raft-store/src/grpc/grpc_client_conf.rs 0% <0%> (ø)
common/meta/raft-store/src/state_machine/sm.rs 97% <ø> (ø)
common/meta/types/src/applied_state.rs 50% <ø> (ø)
common/meta/types/src/message.rs 95% <ø> (ø)
metasrv/src/executor/meta_handlers.rs 81% <ø> (ø)
metasrv/src/meta_service/meta_leader.rs 82% <ø> (ø)
metasrv/src/meta_service/meta_node_kv_api_impl.rs 86% <ø> (ø)
metasrv/src/meta_service/meta_service_impl.rs 92% <ø> (ø)
metasrv/src/meta_service/raftmeta.rs 47% <ø> (+<1%) ⬆️
... and 32 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a2529db...d4e6cec. Read the comment docs.

@ariesdevil ariesdevil marked this pull request as ready for review December 30, 2021 05:45
Copy link
Member

@drmingdrmer drmingdrmer left a comment

Choose a reason for hiding this comment

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

Looks gorgeous to me

common/meta/types/src/message.rs Outdated Show resolved Hide resolved

// message
rpc WriteMsg(RaftRequest) returns (RaftReply);
rpc ReadMsg(GetReq) returns (GetReply);
Copy link
Member

Choose a reason for hiding this comment

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

Rename GetReq to GetRequest in next PR? 🤔

Comment on lines +135 to +141
let body = self.action_handler.execute_read(action).await?;
let r = GetReply {
ok: true,
key: "".to_string(),
value: body,
};
Ok(Response::new(r))
Copy link
Member

Choose a reason for hiding this comment

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

If key is not used at all, we could refine GetReply in next PR. :DDD

common/meta/raft-store/tests/it/grpc/grpc_server.rs Outdated Show resolved Hide resolved
common/meta/raft-store/tests/it/grpc/grpc_client.rs Outdated Show resolved Hide resolved
common/meta/raft-store/tests/it/grpc/grpc_client.rs Outdated Show resolved Hide resolved
Copy link
Member

@drmingdrmer drmingdrmer left a comment

Choose a reason for hiding this comment

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

Nice fix up

@databend-bot
Copy link
Member

CI Passed
Reviewers Approved
Let's Merge
Thank you for the PR @ariesdevil

@databend-bot databend-bot merged commit f6f21c0 into datafuselabs:main Dec 30, 2021
@ariesdevil ariesdevil deleted the r-replace-arrow-flight branch December 30, 2021 11:19
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.

[metasrv] replace arrow flight service with gRPC for metasrv
5 participants