Streaming messages between client&server services using gRPC
Learn how to stream messages between client and server services using gRPC. Explore the advantages of gRPC for high-performance communication in microservices architectures, including features like bidirectional streaming and real-time data exchange.
At a Glance
Learn how to use gRPC unary calls, server streaming, client streaming, and bidirectional streaming to communicate between Java client and server services with Open Liberty.
You will learn how to create gRPC services and their clients by using protocol buffers and how to implement them with Open Liberty. You will use Maven to generate the gRPC stubs, deploy the services, and to interact with the running Liberty runtime.
The application that you will build in this guide consists of three projects: the systemproto model project, the query client service, and the system server service.
The query service implements four RESTful APIs by using four different gRPC streaming methods.
- Unary RPC: The client sends a single request and receives a single response.
- Server streaming RPC: The client sends a single request and the server returns a stream of messages.
- Client streaming RPC: The client sends a stream of messages and the server responds with a single message.
- Bidirectional RPC: Both client and server send a stream of messages. The client and server can read and write messages in any order.
There are no reviews yet.