Re:Application Load Balancers enables gRPC workloads with en...
by k__ on Friday October 30, 2020 @02:06PM
(#24945123)
Does gRPC bring fexibility and discoverability like GraphQL?
[ Parent
| on HN ]
Re:Application Load Balancers enables gRPC workloads with en...
by malkia on Friday October 30, 2020 @02:21PM
(#24945318)
You can enable reflection API (but must compile your server with it) - e.g. it exposes some well known end-point, which when asked can return you back the other end-points available (services), and then asking each end-point service can return each method - and then for each method - what it takes (assuming as "proto") and returns, also what kind is (one shot, bidi, etc.)
So not the same as GraphQL, as you are not asking about resources/objects, but rather inspecting what can be called and how.
Re:Application Load Balancers enables gRPC workloads with en...
by hagsh on Friday October 30, 2020 @02:20PM
(#24945310)
I have not used GraphQL in practice so I can't directly compare them.
What I can say is that in terms of flexibility, protobufs by nature provide us with forward and backward compatibility. We can easily add new fields and eventually deprecate old ones, evolving the API similarly to GraphQL.
Apparently, gRPC also has some introspection capabilities like GraphQL (since again you have a clear protobuf schema) but I have never used them in my clients, and perhaps they are not as baked into the system as in GraphQL.