In streams, we have the producer-consumer model:

There are different methods of using the producer-consumer model:

Consumers may be consuming data from multiple producers, and a producer might need to send data to multiple consumers (many-many relationship).

In order to scale, we use middleware that coordinates streaming - data broker.

image.png

Note we can also have a push-poll model - producers push to broker, consumers poll from broker as needed.

Note we can also have a push-poll model - producers push to broker, consumers poll from broker as needed.