You can’t really compare the two. Apache Kafka is a distributed streaming platform. In plainer words, a technology that helps you reliably pass information (data streams) between multiple actors. It’s mostly used as a smarter pubsub messaging queue, facilitating communication between microservices. You could compare it with RabbitMQ, ZeroMQ or even Redis (as a poor’s man choice)
REST is a protocol on top of HTTP that standardizes the way we’re synchronously (aka waiting for a response after each request) reading, writing and deleting remote resources.
However, if you're actually asking why and when you should use a messaging queue versus when you should simply call other services using REST in a microservices architecture, then I would advise to always use a messaging queue. Here's an article I've wrote regarding this topic here on dev.to which touches this topic among other things related to microservices.
A Python developer with a knack for math. TKD black belt, ask me about 2013.
Applied Math Alum @SMU, but I can tell you all about commutative rings too.
https://www.pbk.org/
Top comments (2)
You can’t really compare the two. Apache Kafka is a distributed streaming platform. In plainer words, a technology that helps you reliably pass information (data streams) between multiple actors. It’s mostly used as a smarter pubsub messaging queue, facilitating communication between microservices. You could compare it with RabbitMQ, ZeroMQ or even Redis (as a poor’s man choice)
REST is a protocol on top of HTTP that standardizes the way we’re synchronously (aka waiting for a response after each request) reading, writing and deleting remote resources.
However, if you're actually asking why and when you should use a messaging queue versus when you should simply call other services using REST in a microservices architecture, then I would advise to always use a messaging queue.
Here's an article I've wrote regarding this topic here on dev.to which touches this topic among other things related to microservices.
These are two very different things in my mind, and not something you make a decision between