dapr: Remove duplicated PB message definitions and refine gRPC API

In what area(s)?

/area runtime

Describe the feature

This is to remove the duplicated Protobuf message definition and rename gRPC service name properly

  • Move State, StateOptions, RetryPolicy, and StateRequest to dapr/proto/common/v1/ and share them in Dapr and DaprClient grpc service.
    • JS grpc generator complains about the duplicated definitions in Dapr and DaprClient cc/ @pruthvidhodda
  • Rename DaprClient gRPC Service name to AppCallback
    • DaprClient naming makes user confused. We can think that DaprClient is used for Dapr gRPC API client. But, this gRPC is designed for AppChannel communication in user application.
  • Use the consistent request and response message naming convention
    • We use xxxxEnvelope message name in some proto files while using xxxRequest, xxxResponse message name in the other proto files. I am proposing to use xxxRequest, xxxResponse for request and response msg naming conventions respectively.

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 24 (24 by maintainers)

Most upvoted comments

Yes, AppCallback is good as well.

Along those lines then, AppCallback would be more suitable.

You know how the Go linter claims you stutter if the type first word contains the package name?

So dapr.DaprCallback is weird, because the package name is already there. I think dapr.AppCallback is cleaner in this case. WDYT?

I support the usage of Request/Response.

Overall, LGTM.

Can you clarify what will be the naming convention for request/response?