xkrogen commented on code in PR #5246:
URL: https://github.com/apache/hadoop/pull/5246#discussion_r1054988970
##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/log/LogThrottlingHelper.java:
##########
@@ -259,6 +259,10 @@ public LogAction record(String recorderName, long
currentTimeMs,
currentLogs.put(recorderName, currentLog);
}
currentLog.recordValues(values);
+ if (currentTimeMs < lastLogTimestampMs) {
+ // Reset lastLogTimestampMs: this should only happen in tests
+ lastLogTimestampMs = Long.MIN_VALUE;
+ }
Review Comment:
Why does `FSEditLogLoader` need a reset method? Just so we can trigger the
reset from within `TestFSEditLogLoader`? If so then can we just made
`FSEditLogLoader.LOAD_EDITS_LOG_HELPER` package-private so that we can access
it from within `TestFSEditLogLoader` and then call `reset()` directly on the
`LogThrottlingHelper`?
--
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]