Back to Redis

XGROUP DELCONSUMER

content/commands/xgroup-delconsumer.md

latest1.3 KB
Original Source

The XGROUP DELCONSUMER command deletes a consumer from the consumer group.

Sometimes it may be useful to remove old consumers since they are no longer used.

Note, however, that any pending messages that the consumer had will become unclaimable after it was deleted. It is strongly recommended, therefore, that any pending messages are claimed or acknowledged prior to deleting the consumer from the group.

Redis Software and Redis Cloud compatibility

| Redis Software | Redis Cloud | <span style="min-width: 9em; display: table-cell">Notes</span> | |:----------------------|:-----------------|:------| | <span title="Supported">✅ Standard</span> <span title="Supported"><nobr>✅ Active-Active</nobr></span> | <span title="Supported">✅ Standard</span> <span title="Supported"><nobr>✅ Active-Active</nobr></span> | |

Return information

{{< multitabs id="xgroup-delconsumer-return-info" tab1="RESP2" tab2="RESP3" >}}

Integer reply: the number of pending messages the consumer had before it was deleted.

-tab-sep-

Integer reply: the number of pending messages the consumer had before it was deleted.

{{< /multitabs >}}