Complete the code to add an event to a Redis stream named 'mystream'.
XADD mystream * event [1]The command XADD mystream * event start adds an event named 'start' to the stream 'mystream'. The asterisk * lets Redis generate the event ID automatically.
Complete the code to read the latest event from the Redis stream 'mystream'.
XREVRANGE mystream + - COUNT [1]The command XREVRANGE mystream + - COUNT 1 reads the most recent event from the stream.
Fix the error in the command to read events from 'mystream' starting from ID '0-0'.
XRANGE mystream [1] +The command XRANGE mystream 0-0 + reads all events from the beginning of the stream.
Fill both blanks to create a consumer group named 'mygroup' for the stream 'mystream' starting from the beginning.
XGROUP CREATE mystream [1] [2]
The command XGROUP CREATE mystream mygroup 0-0 creates a consumer group named 'mygroup' starting from the first event in the stream.
Fill all three blanks to read new messages from 'mystream' for consumer 'consumer1' in group 'mygroup'.
XREADGROUP GROUP [1] [2] COUNT 1 STREAMS mystream [3]
The command XREADGROUP GROUP mygroup consumer1 COUNT 1 STREAMS mystream > reads new messages that have never been delivered to any consumer in the group.