Github user StephanEwen commented on a diff in the pull request: https://github.com/apache/flink/pull/674#discussion_r30787124 --- Diff: flink-staging/flink-streaming/flink-streaming-connectors/src/main/java/org/apache/flink/streaming/connectors/kafka/api/persistent/PersistentKafkaSource.java --- @@ -236,13 +246,22 @@ public void restoreState(long[] state) { @Override public void commitCheckpoint(long checkpointId) { LOG.info("Commit checkpoint {}", checkpointId); - long[] checkpointOffsets = pendingCheckpoints.remove(checkpointId); - if(checkpointOffsets == null) { + final int posInMap = pendingCheckpoints.indexOf(checkpointId); + if(posInMap == -1) { LOG.warn("Unable to find pending checkpoint for id {}", checkpointId); return; } + + long[] checkpointOffsets = (long[]) pendingCheckpoints.remove(posInMap); LOG.info("Got corresponding offsets {}", Arrays.toString(checkpointOffsets)); --- End diff -- I think this log message can be improved. To something like "Committing offsets {} to Kafka."
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---