Open sainad2222 opened 1 day ago
👋 Thanks for opening this issue!
Get help or engage by:
/help
: to print help messages./assignme
: to assign this issue to you./assignme
The plan is to utilize
prost
andtonic
for handling proto files and generating Rust code.
Though I understand that some people might want to use gRPC, this is way too slow/heavyweight for our use case. Further, the mentioned tools currently pretty much hard-code tokio
runtime, to which we painstakingly removed the dependencies from the core.
Please ensure while doing so to put such things into a separate crate not polluting the openraft
core itself. It is not a core functionality. But, I assume, this was your plan from the beginning, right? :-)
Problem statement Currently, Openraft does not use Protocol Buffers (proto) messages; instead, it passes Rust structs for internal communication. This necessitates that anyone writing a gRPC network layer must rewrite proto files like the example found in databend's source code
Solution Openraft can have proto file and generated pb file in the repo along with From and Into trait converters that people can use in writing thier network component Example from kv-memstore: Instead of
it will look something like this
Scope and tools: The plan is to utilize
prost
andtonic
for handling proto files and generating Rust code. As I delve deeper into the codebase, I will update this section with more details.Open questions:
rust-protobuf
instead ofprost