https://github.com/danielvieiravega/go-grpc-example
https://github.com/danielvieiravega/go-grpc-example
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/danielvieiravega/go-grpc-example
- Owner: danielvieiravega
- Created: 2022-05-01T18:40:42.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2022-05-01T18:42:56.000Z (about 3 years ago)
- Last Synced: 2025-01-16T11:32:53.288Z (4 months ago)
- Language: Go
- Size: 12.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Exemplo de utilização do gRPC usando go.
O código foi feito acompanhando o curso de Comunicação entre sistemas da plataforma https://fullcycle.com.br/
```sh
sudo apt install protobuf-compiler
go mod init github.com//
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
export PATH="$PATH:$(go env GOPATH)/bin"
source ~/.bashrc
```--gerar os stubs
```sh
protoc --proto_path=proto/ proto/*.proto --plugin=$(go env GOPATH)/bin/protoc-gen-go-grpc --go-grpc_out=. --go_out=.
```