[
https://issues.apache.org/jira/browse/HDFS-14346?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16789677#comment-16789677
]
Erik Krogen commented on HDFS-14346:
------------------------------------
Hey [~csun], the approach LGTM. We should probably change the title (and the
project?) to more accurately reflect the scope of the change.
One comment on the patch so far, can you explain why we need this method / what
the use case would be?
{code}
public long getTimeDuration(String name, String defaultValue, TimeUnit
defaultUnit, TimeUnit returnUnit)
{code}
> EditLogTailer loses precision for sub-second edit log tailing and rolling
> interval
> ----------------------------------------------------------------------------------
>
> Key: HDFS-14346
> URL: https://issues.apache.org/jira/browse/HDFS-14346
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: namenode
> Reporter: Chao Sun
> Assignee: Chao Sun
> Priority: Minor
> Attachments: HDFS-14346.000.patch
>
>
> {{EditLogTailer}} currently uses the following:
> {code}
> logRollPeriodMs = conf.getTimeDuration(
> DFSConfigKeys.DFS_HA_LOGROLL_PERIOD_KEY,
> DFSConfigKeys.DFS_HA_LOGROLL_PERIOD_DEFAULT, TimeUnit.SECONDS) * 1000;
> sleepTimeMs = conf.getTimeDuration(
> DFSConfigKeys.DFS_HA_TAILEDITS_PERIOD_KEY,
> DFSConfigKeys.DFS_HA_TAILEDITS_PERIOD_DEFAULT, TimeUnit.SECONDS) *
> 1000;
> {code}
> to determine the edit log roll and tail frequency. However, if user specify
> sub-second frequency, such as {{100ms}}, it will lose precision and become
> 0s. This is not ideal for some scenarios such as standby reads (HDFS-12943).
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]