Skip to content

0xp3/rust-grpc-sample

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This project shows how to use tonic to implement both, a gRPC client and a gRPC server defined in .proto files.

gRPC Server

/src folder contains the server code. build.rs uses tonic-build to compile the protos to rust code .

You can inspect the proto compilation result at /src/proto/ folder.

cargo run will launch the server at http://localhost:8080.

Then you can use any of the clients to interact with the server or use grpcurl or postman to interact with it.

gRPC Clients

clients folder contains clients in different programming languages that communicate with the server.

See each folder for instructions on how to compile the .proto files and how to run the clients

Demo

The Dockerfile in this project was setup to host and run this server in GPC (Google Cloud Platform) for demo purposes.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 57.9%
  • JavaScript 20.2%
  • TypeScript 9.8%
  • Go 6.4%
  • CSS 3.0%
  • Dockerfile 2.0%
  • HTML 0.7%