Cookbook: Delta Subscribe

This section presents common recipes for subscribing to a topic in AMPS using the Command or Message interfaces. This section provides information on how to configure the request to AMPS. You can adapt this information to your application and the specific interface you are using.

Command: delta_subscribe

Basic Delta Subscription

In its simplest form, a delta subscription needs only the topic to subscribe to.

HeaderComment

Topic (required)

Sets the topic to subscribe to. All messages from the topic will be delivered on this subscription. The topic specified can be the literal topic name, or a regular expression that matches multiple topics.

Delta Subscription with Options

In its simplest form, a delta subscription needs only the topic to subscribe to. To add options to the subscription, set the Options header on the Command.

HeaderComment

Topic (required)

Sets the topic to subscribe to. All messages from the topic will be delivered on this subscription. The topic specified can be the literal topic name, or a regular expression that matches multiple topics.

Options

A comma-delimited set of options for this command. See the delta_subscribe section of this guide for a description of supported options.

Delta Subscription with Content Filter

To provide a content filter on a delta subscription, set the Filter property on the command. The AMPS User Guide provides details on the filter syntax.

HeaderComment

Topic (required)

Sets the topic to subscribe to. The topic specified can be the literal topic name, or a regular expression that matches multiple topics.

Filter

Sets the content filter to be applied to the subscription. Only messages that match the content filter will be provided to the subscription.

Last updated

Copyright 2013-2024 60East Technologies, Inc.