[ 
https://issues.apache.org/jira/browse/HBASE-5332?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13210721#comment-13210721
 ] 

Phabricator commented on HBASE-5332:
------------------------------------

Kannan has commented on the revision "[jira] [HBASE-5332] Deterministic 
Compaction Jitter".

  Nicolas -- excellent! Minor comments...

INLINE COMMENTS
  src/main/java/org/apache/hadoop/hbase/regionserver/Store.java:1068 
storeNameStr appears to be the CF name only. Did you intend to take the 
regionName also into the seed computation?

  Not a big deal.. the fact that you are taking the path name of the first file 
should itself be good enough since that's randomized enough. We may not even 
need the storeNameStr.


  src/main/java/org/apache/hadoop/hbase/regionserver/Store.java:1067 maybe 
safer to:

  if (storefiles != null && !storefiles.isEmpty()) {
    ..
  }

  Maybe the constructor always guarantees that this is initialized to a 
0-element list. But nevertheless...
  src/main/java/org/apache/hadoop/hbase/regionserver/Store.java:1065 I think 
this lock here is unnecessary.

  storeFiles points to a immutable list, something that's update wholesale 
rather than in-parts at the end of a flush or compaction.

  See other uses of this like: getStorefilesIndexSize() which don't take a lock 
either.

REVISION DETAIL
  https://reviews.facebook.net/D1785

                
> Deterministic Compaction Jitter
> -------------------------------
>
>                 Key: HBASE-5332
>                 URL: https://issues.apache.org/jira/browse/HBASE-5332
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Nicolas Spiegelberg
>            Assignee: Nicolas Spiegelberg
>            Priority: Minor
>         Attachments: D1785.1.patch, D1785.2.patch
>
>
> Currently, we add jitter to a compaction using "delay + jitter*(1 - 
> 2*Math.random())".  Since this is non-deterministic, we can get major 
> compaction storms on server restart as half the Stores that were set to 
> "delay + jitter" will now be set to "delay - jitter".  We need a more 
> deterministic way to jitter major compactions so this information can persist 
> across server restarts.

--
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

        

Reply via email to