Efrat19 commented on code in PR #257:
URL: 
https://github.com/apache/flink-connector-kafka/pull/257#discussion_r3294114149


##########
flink-connector-kafka/src/main/java/org/apache/flink/connector/kafka/source/reader/KafkaPartitionSplitReader.java:
##########
@@ -240,13 +240,18 @@ public void close() throws Exception {
     public void pauseOrResumeSplits(
             Collection<KafkaPartitionSplit> splitsToPause,
             Collection<KafkaPartitionSplit> splitsToResume) {
+        // Filter against current assignment to avoid IllegalStateException 
when a partition
+        // was concurrently unassigned by fetch() or removeEmptySplits().
+        Set<TopicPartition> assigned = consumer.assignment();

Review Comment:
   Nit: Wdyt about leaving a warn here to unmask any edge case where 
pauseOrResumeSplits is called for unassigned partition from an unfinished split?



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