Closed f0ff886f closed 5 years ago
By default XGROUP CREATE passes $ as the ID which means "serve all IDs added from this point on".
XGROUP CREATE
$
Due to that, the XADD directly above never gets served to the XREADGROUP command and this example will just hang the first time you run it waiting.
XADD
XREADGROUP
Adding an explicit ID of 0 means we will get the previous message back in the XREADGROUP.
By default
XGROUP CREATE
passes$
as the ID which means "serve all IDs added from this point on".Due to that, the
XADD
directly above never gets served to theXREADGROUP
command and this example will just hang the first time you run it waiting.Adding an explicit ID of 0 means we will get the previous message back in the
XREADGROUP
.