Tiny Golang service with a gRPC setup
- Payload data type
- gRPC: Protocol Buffers
- REST: JSON
- Protocol type
- gRPC: HTTP/2?
- REST: HTTP/1.1
- Go ^1.17
- GNU Make
make proto
requires installingprotoc-gen-go
andprotoc-gen-go-grpc
first.
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
make server
# In another Shell window
make client
# Generates or updates *.pb.go generated files. They should be not be directly edited.
. .envrc # Run these commands when starting a new shell window. Alternatively you can put this in your own global shell RC file.
make proto