DBAtlas · Database operations atlas

BUSYGROUP Consumer Group name already exists: Consumer group already exists

Redis

What does it mean?

You tried to create a consumer group on a stream with XGROUP CREATE, but a group with the same name already exists on that stream. Redis does not overwrite the existing group.

Why does it happen?

The application unconditionally tries to create the group at startup and the group is left over from a previous run; or multiple instances try to create the same group in parallel. Typical of non-idempotent startup logic.

How to fix it

Make group creation idempotent: catch and ignore the error (an existing group is fine). Use XGROUP CREATE stream group $ MKSTREAM to create the stream automatically if it does not exist yet. Run XINFO GROUPS stream to see existing groups. If you really want to reset it, first delete it with XGROUP DESTROY stream group.

Open in DBAtlas →

More from this engine