Github user tdas commented on a diff in the pull request: https://github.com/apache/spark/pull/17594#discussion_r110760826 --- Diff: sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/StreamExecution.scala --- @@ -304,8 +304,8 @@ class StreamExecution( finishTrigger(dataAvailable) if (dataAvailable) { // Update committed offsets. - committedOffsets ++= availableOffsets batchCommitLog.add(currentBatchId) --- End diff -- Technically, when there is a batch with data, it finishes executing and then increments the batch id for the next batch. But if next batch has no data, then the batchid not further increment, and gets eventually used in a future batch with data. So i think it is correct to update the commit log as soon this batch is done, and before the batch id is incremented for next batch. This change maintains that invariant as far as i think.
--- 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. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org