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

Kafka input on Benthos 4.22 is incompatible with Event Hubs / Kafka 1.0.0 due to Sarama 1.41.0+ #2176

Closed
mfamador opened this issue Oct 19, 2023 · 4 comments · Fixed by #2201
Labels
bug waiting for upstream Blocked on changes needed in an upstream dependency

Comments

@mfamador
Copy link
Contributor

Starting from Sarama version 1.41.0, every time a consumer group starts or leaves from an Azure Event Hub partition, all running consumers from the same consumer group re-consumes all messages. It appears that the offsets are reset and not committed again.
This issue seems to be specific to Azure Event Hubs (Kafka version 1.0.0), and it has also been reproduced, not so often though, using Kafka 1.0.0 docker.
I could also reproduce it using plain Golang, so very likely a Sarama's issue, just creating this one here as an heads up for who's using Event Hubs with kafka_input not upgrading to Benthos 4.22 : see IBM/sarama#2677

Reverting back to Sarama 1.40.1 everything works again as expected.

From their breaking changes heads up on 1.41.0 release (https://github.com/IBM/sarama/releases/tag/v1.41.0), we're already pinning the version with target_version to 1.0.0, it should be ok.

input:
  kafka:
    addresses:
    - fooeventhub.servicebus.windows.net:9093
    tls:
      enabled: true
    sasl:
      mechanism: PLAIN
      user: $ConnectionString
      password: 'Endpoint=<READCTED>;EntityPath=test'
    target_version: 1.0.0
    topics:
    - test
    consumer_group: foo
@mfamador mfamador changed the title Kafka input on benthos 4.22 is incompatible with Event Hubs / Kafka 1.0.0 due to Sarama 1.41.0+ Kafka input on Benthos 4.22 is incompatible with Event Hubs / Kafka 1.0.0 due to Sarama 1.41.0+ Oct 19, 2023
@mihaitodor mihaitodor added bug waiting for upstream Blocked on changes needed in an upstream dependency labels Oct 23, 2023
@mfamador
Copy link
Contributor Author

mfamador commented Oct 24, 2023

Considering the new version (1.41.0+) of sarama is breaking Kafka 1.0.0/EventHubs consumers, do you think we can revert back to sarama 1.40.1 ? (#2186)

@Jeffail
Copy link
Collaborator

Jeffail commented Oct 30, 2023

Thanks for the investigation @mfamador!

@mfamador
Copy link
Contributor Author

mfamador commented Nov 2, 2023

There is already a fix on Sarama, we should be able to upgrade again as soon as they release a new version.
IBM/sarama#2700

@dnwe
Copy link
Contributor

dnwe commented Nov 2, 2023

Fix released in Version 1.42.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug waiting for upstream Blocked on changes needed in an upstream dependency
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants