The other program retrieves the message from the queue and processes the requests and information encapsulated in the message. A message-oriented middleware furnishes message passing through distributed networks over heterogeneous platforms, reducing the complexity of building applications that span multiple operating systems and network protocols. By: Justin Stoltzfus Contributor, Reviewer. By: Satish Balakrishnan.
Dictionary Dictionary Term of the Day. Natural Language Processing. Techopedia Terms. Connect with us. Sign up. Term of the Day. Best of Techopedia weekly. News and Special Offers occasional. Message Queue. Techopedia Explains Message Queue. What Does Message Queue Mean? Techopedia Explains Message Queue A message queuing environment provides programs in a set, and performs well-defined, self-contained actions in response to a particular request.
Synonyms Mail Box. An example of a message could be something that tells one system to start processing a task, it could contain information about a finished task or just be a plain message. The basic architecture of a message queue is simple; there are client applications called producers that create messages and deliver them to the message queue.
Another application, called a consumer, connects to the queue and gets the messages to be processed. Messages placed onto the queue are stored until the consumer retrieves them. A message queue provides an asynchronous communications protocol, which is a system that puts a message onto a message queue and does not require an immediate response to continuing processing.
Email is probably the best example of asynchronous communication. When an email is sent, the sender continues to process other things without needing an immediate response from the receiver. This way of handling messages decouples the producer from the consumer so that they do not need to interact with the message queue at the same time.
Decoupling describes how much one piece of a system relies on another piece of the system. Decoupling is the process of separating functions so that they are more self-contained. A decoupled system is achieved when two or more systems are able to communicate without being connected. The systems can remain completely autonomous and unaware of other functions. Decoupling is often a sign of a computer system that is well structured because it is easier to maintain,.
If one process in a decoupled system fails to process messages from the queue, other messages can still be added to the queue and be processed when the system has recovered. You can also use a message queue to delay processing - for example, a producer posts messages to a queue. At the appointed time, the consumers start and process the messages in the queue. A queued message can be stored-and-forwarded, and the message can be redelivered until it is processed.
Instead of building one large application, it is beneficial to decouple different parts of your application and communicate between them asynchronously using message queues. A message queue will keep the processes in your application separate and independent of each other.
The first process will never need to invoke another process, post notifications to another process, or follow the process flow of the other processes. It can just put the message in the queue and then continue processing. The other processes can also handle their work independently, taking the messages from the queue when they are able to process them.
This way of handling messages creates a system that is easy to maintain and scale. Imagine that you have a web service that receives many requests every second, where no request can get lost, and all requests need to be processed by a function that has a high throughput.
0コメント