bryanck commented on code in PR #17080:
URL: https://github.com/apache/iceberg/pull/17080#discussion_r4123804076


##########
kafka-connect/kafka-connect/src/main/java/org/apache/iceberg/connect/channel/CommitState.java:
##########
@@ -144,16 +144,21 @@ Map<TableReference, List<Envelope>> tableCommitMap() {
   }
 
   OffsetDateTime validThroughTs(boolean partialCommit) {
+    List<DataComplete> currentCommitReady =
+        readyBuffer.stream()
+            .filter(payload -> Objects.equals(currentCommitId, 
payload.commitId()))

Review Comment:
   Rather than duplicating the same filter in `isCommitReady()` I feel we can 
filter out the old ready events in `addReady()`, then both are working off of 
the same collection, do you have thoughts on that?



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to