jugomezv commented on code in PR #9994:
URL: https://github.com/apache/pinot/pull/9994#discussion_r1050223101


##########
pinot-core/src/main/java/org/apache/pinot/core/data/manager/realtime/LLRealtimeSegmentDataManager.java:
##########
@@ -585,6 +585,11 @@ private boolean processStreamEvents(MessageBatch 
messagesAndOffsets, long idlePi
             realtimeRowsConsumedMeter =
                 _serverMetrics.addMeteredTableValue(_metricKeyName, 
ServerMeter.REALTIME_ROWS_CONSUMED, 1,
                     realtimeRowsConsumedMeter);
+            long currentTime = System.currentTimeMillis();
+            long pinotIngestionDelayMs = currentTime - 
msgMetadata.getRecordIngestionTimeMs();
+            pinotIngestionDelayMs = pinotIngestionDelayMs >= 0 ? 
pinotIngestionDelayMs : 0;

Review Comment:
   I think there are two possible cases here: something changes the system time 
manually, and the second is the timestamp introduced by the stream service is 
using a clock which is drifted from the pinot server time.



-- 
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]

Reply via email to