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

chore: update kafka to 3.4 #210

Merged
merged 2 commits into from
Apr 17, 2023
Merged

chore: update kafka to 3.4 #210

merged 2 commits into from
Apr 17, 2023

Conversation

jeqo
Copy link
Member

@jeqo jeqo commented Apr 16, 2023

No description provided.

Comment on lines 308 to 309
// Intentionally using deprecated method to avoid pinning newer Kafka client
if (adminClient != null) adminClient.close(1, TimeUnit.SECONDS);
if (adminClient != null) adminClient.close();
Copy link
Member Author

Choose a reason for hiding this comment

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

Update admin close to undefined timeout as method with timeunit is not available anymore.

Copy link
Member

Choose a reason for hiding this comment

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

What's the minimum Kafka version supported now? We should probably document this somewhere.

Copy link
Member Author

Choose a reason for hiding this comment

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

With this change we fallback to a close method that is supported across versions -- if we were to use .close(Duration), then it will limit versions; also sniffer was complaining about Duration as it's JDK 8 AFAIR.

Copy link
Member

Choose a reason for hiding this comment

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

I see. So we've kept library version compatibility, but now the behavior is changed - it will wait indefinitely for close now. I guess that's not such a big deal since we already wait indefinitely to close the KafkaProducer. Thanks for the explanation!

Copy link
Member

Choose a reason for hiding this comment

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

I guess the comment on line 308 can be removed now, though, since we're no longer using a deprecated method.

@jeqo jeqo requested review from jcchavezs and shakuzen April 16, 2023 21:48
@jeqo jeqo marked this pull request as ready for review April 17, 2023 06:33
@jeqo jeqo merged commit cb33037 into master Apr 17, 2023
@jeqo jeqo deleted the jeqo/bump-kafka-3.4 branch April 17, 2023 18:17
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