Complete the code to trim the stream to a maximum length of 1000 entries.
XTRIM mystream MAXLEN [1]The MAXLEN option limits the stream length. Using 1000 caps the stream at 1000 entries.
Complete the code to trim the stream approximately to 500 entries using the ~ option.
XTRIM mystream MAXLEN ~ [1]The ~ option allows approximate trimming. Setting MAXLEN ~ 500 caps the stream near 500 entries.
Fix the error in the command to trim the stream to exactly 200 entries.
XTRIM mystream MAXLEN [1]The MAXLEN 200 option (without ~) trims the stream exactly to 200 entries.
Fill both blanks to trim the stream to exactly 300 entries without approximate trimming.
XTRIM mystream MAXLEN [1] [2]
Using MAXLEN 300 EXACT trims the stream exactly to 300 entries without approximation.
Fill all three blanks to trim the stream by minimum ID, keeping entries with IDs greater than or equal to 1609459200000-0.
XTRIM mystream [1] [2] [3]
The command XTRIM mystream MINID 1609459200000-0 EXACT trims the stream by removing entries with IDs less than the given ID, exactly.