You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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.
Copy file name to clipboardexpand all lines: service/grpc/Readme.md
+26-9
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ Start by importing Dapr Go `service/grpc` package:
6
6
daprd "github.com/dapr/go-sdk/service/grpc"
7
7
```
8
8
9
-
## Creating and Starting Service
9
+
## Creating and Starting Service
10
10
11
11
To create a gRPC Dapr service, first, create a Dapr callback instance with a specific address:
12
12
@@ -27,6 +27,23 @@ if err != nil {
27
27
s:= daprd.NewServiceWithListener(list)
28
28
```
29
29
30
+
Dapr gRPC service supports using existed gRPC server with the help of `NewServiceWithGrpcServer`. You can use `RegisterGreeterServer` to add existed gRPC service either:
Once you create a service instance, you can "attach" to that service any number of event, binding, and service invocation logic handlers as shown below. Onces the logic is defined, you are ready to start the service:
0 commit comments