English

Kafka Consumer Group Autoscaler

Distributed, Parallel, and Cluster Computing 2022-06-23 v1

Abstract

Message brokers enable asynchronous communication between data producers and consumers in distributed environments by assigning messages to ordered queues. Message broker systems often provide with mechanisms to parallelize tasks between consumers to increase the rate at which data is consumed. The consumption rate must exceed the production rate or queues would grow indefinitely. Still, consumers are costly and their number should be minimized. We model the problem of determining the required number of consumers, and the partition-consumer assignments, as a variable item size bin packing variant. Data cannot be read when a queue is being migrated to another consumer. Hence, we propose the R-score metric to account for these rebalancing costs. Then, we introduce an assortment of R-score based algorithms, and compare their performance to established heuristics for the Bin Packing Problem for this application. We instantiate our method within an existing system, demonstrating its effectiveness. Our approach guarantees adequate consumption rates something the previous system was unable to at lower operational costs.

Keywords

Cite

@article{arxiv.2206.11170,
  title  = {Kafka Consumer Group Autoscaler},
  author = {Diogo Landau and Xavier Andrade and Jorge G. Barbosa},
  journal= {arXiv preprint arXiv:2206.11170},
  year   = {2022}
}

Comments

10 pages, 10 figures, MSc dissertation work

R2 v1 2026-06-24T12:00:24.192Z