PrachiKhobragade commented on code in PR #8911: URL: https://github.com/apache/pinot/pull/8911#discussion_r902946032
########## pinot-core/src/main/java/org/apache/pinot/core/query/reduce/BaseReduceService.java: ########## @@ -318,7 +318,7 @@ protected void setStats(String rawTableName, BrokerResponseNative brokerResponse brokerMetrics.addTimedTableValue(rawTableName, BrokerTimer.REALTIME_TOTAL_CPU_TIME_NS, _realtimeTotalCpuTimeNs, TimeUnit.NANOSECONDS); - if (_numConsumingSegmentsProcessed > 0 && _minConsumingFreshnessTimeMs > 0) { + if (_minConsumingFreshnessTimeMs != Long.MAX_VALUE) { Review Comment: _minConsumingFreshnessTimeMs may have value even when _numConsumingSegmentsProcessed equals 0, in some error scenarios. Previously _numConsumingSegmentsProcessed > 0 was used in a way to check if consuming segments are present and emit metrics only when the condition is reached. Now we want to emit metrics even if no consuming segments are present, so the first part becomes redundant and can be removed -- 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: commits-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org