Push Vs Pull
Pull base
- Pull is better when dealing with diversified consumers.
- Pull consumer can effectively control its own rate of consuming
- Easier and more optimal for batch processing
- Pull consumer no need to keep the connection
- Draw back: keep polling when there is no data.
- We can introduce long-polling waiting mode until data arrives
Push base
- Need to keep the connection
- have different push types
- harder to scale
For pull-based: Kafka
For push-based: RabbitMQ