Redis Listener (com.ibi.edaqm.XDRedisMasterRedis)

Syntax:

com.ibi.edaqm.XDRedisMasterRedis

Description:

Redis® is a key-value database that also supports a publish/subscribe paradigm. The com.ibi.edaqm.XDRedisMasterRedis listener subscribes to one or more Redis channels and accepts messages that have been published to those channels. The subscription can be a list of channel names or a list of patterns to match against channel names.

The message is received as a string. When stored in the document, it can be left flat or parsed as JSON or XML, depending on the Input Format property.

Parameters:

The following table describes the parameters of the Redis Listener.

Special Registers

The listener will assign the following DOC special registers when processing a message.

Special Register

Description

redis.channel

Name of the channel where the message was published.

redis.pattern

Pattern that matched the channel name. Empty when not using subscription pattern matching.

Example

Assume the value of the Subscriptions property is chan1*,chan2*, the Pattern Matching property is true, and the Input Format property is Parsed XML. When another application publishes the message, <a/>, to the channel, chan100, the listener receives the message, parses it as XML, and stores the result in the document. The value of the redis.channel and redis.pattern special registers will be chan100 and chan1*, respectively.