← All notes

Share a Kafka topic among consumers with consumer groups

Answer: A group coordinator allocates entity ids to members of a consumer group and drives rebalance. Share groups exist as another group type alongside traditional consumer groups. GroupCoordinator includes a heartbeat to a Consumer Group.

Partitions and membership

This partitioning style is explicitly designed to allow locality-sensitive processing in consumers. The client controls which partition it publishes messages to. The rebalance protocol relies on the group coordinator to allocate entity ids to group members. Those generated ids are ephemeral; they change if members restart and later rejoin.

Static membership aims to keep group membership unchanged based on those ids, thus no rebalance will be triggered. The unit of replication is the topic partition.

| group coordinator | rebalance | |---|---| | allocate entity ids | membership changes | | Consumer Group heartbeat | GroupCoordinator | | share groups | alongside traditional consumer groups |

Coordinator and share groups

GroupCoordinator is a public interface. One method is a heartbeat to a Consumer Group. Another method is Join a Classic Group. There is also Leave a Classic Group, and List Groups.

However, some traditional messaging workloads are not a good fit for consumer groups. Share groups exist alongside those traditional groups and have their own heartbeat. A broker configuration property, group.share.partition.max.record.locks, controls a share-group limit.

See also

Claims

Sources

License: this note is CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Summary by iinventedlight (AI-assisted). Sources: Apache Kafka docs, Design; Apache Kafka source, GroupCoordinator.java. Apache-2.0. Text was condensed and changed from the originals.

License: CC-BY-4.0 · Summary by iinventedlight (AI-assisted). Sources: Apache Kafka docs, Design; Apache Kafka source, GroupCoordinator.java. Apache-2.0.

Cite this

Permanent ID: iil:note:43jt98m6

iinventedlight. 2026. "Share a Kafka topic among consumers with consumer groups." iinventedlight Library, iil:note:43jt98m6, version of 2026-11-20. https://iinventedlight.com/library/notes/kafka-consumer-groups/. License: CC-BY-4.0.

@misc{iil_note_43jt98m6,
  author = {{iinventedlight}},
  title = {{Share a Kafka topic among consumers with consumer groups}},
  howpublished = {iinventedlight Library},
  year = {2026},
  date = {2026-11-20},
  url = {https://iinventedlight.com/library/notes/kafka-consumer-groups/},
  note = {Permanent ID iil:note:43jt98m6. License: CC-BY-4.0.},
}

Markdown

Spotted a mistake? Use the MCP feedback tool or email hello@iinventedlight.com. Or Report a correction (no account needed).

Extra files beside this note

These files use this note's license, shown below. Paper extras retain their reproduction status; a link is not a reproduction.

All artifact files (JSON index)

For language models and agents: start at /llms.txt | /agents.md | /.well-known/agent-library.json. This page in Markdown: /library/notes/kafka-consumer-groups.md.