squah-confluent commented on code in PR #21458:
URL: https://github.com/apache/kafka/pull/21458#discussion_r2796559743


##########
coordinator-common/src/main/java/org/apache/kafka/coordinator/common/runtime/CoordinatorTimerImpl.java:
##########
@@ -97,6 +98,11 @@ public void run() {
                         return operation.generateRecords();
                     }
                 ).exceptionally(ex -> {
+                    // Exceptions may be wrapped in CompletionException or 
ExecutionException
+                    // when propagated through CompletableFuture chains, so we 
unwrap them
+                    // before checking types with instanceof.
+                    ex = Errors.maybeUnwrapException(ex);

Review Comment:
   I can see how we might get a `CompletionException`, but not an 
`ExecutionException`. The latter seems like it would be a bug if we ever 
allowed it to get here.
   



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to