WebSphere Message Service Clients for C/C++ and .NET, Version 1.2 Operating Systems: Linux, Windows

Styles of messaging

XMS supports the point-to-point and publish/subscribe styles of messaging.

Styles of messaging are also called messaging domains.

Point-to-point messaging
A common form of point-to-point messaging uses queuing. In the simplest case, an application sends a message to another application by identifying, implicitly or explicitly, a destination queue. The underlying messaging and queuing system receives the message from the sending application and routes the message to its destination queue. The receiving application can then retrieve the message from the queue.

If the underlying messaging and queuing system contains a message broker, the broker might replicate a message and route copies of the message to different queues so that more than one application can receive the message. The broker might also transform a message and add data to it.

A key characteristic of point-to-point messaging is that an application identifies a destination queue when it sends a message. The configuration of the underlying messaging and queuing system then determines precisely which queue the message is put on so that it can be retrieved by the receiving application.

Publish/subscribe messaging
In publish/subscribe messaging, there are two types of application: publisher and subscriber.

A publisher supplies information in the form of messages. When a publisher publishes a message, it specifies a topic, which identifies the subject of the information inside the message.

A subscriber is a consumer of the information that is published. A subscriber specifies the topics it is interested in by sending subscription requests to a publish/subscribe broker. The broker receives published messages from publishers and subscription requests from subscribers, and routes published messages to subscribers. A subscriber receives messages on all topics, and only those topics, to which it has subscribed.

A key characteristic of publish/subscribe messaging is that a publisher identifies a topic when it publishes a message, and a subscriber receives the message only if has subscribed to the topic. If a message is published on a topic for which there are no subscribers, no application receives the message.

An application can be both a publisher and a subscriber.


Concept topic

Terms of Use | Rate this page

Last updated: 7 Dec 2005

© Copyright IBM Corporation 2005. All Rights Reserved.