You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Tsz Wo (Nicholas), SZE (JIRA)" <ji...@apache.org> on 2012/05/23 20:20:40 UTC
[jira] [Commented] (HDFS-3456) blockReportInterval is long value
but when we take the random value it uses getRandom().nextInt,it is causing
frequently BR
[ https://issues.apache.org/jira/browse/HDFS-3456?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13281776#comment-13281776 ]
Tsz Wo (Nicholas), SZE commented on HDFS-3456:
----------------------------------------------
Although this is a valid concern, the problem won't happen in practice since
{code}
Integer.MAX_VALUE milliseconds > 596 hours. // (2^31-1)/3600,000 = 596.52...
{code}
blockReportInterval won't be set to such large value.
> blockReportInterval is long value but when we take the random value it uses getRandom().nextInt,it is causing frequently BR
> ---------------------------------------------------------------------------------------------------------------------------
>
> Key: HDFS-3456
> URL: https://issues.apache.org/jira/browse/HDFS-3456
> Project: Hadoop HDFS
> Issue Type: Bug
> Components: data-node
> Affects Versions: 2.0.0
> Reporter: Brahma Reddy Battula
> Priority: Minor
>
> blockReportInterval is long value but when we take the random value it uses getRandom().nextInt.
> Due to this, offerService can throw exception as long may get rotated to negative value.
> So, block report may send very frequently.
> {code}
> if (resetBlockReportTime) {
> lastBlockReport = startTime - DFSUtil.getRandom().nextInt((int)(dnConf.blockReportInterval));
> resetBlockReportTime = false;
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira