Comment by gr4vityWall
2 days ago
Shouldn't WebSockets be comparable to raw TCP + a simple message protocol on top of it once you're done with the initial handshaking and protocol upgrade?
I wouldn't expect latency to be an issue for long lived connections, compared to TCP.
no but reliability is. And if you need to re-establish the connection, you'll have to preamble your way through another handshake.
gRPC uses HTTP/2, which has a Client/Server Stream API, to forgo the preamble. In the end though, ANY HTTP based protocol could be throttled by infrastructure in-between. TCP on the other hand, can be encrypted and sent without any preamble - just a protocol, and only L2/L3 can throttle.