Rundler utilizes gRPC for communication between modules while running in distributed mode. Refer to this document for best practices when utilizing protocol buffers in gRPC.
Rundler builds on Tonic to power lightning quick gRPC interfaces between internal components. To re-compile changes to the protocol buffers:
- Make sure
protoc
is installed locally. On Macs one can runbrew install protobuf
. Otherwise see the official protobuf docs for installation instructions. - Run
cargo build
to recompile the protocol buffers as part of the overall binary build. This is configured inbuild.rs
in thegenerate_protos
function. Adding schemas in new files will require a change tobuild.rs
.
Rundler largely relies on the canonical protobuf style guide. There are a few minor differences captured in buf.yaml
to support Tonic best practices. Rundler uses buf to lint the .proto
files. To use buf
run buf lint protos/.
. To install buf
on Macs, run brew install bufbuild/buf/buf
.