Jackie-Jiang commented on code in PR #11421: URL: https://github.com/apache/pinot/pull/11421#discussion_r1304835090
########## pinot-core/src/main/java/org/apache/pinot/core/data/manager/realtime/LLRealtimeSegmentDataManager.java: ########## @@ -1648,12 +1648,13 @@ private void updateCurrentDocumentCountMetrics() { _lastUpdatedRowsIndexed.set(_numRowsIndexed); final long now = now(); final int rowsConsumed = _numRowsConsumed - _lastConsumedCount; - final long prevTime = _lastConsumedCount == 0 ? _consumeStartTime : _lastLogTime; + final long prevTime = _lastLogTime == 0 ? _consumeStartTime : _lastLogTime; // Log every minute or 100k events if (now - prevTime > TimeUnit.MINUTES.toMillis(TIME_THRESHOLD_FOR_LOG_MINUTES) || rowsConsumed >= MSG_COUNT_THRESHOLD_FOR_LOG) { _segmentLogger.info( "Consumed {} events from (rate:{}/s), currentOffset={}, numRowsConsumedSoFar={}, numRowsIndexedSoFar={}", + // multiply by 1000 to get events/sec. now and prevTime are in milliseconds. rowsConsumed, (float) (rowsConsumed) * 1000 / (now - prevTime), _currentOffset, _numRowsConsumed, Review Comment: Not introduced in this PR, but I guess the intention should be ```suggestion rowsConsumed, ((float) rowsConsumed) * 1000 / (now - prevTime), _currentOffset, _numRowsConsumed, ``` -- 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