Overview

JLupin supports publish & subscribe pattern where many clients (microservices) communicate through a channel. Channels implements classic FIFO algorithm to process messages - a message which is put in the end of the channel by a publisher/writer waits to be taken from the front and deleted by a subscriber/reader.

Configuration allows to define many channels within one channel microservice but our recommendation is to define only one channel per one channel microservice (you can define multiple channel microservices to have more than one channel) to separate channels to different JVMs. This way your channels will be more resistant to failures, outages, overloads, etc.

Figure 1. JLupin Reactive Channels Overview.

Why reactive? Because it enables option to stream your result part by part (as one is ready). Great example is a list with result. If we compute elements one by one, already ready ones could be sent to client and shown to user. This way there is no need to wait for last element is computed to access the first one. With streaming option for HTTP requests (supported by WebFlux for example) it is possible to show end user results as they are computed without need to wait for whole computation is done.