mirror of https://github.com/dapr/go-sdk.git
|
||
---|---|---|
.github/workflows | ||
bin | ||
client | ||
dapr/proto | ||
example | ||
.gitignore | ||
CONTRIBUTING.md | ||
LICENSE | ||
Makefile | ||
Readme.md | ||
go.mod | ||
go.sum |
Readme.md
Dapr SDK for Go
This is the dapr SDK (client) for Go.
Update the latest gRPC proto clients
./protogen.sh
Installation
go get github.com/dapr/go-sdk
Usage
The example
folder contains a Dapr enabled serving
app a client
app that uses this SDK to invoke Dapr API for state and events, serving
app for service to service invocation, and a simple HTTP binding to illustrate output binding. To run the example:
- Start the
serving
app in theexample/serving
directory
cd example/serving
dapr run --app-id serving \
--protocol grpc \
--app-port 50001 \
go run main.go
- Start the
client
app in theexample/client
directory
cd example/client
dapr run --app-id caller \
--components-path ./comp \
go run main.go