XCLAIM

Since 1.1.0Streams

Syntax

XCLAIM key group consumer min-idle-time id [id ...] [IDLE ms] [TIME ms] [RETRYCOUNT n] [FORCE] [JUSTID] [LASTID id]
  • Flags: write
  • ACL categories: @slow, @stream, @write
  • Arity: -6

Gives pending entries to consumer, if they have been idle at least min-idle-time milliseconds: for when the consumer that had them stopped. Each claim counts as a delivery.

Options

OptionEffect
IDLE ms, TIME msSet the entries' idle time, or the time they count as delivered.
RETRYCOUNT nSet their delivery count.
FORCEMake entries that are not pending pending, for consumer.
JUSTIDReply with IDs only, and do not count a delivery.
LASTID idAlso move the group's last delivered ID.

Reply

  • The entries claimed, or their IDs with JUSTID.

Examples

> XCLAIM jobs workers bob 0 2-0
1) 1) "2-0"
   2) 1) "task"
      2) "b"
> XCLAIM jobs workers alice 0 2-0 JUSTID
1) "2-0"