loopback4-microservice-catalog icon indicating copy to clipboard operation
loopback4-microservice-catalog copied to clipboard

Grpc Support for microservices

Open SouravSF opened this issue 4 years ago • 0 comments

How about we extend our microservice catalog to support Grpc protocol?

gRPC can use protocol buffer for data serialization. This makes payloads faster, smaller and simpler.

Just like REST, gRPC can be used cross-language which means that if you have written a web service in Golang, a Java written application can still use that web service, which makes gRPC web services very scalable.

gRPC uses HTTP/2 to support highly performant and scalable API’s and makes use of binary data rather than just text which makes the communication more compact and more efficient. gRPC makes better use of HTTP/2 then REST. gRPC for example makes it possible to turn-off message compression. This might be useful if you want to send an image that is already compressed. Compressing it again just takes up more time.

It is also type-safe. This basically means that you can’t give an apple while a banana is expected. When the server expects an integer, gRPC won’t allow you to send a string because these are two different types.

https://grpc.io/

SouravSF avatar Jul 20 '21 07:07 SouravSF