What is messaging queue?

Messaging queue is an intermediate component between the interacting entities, typically consumers and producers. The producer produces messages and places them in the queue, while the consumer’s task is to retrieve the messages from the queue and process them. There might be multiple producers and consumers at a time interacting with the queue. Messaging queue enables asynchronous communication between interacting entities and eliminates the speed difference between them. It also decouples the end-points making the system more flexible, available, and highly scalable. Further, it also allows interconnecting heterogeneous environments making communication easier between them.

The messaging queue approach can be utilized at several different levels. It can be used for interprocess communication within one operating system and connect various micro-services in a distributed environment.

Following is an illustration of two applications interacting via a single messaging queue.

Create a free account to access the full course.

By signing up, you agree to Educative's Terms of Service and Privacy Policy