Real-Time Messaging Services

Real-time messaging services (RTMS) provide a way to capture transactions in an Adaptive Server Enterprise database and deliver them as events to external applications through a Java Messaging Service (JMS) message bus.

Messaging is the exchange of information between two or more software applications. A message is a self-contained package of information. Message systems allow senders and receivers to be decoupled so that not all components need to be up, running, and connected at all times. For example, a messaging system can be asynchronous in that an application can send messages that are successfully delivered even if one or more target applications are temporarily down. Real-time means that the database can trigger events at the same time as they occur, rather than simply queuing the events. For example, a change in a record may be evaluated in conjunction with other changes, and the most efficient response chosen.

RTMS provides an easy way to perform messaging operations within SQL statements. JMS is an API that defines how clients communicate with message providers. Sender and receiver both act as clients to the message provider.

JMS defines two messaging models:

Table 1. JMS messaging models
Point-to-point A one-to-one model in which an application, called a message sender, can send any message, which can be read only by one receiving application, called a message receiver. The destination of a point-to-point message is a queue. A queue can contain more than one active message receiver, but the messaging provider ensures that the message is delivered to only one message receiver.
Publish and consume A one-to-many model, in which the sender, or message producer, initiates the message but does not depend on message consumers receiving the message. The destination of this kind of message is called a topic. Message consumers establish subscriptions to register an interest in messages sent to a topic.

There are two types of subscriptions for this model:


  • Durable – a durable subscription retains messages for the message consumer even when the message consumer application is not connected.

  • Nondurable – a nondurable subscription retains messages only when consumer applications are connected to the message provider.

Note: To publish or subscribe to a topic, you must first register a subscription.
Related concepts
Mapping Functions
Related tasks
Sending a Message to a JMS Queue
Receiving a Message from a JMS Queue
Sending a Message to a WebSphere MQ Queue
Receiving a Message from a WebSphere MQ Queue
Publishing a Message to a Topic
Subscribing to a Topic
Consuming a Message from a Topic
Unsubscribing from a Topic
Registering a Subscription
Parsing an XML Document
Retrieving XML Message Properties
Related reference
Select for XML Statements

For product-related issues, contact Sybase Technical Support at 1-800-8SYBASE. Send your feedback on this help topic directly to Sybase Technical Publications: pubs@sybase.com