#grpc #protobuf #client-server #bsr #rust

bin+lib helloworld-tonic-bsr

A Rust-based protobuf/gRPC example using buf.Build BSR

4 releases (2 breaking)

0.3.0 Oct 27, 2023
0.2.0 Oct 27, 2023
0.1.1 Oct 22, 2023
0.1.0 Oct 22, 2023

#255 in #grpc

Custom license

30KB
568 lines

helloworld-tonic-bsr

A Rust-based protobuf/gRPC example using buf.Build BSR. Please visit the repository to view the complete solution: client, server, and lib.

Example grpcurl commands:

SayHello:

grpcurl -plaintext -import-path "./proto/helloworld/v1" -proto helloworld.proto -d '{"name": "Tonic"}' '[::1]:50051' helloworld.v1.GreeterService/SayHello

{ "message": "Hello Tonic!" }

Describe GreeterService:

grpcurl --plaintext --import-path "./proto/helloworld/v1" -proto helloworld.proto describe helloworld.v1.GreeterService

helloworld.v1.GreeterService is a service:

service GreeterService {

rpc SayHello ( .helloworld.v1.SayHelloRequest ) returns ( .helloworld.v1.SayHelloResponse );

}

Dependencies

~13–24MB
~430K SLoC