-
Notifications
You must be signed in to change notification settings - Fork 488
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: Add support to configure heartbeat interval and session timeout to kafka's consumer #3375
Kafka: Add support to configure heartbeat interval and session timeout to kafka's consumer #3375
Conversation
…ub and binding metadata Signed-off-by: denisbchrsk <[email protected]>
Signed-off-by: denisbchrsk <[email protected]>
…meout Signed-off-by: denisbchrsk <[email protected]>
…kafka metadata Signed-off-by: denisbchrsk <[email protected]>
Signed-off-by: denisbchrsk <[email protected]>
It definitely looks very similar, but if I'm not mistaken, #3371 reinforces the network-level connection to the broker, vs a new-initialized consumer in the consumer group defining a SLA to the broker; if no heartbeat occurred after sessionTimeout, then the consumer instance is removed from the consumer group, and the broker rebalances the consumer group and re-assigns the partitions (Kafka-specific configuration, there's a better explanation in confluent's docs https://docs.confluent.io/platform/current/installation/configuration/consumer-configs.html#session-timeout-ms). |
Yes, I think we will want the network-level connection with the broker in my PR you've linked. My PR gets at keeping the sidecar with a constant network connection to the broker which is what you want in the event a sidecar becomes idle in the eyes of the broker. |
Thanks @sicoyle for the confirmation, to summarize the differences in (hopefully) simpler terms from my previous comment:
Both of these PRs are relevant in their own domain and are different. |
Signed-off-by: denisbchrsk <[email protected]>
Hey @ItalyPaleAle, is it possible to take a look at this again? I've explained in the previous comment why it's completely different from #3371 |
Yes, I think this is helpful. I've just merged #3371 and now there are some merge conflicts. Could you please take a look? I'll review after this is ready |
Signed-off-by: denisbchrsk <[email protected]>
Fixed the merge conflicts, it's ready for review @ItalyPaleAle |
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 thanks!
Please don't forget to open a PR (or at least an issue) in dapr/docs to have the new options documented!
Description
Added the option to configure heartbeat interval and session timeout in Kafka Pubsub and Kafka Binding - relevant for certain use cases where the sidecar might not be able to consistently send heartbeats to the Kafka brokers, or real time cases where you need the sidecar to send heartbeats more frequently than sarama's default values.
Issue reference
We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.
Please reference the issue this PR will close: #[issue number]
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list: