Using durable subscriptions

The probe can make a durable or a non-durable subscription with a JMS topic.

In durable subscription to a topic, an active subscriber specified by the probe receives messages that were published on the topic while the subscriber was inactive. When the durable subscription is enabled, the JMS stores messages published on the specified topic while the subscriber is not active or disconnected from the JMS.

In a non-durable subscription to a topic, the subscriber only receives messages that are published on that topic while the subscriber is active. The JMS drops other messages that are sent while the subscriber is inactive.

Enabling durable subscriptions

You can specify the identifier of the subscriber in the PersistentJmsId property, and enable a durable subscription using the Durable property. When the probe reconnects with the same subscriber value, the JMS sends the stored events.

In durable subscription mode, if you stop the probe manually using Ctrl - C and the StoreEvents property is set to 0 the JMS session becomes inactive. However, when the probe is stopped unexpectedly the durable JMS session remains active (or if the StoreEvents property is set to 1). For example, if the probe is stopped due to a system crash, the JMS session remains active. This helps the probe receive alarms generated when it was inactive.

Note: Make sure that the same Jms ClientId value specified using the PersistentJmsID property is part of the JmsFilter property value.

Disabling durable subscriptions

To disable the durable subscription mode, set the value for the Durable property to false. If the value specified for this property is false, the probe makes a non-durable subscription with the JMS topic and receives active alarms.

Note: The JMS removes the stored messages once the probe receives new messages, when the stored messages expire, or when the durable subscription is deleted.