TsgcWSPServer_Dataset › Methods › ClearQueue
Discards queued retained publications pending on a channel.
function ClearQueue(const aChannel: String): Boolean;
| Name | Type | Description |
|---|---|---|
aChannel | const String | Name of the channel whose queued publications must be discarded. |
True when a queue was found for the channel and emptied, False when no queue exists for that channel (Boolean)
When clients publish with QoS Level 1 or Level 2 the server keeps the latest (Level 1) or the full history (Level 2) of messages per channel so late subscribers can receive them on connect or on Subscribe. ClearQueue drops those retained messages for the given channel without affecting currently connected subscribers.
oProtocol.ClearQueue('news');