You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Lars George (JIRA)" <ji...@apache.org> on 2015/08/31 14:54:45 UTC

[jira] [Commented] (HBASE-14343) Fix debug message in SimpleRegionNormalizer for small regions

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

Lars George commented on HBASE-14343:
-------------------------------------

{code}
    if (tableRegions == null || tableRegions.size() < 3) {
      LOG.debug("Table " + table + " has " + tableRegions.size() + " regions, required min number"
        + " of regions for normalizer to run is 3, not running normalizer");
      return EmptyNormalizationPlan.getInstance();
    }
{code}

Also, the debug message above will through an NPE if the {{tableRegions}} is {{null}} as checked. Missing extra check in debug message construction.



> Fix debug message in SimpleRegionNormalizer for small regions
> -------------------------------------------------------------
>
>                 Key: HBASE-14343
>                 URL: https://issues.apache.org/jira/browse/HBASE-14343
>             Project: HBase
>          Issue Type: Bug
>          Components: regionserver
>    Affects Versions: 1.1.1
>            Reporter: Lars George
>            Assignee: Lars Francke
>            Priority: Trivial
>              Labels: beginner
>
> The {{SimpleRegionNormalizer}} has this:
> {code}
>      if ((smallestRegion.getSecond() + smallestNeighborOfSmallestRegion.getSecond()
>           < avgRegionSize)) {
>         LOG.debug("Table " + table + ", smallest region size: " + smallestRegion.getSecond()
>           + " and its smallest neighbor size: " + smallestNeighborOfSmallestRegion.getSecond()
>           + ", less than half the avg size, merging them");
> {code}
> It does *not* check for "less than half the avg size" but only "less than the avg size", that is, drop the "half". Fix message.



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