You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "lianetm (via GitHub)" <gi...@apache.org> on 2025/09/03 19:23:23 UTC
[PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
lianetm opened a new pull request, #20472:
URL: https://github.com/apache/kafka/pull/20472
Add to the consumer.close java doc to describe the error handling behaviour.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "chia7712 (via GitHub)" <gi...@apache.org>.
chia7712 commented on PR #20472:
URL: https://github.com/apache/kafka/pull/20472#issuecomment-3259002603
the root cause of flaky is https://github.com/apache/kafka/pull/20244/files#r2325557949
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "lianetm (via GitHub)" <gi...@apache.org>.
lianetm commented on PR #20472:
URL: https://github.com/apache/kafka/pull/20472#issuecomment-3258430275
Thank you all for the reviews. Comments addressed adding missing exceptions to the KafkaConsumer (and checked the ShareKafkaConsumer has them already consistently).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "chia7712 (via GitHub)" <gi...@apache.org>.
chia7712 commented on code in PR #20472:
URL: https://github.com/apache/kafka/pull/20472#discussion_r2320011286
##########
clients/src/main/java/org/apache/kafka/clients/consumer/KafkaConsumer.java:
##########
@@ -1833,6 +1838,9 @@ public void close(Duration timeout) {
* {@link ConsumerConfig#REQUEST_TIMEOUT_MS_CONFIG} for these requests to complete during the close operation.
* Note that the execution time of callbacks (such as {@link OffsetCommitCallback} and
* {@link ConsumerRebalanceListener}) does not consume time from the close timeout.
+ * <p>
+ * This close operation will attempt all shutdown steps even if one of them fails.
+ * It logs all encountered errors, continues to execute the next steps, and finally throws the first error found.
Review Comment:
Should we also list the exceptions, as we do for other close methods?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "frankvicky (via GitHub)" <gi...@apache.org>.
frankvicky commented on code in PR #20472:
URL: https://github.com/apache/kafka/pull/20472#discussion_r2321452584
##########
clients/src/main/java/org/apache/kafka/clients/consumer/KafkaConsumer.java:
##########
@@ -1833,6 +1838,9 @@ public void close(Duration timeout) {
* {@link ConsumerConfig#REQUEST_TIMEOUT_MS_CONFIG} for these requests to complete during the close operation.
* Note that the execution time of callbacks (such as {@link OffsetCommitCallback} and
* {@link ConsumerRebalanceListener}) does not consume time from the close timeout.
+ * <p>
+ * This close operation will attempt all shutdown steps even if one of them fails.
+ * It logs all encountered errors, continues to execute the next steps, and finally throws the first error found.
Review Comment:
+1
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "chia7712 (via GitHub)" <gi...@apache.org>.
chia7712 merged PR #20472:
URL: https://github.com/apache/kafka/pull/20472
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "frankvicky (via GitHub)" <gi...@apache.org>.
frankvicky commented on code in PR #20472:
URL: https://github.com/apache/kafka/pull/20472#discussion_r2321452584
##########
clients/src/main/java/org/apache/kafka/clients/consumer/KafkaConsumer.java:
##########
@@ -1833,6 +1838,9 @@ public void close(Duration timeout) {
* {@link ConsumerConfig#REQUEST_TIMEOUT_MS_CONFIG} for these requests to complete during the close operation.
* Note that the execution time of callbacks (such as {@link OffsetCommitCallback} and
* {@link ConsumerRebalanceListener}) does not consume time from the close timeout.
+ * <p>
+ * This close operation will attempt all shutdown steps even if one of them fails.
+ * It logs all encountered errors, continues to execute the next steps, and finally throws the first error found.
Review Comment:
+1, makes sense to me to align these comments.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] MINOR: extend consumer close java doc with error handling behaviour [kafka]
Posted by "AndrewJSchofield (via GitHub)" <gi...@apache.org>.
AndrewJSchofield commented on PR #20472:
URL: https://github.com/apache/kafka/pull/20472#issuecomment-3258448421
@lianetm Checkstyle :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org