Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parallelize topics - consumer groups #267

Merged
merged 4 commits into from
Jan 12, 2024

Conversation

Theodlz
Copy link
Collaborator

@Theodlz Theodlz commented Jan 12, 2024

This PR allows us to have more than one consumer reading a single topic. By creating multiple consumers on the same topic, but ensuring that they use the same group.id, kafka will divide the partitions of a topic between the consumers subscribed to it. This should allow us to read topics quicker, though networking can still be a limiting factor.

In the future, we can definitely consider having a dynamic number of consumers, adding and removing consumers as we accumulate delay/lag. Also, we might want to read the number of partitions on a topic to make sure we don't create more consumers than partitions (in which case we would have idle consumers).

Copy link
Collaborator

@mcoughlin mcoughlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Theodlz Theodlz merged commit 54a22d6 into skyportal:main Jan 12, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants