mirror of https://github.com/dapr/go-sdk.git
Signed-off-by: mikeee <hey@mike.ee> |
||
|---|---|---|
| .. | ||
| client | ||
| server | ||
| README.md | ||
README.md
Grpc Service Example with proxy mode
The examples/grpc-service folder contains a Dapr enabled server app and a client app that uses this SDK to invoke grpc methos via grpc stub, The server app is available as gRPC. The client app can target either one of these for service to service and binding invocations.
Step
Prepare
- Dapr installed
Run server as a dapr app
dapr run --app-id grpc-server \
--app-port 50051 \
--app-protocol grpc \
--dapr-grpc-port 50007 \
go run ./server/main.go
Run grpc client
dapr run --app-id grpc-client \
go run ./client/main.go
Cleanup
dapr stop --app-id grpc-server