In our previous tutorial, we have built a server to handle the bi-directional streams. Here we will build a bi-directional streaming client for the same with NodeJS. In order to implement the following tutorial, we need to have NodeJS 14+ installed on your system and the bi-directional gRPC streaming server is running successfully on the system. As the server is running as a part of the prerequisite so we will assume that all the required dependencies have been installed on the system.
gRPC also provides a unique capability for bi-directional streaming which could be used for any use cases starting from Chat server, persistent service-to-service connection, and lots more. Today we will learn how to implement bi-directional streaming using gRPC with NodeJS. We will build a bi-directional streaming server and client to create an article management application that will allow us to create articles in bulk using streaming.
HTTP/2 works very similarly from the client perspective. We can still make GET requests, POST requests etc, and also we are still using a single TCP connection. But here we ended up using this single TCP connection, very efficiently. The client in this scenario , shoves as many requests at the same time into this pipe .This is called multiplexing.
We at Techunits RnD team dedicate ourself towards unveiling bleeding edge technologies in the fields of Data Science, Neural Networks, Machine Learning and lots more. Join us now for some exciting discovery, discussion and submissions!
© 2019 by Techunits | All rights reserved