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

Ted Yu commented on HBASE-15381:
--------------------------------

{code}
+ */
+public class MasterMobCompactionManager extends MasterProcedureManager 
implements Stoppable {
{code}
Add annotation for audience.
{code}
+  private static final String MOB_COMPACTION_TIMEOUT_MILLIS_KEY =
+    "hbase.mob.compaction.master.timeoutMillis";
{code}
Looking at other configs, the key should be named 
hbase.master.mob.compaction.timeoutMillis
Same with hbase.mob.compaction.master.wakeMillis config name.
{code}
+  private Map<TableName, Map<String, Pair<Boolean, List<String>>>> 
compactingRegions =
{code}
Please add comment for what the String and Boolean mean.
{code}
+  private HMaster master;
{code}
Can we narrow the type so that HMaster is not referenced directly ?
{code}
+    Configuration copyOfConf = new Configuration(conf);
+    copyOfConf.setBoolean(CacheConfig.CACHE_DATA_ON_READ_KEY, Boolean.FALSE);
{code}
Maybe check the value for CacheConfig.CACHE_DATA_ON_READ_KEY . If it is false 
already, there is no need to copy.
{code}
+  public void updateAsMajorCompaction(TableName tableName, String serverName) {
...
+    regions.setFirst(Boolean.TRUE);
{code}
Consider using an eum in place of the boolean - it would make the code more 
readable.

> Implement a distributed MOB compaction by procedure
> ---------------------------------------------------
>
>                 Key: HBASE-15381
>                 URL: https://issues.apache.org/jira/browse/HBASE-15381
>             Project: HBase
>          Issue Type: Improvement
>          Components: mob
>            Reporter: Jingcheng Du
>            Assignee: Jingcheng Du
>         Attachments: HBASE-15381.patch, mob distributed compaction 
> design-v2.pdf, mob distributed compaction design.pdf
>
>
> In MOB, there is a periodical compaction which runs in HMaster (It can be 
> disabled by configuration), some small mob files are merged into bigger ones. 
> Now the compaction only runs in HMaster which is not efficient and might 
> impact the running of HMaster. In this JIRA, a distributed MOB compaction is 
> introduced, it is triggered by HMaster, but all the compaction jobs are 
> distributed to HRegionServers.



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

Reply via email to