[ 
https://issues.apache.org/jira/browse/HDFS-7979?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andrew Wang updated HDFS-7979:
------------------------------
    Attachment: HDFS-7979.002.patch

Thanks for reviewing Colin. I was doing the zero test was just to initialize 
prevBlockReportId, I don't think there's anything actually wrong with a zero 
value.

To be more clear (and avoid the chance of re-initializing), I changed it to be 
a Long with a null check instead. I left the Random being allocated on the 
stack since it really should be used only once now, ever. LMK what you think.

> Initialize block report IDs with a random number
> ------------------------------------------------
>
>                 Key: HDFS-7979
>                 URL: https://issues.apache.org/jira/browse/HDFS-7979
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: datanode
>    Affects Versions: 2.7.0
>            Reporter: Andrew Wang
>            Assignee: Andrew Wang
>            Priority: Minor
>         Attachments: HDFS-7979.001.patch, HDFS-7979.002.patch
>
>
> Right now block report IDs use system nanotime. This isn't that random, so 
> let's start it at a random number for some more safety.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to