[
https://issues.apache.org/jira/browse/HDDS-12459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17932694#comment-17932694
]
Tsz-wo Sze commented on HDDS-12459:
-----------------------------------
[~chiacyu], thanks a lot for working on this!
BTW, I propose adding a NanoClock class extending Clock, where NanoClock is
implemented using System.nanoTime(). Then, the use of system(ZoneId) /
systemDefaultZone() / systemUTC() can be replaced by a NanoClock. Please see
if it is a good idea.
> System clock should not be used for measuring time duration
> -----------------------------------------------------------
>
> Key: HDDS-12459
> URL: https://issues.apache.org/jira/browse/HDDS-12459
> Project: Apache Ozone
> Issue Type: Bug
> Reporter: Tsz-wo Sze
> Assignee: Chia-Chuan Yu
> Priority: Major
>
> java.time.Clock (system(ZoneId) / systemDefaultZone() / systemUTC()) uses
> System.currentTimeMillis(). As described in HADOOP-15901, this could result
> in undesired results when system clock's time changes.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]