Github user brkyvz commented on a diff in the pull request:
https://github.com/apache/spark/pull/21220#discussion_r185677898
--- Diff:
sql/core/src/main/scala/org/apache/spark/sql/execution/streaming/MicroBatchExecution.scala
---
@@ -128,40 +130,49 @@ class MicroBatchExecution(
* Repeatedly attempts to run batches as data arrives.
*/
protected def runActivatedStream(sparkSessionForStream: SparkSession):
Unit = {
- triggerExecutor.execute(() => {
- startTrigger()
+ triggerExecutor.execute(() => {
if (isActive) {
+ var currentBatchIsRunnable = false // Whether the current batch is
runnable / has been run
+ var currentBatchHadNewData = false // Whether the current batch
had new data
+
reportTimeTaken("triggerExecution") {
+ startTrigger()
--- End diff --
this used to be out of the timing block
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]