Comparing HTTP and gRPC for Dapr
gRPC is a high-performance, open source, universal RPC framework that became extremely popular in the inter-microservices communication space because of its efficiency. gRPC leverages HTTP/2 for transport and adopts the binary serialization format Protobuf.
gRPC in .NET
There are several documents and blog posts on how to implement gRPC servers in Dapr, including articles from the .NET documentation on gRPC, https://docs.microsoft.com/en-us/aspnet/core/tutorials/grpc/grpc-start?tabs=visual-studio-code, and the (not specific to .NET) Dapr documentation on the gRPC service, https://docs.dapr.io/operations/configuration/grpc/.
gRPC is a Cloud Native Computing Foundation (CNCF) incubating project.
Let’s explore how we can leverage gRPC in ASP.NET and then how to apply it to Dapr.
gRPC in ASP.NET
In ASP.NET, we are so used to the combination of HTTP and JSON that we tend to think of these two as the only transport and format choices...