-
Notifications
You must be signed in to change notification settings - Fork 71
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
Replace sync Kafka consumers with confluent_kafka one #794
Conversation
This reverts commit ca4412e.
480822a
to
80f07dc
Compare
@matyaskuti Could you comment the exact spot in the PR for the spot where the bug was? |
@jjaakola-aiven I updated the description with the location. After a short discussion with @aiven-anton I'll attempt to add a test that reveals this issue through the backups code as well. |
80f07dc
to
c4549d0
Compare
c4549d0
to
a30608f
Compare
When instantiating the consumer we already a subscribe to the topic that is to be backed up (ie. __schemas). Using assign on top of that causes problems - once the assignment actually takes effect, the consumer starts to consume from the beginning, ultimately resulting in an `InconsistentOffset` error. The default subscribe is enough at the moment, as we do not support backing up a multi-partition topic.
a30608f
to
2c03ba0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Rather than review the whole diff, I verified that 7fde3188b470528801c983b43592cf6ac182ff19
is the exact same as the originally merged commit, and then reviewed 2c03ba0a4e881fb58665461258fe184785279ddd
independently.
About this change - What it does
karapace/backup/api.py
L533 removed, see the second commit in this PRWhy this way
consumer.assign
afterconsumer.subscribe
is not supposed to be done (further tests and guards will be introduced in a later PR which adds enriched functionality to consumers)