DomGarguilo commented on code in PR #4250:
URL: https://github.com/apache/accumulo/pull/4250#discussion_r1486335429
##########
server/tserver/src/main/java/org/apache/accumulo/tserver/log/DfsLogger.java:
##########
@@ -186,7 +187,7 @@ public void run() {
} catch (IOException | RuntimeException ex) {
fail(work, ex, "synching");
}
- long duration = System.currentTimeMillis() - start;
+ long duration = NANOSECONDS.toMillis(System.nanoTime() - start);
if (duration > slowFlushMillis) {
Review Comment:
I think it would be best to convert `slowFlushMillis` to nanos and then keep
`start` and `duration` as nanos too. That way you are getting the benefits of
using nanos without having to loose precision by converting back to millis.
That being said, if needed I think its fine to convert from nanos to millis
for logging purposes
--
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]