sureshhewabi
sureshhewabi

Reputation: 91

View values of Redis PubSub channel

I have few questions, I could not find the answers from Redis tutorial

1) how can I view/check values of a Redis PubSub channel? Monitor command is there to debug Redis, but I want to check what previously has pushed to channel.

2) What is the exact differece between channel and a queue?

3) how can I monitor Redis cluster in a free web based application?

Upvotes: 0

Views: 2800

Answers (1)

rainhacker
rainhacker

Reputation: 612

1) You cannot view/check values that were published on a channel in the past. You can think of pubsub as fire and forget. Redis publishes a messages on a channel to clients which have subscribed to it, but does not persist the message for future reference. You can only monitor the messages published in realtime

2) Channel is a reference used by Redis to know which clients have subscribed to received messages published on that channel.

Queue is a data structure which stores values, these values can be accessed in future in FIFO order. So if you are using a queue for messaging, the messages will remain in the queue until you explicitly delete them

3) IMO there isn't any great free monitoring tool for Redis out there. See some available options here

As a side, regarding questions 1) and 2) : in case you are looking for reliable messaging, check out Redis Streams.

Upvotes: 4

Related Questions