• valentinogeron's avatar
    Stream: Inconsistency between master and replica some XREADGROUP case (#7526) · 795c454d
    valentinogeron authored
    XREADGROUP auto-creates the consumer inside the consumer group the
    first time it saw it.
    When XREADGROUP is being used with NOACK option, the message will not
    be added into the client's PEL and XGROUP SETID would be propagated.
    When the replica gets the XGROUP SETID it will only update the last delivered
    id of the group, but will not create the consumer.
    
    So, in this commit XGROUP CREATECONSUMER is being added.
    Command pattern: XGROUP CREATECONSUMER <key> <group> <consumer>.
    
    When NOACK option is being used, createconsumer command would be
    propagated as well.
    
    In case of AOFREWRITE, consumer with an empty PEL would be saved with
    XGROUP CREATECONSUMER whereas consumer with pending entries would be
    saved with XCLAIM
    795c454d
aof.c 72.6 KB