tejaswini-imply commented on code in PR #13144:
URL: https://github.com/apache/druid/pull/13144#discussion_r988555577
##########
indexing-service/src/main/java/org/apache/druid/indexing/seekablestream/supervisor/SeekableStreamSupervisor.java:
##########
@@ -3244,6 +3275,40 @@ private void checkCurrentTaskState() throws
ExecutionException, InterruptedExcep
Futures.successfulAsList(futures).get(futureTimeoutInSeconds,
TimeUnit.SECONDS);
}
+ private void checkIfStreamInactiveAndTurnSupervisorIdle()
+ {
+ if (!spec.getSupervisorStateManagerConfig().isEnableIdleBehaviour()
+ || !spec.getIoConfig().isEnableIdleBehaviour()) {
+ return;
+ }
+
+ Map<PartitionIdType, SequenceOffsetType> latestSequencesFromStream =
getLatestSequences();
+ long nowTime = Instant.now().toEpochMilli();
+ boolean idle;
+ if (lagsVerifiedlastTime > 0
+ && previousPartitionOffsetsSnapshot.equals(latestSequencesFromStream)
+ && computeTotalLag() == 0) {
+ idleTime += nowTime - lagsVerifiedlastTime;
Review Comment:
Oh I'm sorry assignment for `lagsVerifiedlastTime` was done inside by
mistake.
--
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]