-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add gRPC support to FDB #11782
base: main
Are you sure you want to change the base?
Add gRPC support to FDB #11782
Conversation
This patch adds `collect_unit_tests()` to CMake which searches over the codebase and finds all the unit-tests written using Flow's TEST_CASE macro and register as ctest. The test then can be then run using ctest command or directly via Test Explorer in VSCode.
Result of foundationdb-pr on Linux CentOS 7
|
Result of foundationdb-pr-clang-arm on Linux CentOS 7
|
Result of foundationdb-pr-clang on Linux CentOS 7
|
Result of foundationdb-pr-clang-ide on Linux CentOS 7
|
Result of foundationdb-pr-cluster-tests on Linux CentOS 7
|
Result of foundationdb-pr-macos-m1 on macOS Ventura 13.x
|
Result of foundationdb-pr-macos on macOS Ventura 13.x
|
|
||
void GrpcServer::registerService(std::shared_ptr<grpc::Service> service) { | ||
registered_services_.push_back(service); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No ACTOR in here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure why it would be actor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure why it would be actor?
Because the file name is FlowGrpc.actor.cpp. So I was thinking that some methods would have the ACTOR qualification in a file named FlowGrpc.actor.cpp?
namespace asio = boost::asio; | ||
|
||
TEST_CASE("/fdbrpc/grpc/basic_sync_client") { | ||
state NetworkAddress addr(NetworkAddress::parse("127.0.0.1:50001")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test will fail if this port is already occupied?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. I have make some sort of getFreePort()
function. Currently, I'm just making sure each test has different port.
return Void(); | ||
} | ||
|
||
} // namespace fdbrpc_test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any flow in here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing that uses flow compiler. Just Flow/c++ coroutine integration stuff.
message DownloadChunk { | ||
int32 offset = 2; | ||
bytes data = 3; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a proto for file transfer already? Perhaps up in the google cloud repos? There are probably some proto smarts we could 'borrow' -- stuff folks have worked out already around file transfer problem.
This PR gRPC server along with Flow with goal of supporting new/specific features but not entirely replacing FlowRPC itself.
Code-Reviewer Section
The general pull request guidelines can be found here.
Please check each of the following things and check all boxes before accepting a PR.
For Release-Branches
If this PR is made against a release-branch, please also check the following:
release-branch
ormain
if this is the youngest branch)