Skip to content

HBASE-22285 A normalizer which merges small size regions with adjacen… - #931

Closed
mnpoonia wants to merge 8 commits into
apache:branch-1from
mnpoonia:HBASE-22285
Closed

HBASE-22285 A normalizer which merges small size regions with adjacen…#931
mnpoonia wants to merge 8 commits into
apache:branch-1from
mnpoonia:HBASE-22285

Conversation

@mnpoonia

Copy link
Copy Markdown
Contributor

…t regions

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec7m 30sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 1 new or modified test files.
_ branch-1 Compile Tests _
+1 💚mvninstall8m 53sbranch-1 passed
+1 💚compile0m 40sbranch-1 passed with JDK v1.8.0_232
+1 💚compile0m 44sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle1m 34sbranch-1 passed
+1 💚shadedjars2m 51sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 37sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc0m 41sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs2m 51sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs2m 49sbranch-1 passed
_ Patch Compile Tests _
+1 💚mvninstall1m 59sthe patch passed
+1 💚compile0m 42sthe patch passed with JDK v1.8.0_232
+1 💚javac0m 42sthe patch passed
+1 💚compile0m 45sthe patch passed with JDK v1.7.0_242
+1 💚javac0m 45sthe patch passed
-1 ❌checkstyle1m 31shbase-server: The patch generated 10 new + 0 unchanged - 0 fixed = 10 total (was 0)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
-1 ❌shadedjars2m 0spatch has 10 errors when building our shaded downstream artifacts.
+1 💚hadoopcheck5m 1sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 30sthe patch passed with JDK v1.8.0_232
+1 💚javadoc0m 41sthe patch passed with JDK v1.7.0_242
+1 💚findbugs2m 53sthe patch passed
_ Other Tests _
-1 ❌unit124m 1shbase-server in the patch failed.
-1 ❌asflicense0m 33sThe patch generated 2 ASF License warnings.
170m 40s
ReasonTests
Failed junit testshadoop.hbase.regionserver.TestSplitTransactionOnCluster
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux d78bb7c53e83 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 84c0a90
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
checkstylehttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/diff-checkstyle-hbase-server.txt
shadedjarshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/patch-shadedjars.txt
unithttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/patch-unit-hbase-server.txt
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/testReport/
asflicensehttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/patch-asflicense-problems.txt
Max. process+thread count4107 (vs. ulimit of 10000)
modulesC: hbase-server U: hbase-server
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

mergeEnabled = masterRpcServices.isSplitOrMergeEnabled(null,
RequestConverter.buildIsSplitOrMergeEnabledRequest(Admin.MasterSwitchType.MERGE)).getEnabled();
} catch (ServiceException se) {
LOG.debug("Unable to determine whether merge is enabled", se);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LOG.error() ?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can make it WARN but not error. Its a valid scenario for table to disable merge and still at cluster level have normalizer enabled.

* <li> get all regions of a given table
* <li> get avg size S of each region (by total size of store files reported in RegionLoad)
* <li> Otherwise, two region R1 and its smallest neighbor R2 are merged,
* if R1 + R1 &lt; S, and all such regions are returned to be merged

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: R1 + R2 &lt; S

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for catching that

candidateIdx++;
}
} catch (Exception e) {
e.printStackTrace();

@virajjasanivirajjasaniDec 13, 2019

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: LOG.error("MergeNormalizer failed for region {} and {}", r1Name, r2Name, e);

"Table " + table + ", small region size: " + regionSize + " plus its neighbor size: "
+ regionSize2 + ", less than the avg size " + avgRegionSize + ", merging them");
plans.add(new MergeNormalizationPlan(hri, hri2));
candidateIdx++;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be candidateIdx = candidateIdx + 2? e.g. if we have 3 regions: r1, r2, r3 and if we consider r1, r2 for merging, plans should have only one entry with Plan(r1, r2) right? but with candidateIdx++, we might end up adding 2 plans: Plan(r1, r2) and Plan(r2, r3)?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is candidateIdx++ outside if block and was kept outside purposefully.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, got it

@wchevreuilwchevreuil left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additional to @virajjasani observations, had made some minor suggestions over the code. On Another thought, the main structure for computePlanForTable looks very similar to the one from SimpleRegionNormalizer. Would it be too difficult to refactor _SimpleRegionNormalizer so that both normalizer implementations could make most of code reuse?

}
HRegionInfo hri2 = tableRegions.get(candidateIdx + 1);
long regionSize2 = getRegionSize(hri2);
if (regionSize >= 0 && regionSize2 >= 0 && regionSize + regionSize2 < avgRegionSize) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe worth logging (debug?) regions that didn't pass this check.

Comment on lines +119 to +123
if (!(new Timestamp(hriTime.getTime() + TimeUnit.DAYS.toMillis(MIN_DURATION_FOR_MERGE)))
.after(currentTime)
|| !(new Timestamp(
hri2Time.getTime() + TimeUnit.DAYS.toMillis(MIN_DURATION_FOR_MERGE)))
.after(currentTime)) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Few minor suggestions:

  1. Maybe worth mention this extra condition on the class javadoc comment.
  2. The checking logic seems duplicate. Place the check into a separate method:
    !(new Timestamp(hriTime.getTime() + TimeUnit.DAYS.toMillis(MIN_DURATION_FOR_MERGE))) .after(currentTime)
  3. Make MIN_DURATION_FOR_MERGE configurable?

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec8m 19sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
+1 💚hbaseanti0m 0sPatch does not have any anti-patterns.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 1 new or modified test files.
_ branch-1 Compile Tests _
+1 💚mvninstall9m 0sbranch-1 passed
+1 💚compile0m 46sbranch-1 passed with JDK v1.8.0_232
+1 💚compile0m 53sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle1m 59sbranch-1 passed
+1 💚shadedjars3m 30sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 41sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc0m 50sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs3m 20sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs3m 15sbranch-1 passed
_ Patch Compile Tests _
+1 💚mvninstall2m 26sthe patch passed
+1 💚compile0m 50sthe patch passed with JDK v1.8.0_232
+1 💚javac0m 50sthe patch passed
+1 💚compile0m 54sthe patch passed with JDK v1.7.0_242
+1 💚javac0m 54sthe patch passed
-1 ❌checkstyle1m 56shbase-server: The patch generated 4 new + 0 unchanged - 0 fixed = 4 total (was 0)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars3m 19spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck6m 8sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 32sthe patch passed with JDK v1.8.0_232
+1 💚javadoc0m 45sthe patch passed with JDK v1.7.0_242
+1 💚findbugs3m 17sthe patch passed
_ Other Tests _
+1 💚unit129m 22shbase-server in the patch passed.
+1 💚asflicense0m 31sThe patch does not generate ASF License warnings.
183m 15s
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/2/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux 32b4f202dd2f 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 28673f0
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
checkstylehttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/2/artifact/out/diff-checkstyle-hbase-server.txt
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/2/testReport/
Max. process+thread count4394 (vs. ulimit of 10000)
modulesC: hbase-server U: hbase-server
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/2/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@mnpoonia

mnpoonia commented Dec 17, 2019

Copy link
Copy Markdown
ContributorAuthor

Another thought, the main structure for computePlanForTable looks very similar to the one from SimpleRegionNormalizer. Would it be too difficult to refactor _SimpleRegionNormalizer so that both normalizer implementations could make most of code reuse?

After giving it a thought i believe we should have two normalizers one which splits and second which merges and may be third SimpleRegionNormalizer which uses these two and together.
And to reuse code maybe we can have a utility class for normalizer which contains only pure methods which will help other normalization implementations.
@wchevreuil
An example mnpoonia@b8489d5

@mnpoonia

Copy link
Copy Markdown
ContributorAuthor

Also i will make the MIN_DURATION_FOR_MERGE configurable.
@apurtell - FYI

@wchevreuil

Copy link
Copy Markdown
Contributor

After giving it a thought i believe we should have two normalizers one which splits and second which merges and may be third SimpleRegionNormalizer which uses these two and together.
And to reuse code maybe we can have a utility class for normalizer which contains only pure methods which will help other normalization implementations.

I'm not sure moving logic to an util class is a good design practice. Here I think we could probably do a strategy pattern: An abstract normalizer class implementing most of computePlanForTable logic, with only the parts related to picking a region to the region plan and what actions should be perfomed over the region plan (merge, or split, or both) being delegated to methods that would be implemented differently on each of the subclasses.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 37sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
-1 ❌hbaseanti0m 0sThe patch appears use Hadoop classification instead of HBase.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 1 new or modified test files.
_ branch-1 Compile Tests _
+1 💚mvninstall8m 44sbranch-1 passed
+1 💚compile0m 39sbranch-1 passed with JDK v1.8.0_232
+1 💚compile0m 44sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle1m 34sbranch-1 passed
+1 💚shadedjars2m 51sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 37sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc0m 42sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs2m 54sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs2m 52sbranch-1 passed
_ Patch Compile Tests _
+1 💚mvninstall2m 1sthe patch passed
+1 💚compile0m 39sthe patch passed with JDK v1.8.0_232
+1 💚javac0m 39sthe patch passed
+1 💚compile0m 44sthe patch passed with JDK v1.7.0_242
+1 💚javac0m 44sthe patch passed
+1 💚checkstyle1m 32sthe patch passed
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars2m 43spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck4m 59sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 29sthe patch passed with JDK v1.8.0_232
+1 💚javadoc0m 41sthe patch passed with JDK v1.7.0_242
+1 💚findbugs2m 49sthe patch passed
_ Other Tests _
+1 💚unit128m 39shbase-server in the patch passed.
+1 💚asflicense0m 32sThe patch does not generate ASF License warnings.
168m 37s
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/3/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux d75d0ccbe3ef 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 85b43a7
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/3/testReport/
Max. process+thread count4234 (vs. ulimit of 10000)
modulesC: hbase-server U: hbase-server
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/3/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

private static final int MIN_DURATION_FOR_MERGE = 2;

@Override
public List<NormalizationPlan> computePlanForTable(TableName table) throws HBaseIOException {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we implement all common parts of computePlanForTable in the base parent class, then only merge or split normalizer specifc logic would need to go on the implementations?

Comment on lines +77 to +84
if (isOldEnoughToMerge(hri) || isOldEnoughToMerge(hri2)) {
LOG.info(
"Table {}, small region size: {} plus its neighbor size: {}, less than the avg size "
+ "{}, merging them",
table, regionSize, regionSize2, avgRegionSize);
plans.add(new MergeNormalizationPlan(hri, hri2));
candidateIdx++;
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For example, this could go to a separate, abstract method computeNormalization in the base parent class, then MergeNormalizer would implement it as it is now, and SimpleRegionNormalizer would do it the way it does now.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 0sDocker mode activated.
-1 ❌docker5m 51sDocker failed to build yetus/hbase:41990ba20a.
SubsystemReport/Notes
GITHUB PR#931
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/4/console
versionsgit=2.17.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

RequestConverter.buildIsSplitOrMergeEnabledRequest(Admin.MasterSwitchType.MERGE))
.getEnabled();
} catch (ServiceException se) {
LOG.debug("Unable to determine whether merge is enabled", se);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

want to convert this to error or warn log?

RequestConverter.buildIsSplitOrMergeEnabledRequest(Admin.MasterSwitchType.SPLIT))
.getEnabled();
} catch (ServiceException se) {
LOG.debug("Unable to determine whether merge is enabled", se);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARN it is. 😄

private static final Log LOG = LogFactory.getLog(SimpleRegionNormalizer.class);
public class SimpleRegionNormalizer extends BaseNormalizer {
private static final Logger LOG = LoggerFactory.getLogger(SimpleRegionNormalizer.class);
private static final int MIN_REGION_COUNT = 3;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MergeNormalizer and SimpleRegionNormalizer both can use same constant MIN_REGION_COUNT, may be good to move it to HConstant

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure about this yet. Let me think a bit. The point is that both normalizer can have different requirement for the MIN_REGION_COUNT. But then we can't have both normalizer enabled together.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, also this is mostly same constant. if we want to use configs for these values(which we don't want I believe), then we could use it separately but here, may be we can refer to same constant.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec1m 42sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
-1 ❌hbaseanti0m 0sThe patch appears use Hadoop classification instead of HBase.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 3 new or modified test files.
_ branch-1 Compile Tests _
+0 🆗mvndep1m 24sMaven dependency ordering for branch
+1 💚mvninstall7m 32sbranch-1 passed
+1 💚compile1m 4sbranch-1 passed with JDK v1.8.0_232
+1 💚compile1m 10sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle2m 11sbranch-1 passed
+1 💚shadedjars2m 59sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 52sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc1m 10sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs2m 49sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs3m 57sbranch-1 passed
_ Patch Compile Tests _
+0 🆗mvndep0m 17sMaven dependency ordering for patch
+1 💚mvninstall2m 0sthe patch passed
+1 💚compile1m 5sthe patch passed with JDK v1.8.0_232
+1 💚javac1m 5sthe patch passed
+1 💚compile1m 13sthe patch passed with JDK v1.7.0_242
+1 💚javac1m 13sthe patch passed
+1 💚checkstyle0m 33sThe patch passed checkstyle in hbase-common
+1 💚checkstyle1m 40shbase-server: The patch generated 0 new + 4 unchanged - 2 fixed = 4 total (was 6)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars3m 2spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck5m 20sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 52sthe patch passed with JDK v1.8.0_232
+1 💚javadoc1m 7sthe patch passed with JDK v1.7.0_242
-1 ❌findbugs3m 13shbase-server generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
_ Other Tests _
+1 💚unit2m 49shbase-common in the patch passed.
+1 💚unit126m 22shbase-server in the patch passed.
+1 💚asflicense0m 56sThe patch does not generate ASF License warnings.
179m 56s
ReasonTests
FindBugsmodule:hbase-server
Dead store to entries in org.apache.hadoop.hbase.master.normalizer.MergeNormalizer.getMinimumDurationBeforeMerge() At MergeNormalizer.java:org.apache.hadoop.hbase.master.normalizer.MergeNormalizer.getMinimumDurationBeforeMerge() At MergeNormalizer.java:[line 131]
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/5/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux 82b2a708c4c9 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 27fc96e
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
findbugshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/5/artifact/out/new-findbugs-hbase-server.html
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/5/testReport/
Max. process+thread count4214 (vs. ulimit of 10000)
modulesC: hbase-common hbase-server U: .
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/5/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 38sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
-1 ❌hbaseanti0m 0sThe patch appears use Hadoop classification instead of HBase.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 3 new or modified test files.
_ branch-1 Compile Tests _
+0 🆗mvndep1m 22sMaven dependency ordering for branch
+1 💚mvninstall7m 19sbranch-1 passed
+1 💚compile1m 0sbranch-1 passed with JDK v1.8.0_232
+1 💚compile1m 6sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle2m 1sbranch-1 passed
+1 💚shadedjars2m 54sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 53sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc1m 3sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs2m 39sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs3m 45sbranch-1 passed
_ Patch Compile Tests _
+0 🆗mvndep0m 16sMaven dependency ordering for patch
+1 💚mvninstall1m 59sthe patch passed
+1 💚compile0m 58sthe patch passed with JDK v1.8.0_232
+1 💚javac0m 58sthe patch passed
+1 💚compile1m 6sthe patch passed with JDK v1.7.0_242
+1 💚javac1m 6sthe patch passed
+1 💚checkstyle0m 29sThe patch passed checkstyle in hbase-common
+1 💚checkstyle1m 28shbase-server: The patch generated 0 new + 0 unchanged - 6 fixed = 0 total (was 6)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars2m 44spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck5m 0sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 52sthe patch passed with JDK v1.8.0_232
+1 💚javadoc1m 6sthe patch passed with JDK v1.7.0_242
-1 ❌findbugs2m 54shbase-server generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
_ Other Tests _
+1 💚unit2m 51shbase-common in the patch passed.
-1 ❌unit125m 39shbase-server in the patch failed.
+1 💚asflicense0m 56sThe patch does not generate ASF License warnings.
175m 43s
ReasonTests
FindBugsmodule:hbase-server
Dead store to entries in org.apache.hadoop.hbase.master.normalizer.MergeNormalizer.getMinimumDurationBeforeMerge() At MergeNormalizer.java:org.apache.hadoop.hbase.master.normalizer.MergeNormalizer.getMinimumDurationBeforeMerge() At MergeNormalizer.java:[line 111]
Failed junit testshadoop.hbase.master.TestMasterMetrics
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/6/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux 19d523ff1edd 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 27fc96e
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
findbugshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/6/artifact/out/new-findbugs-hbase-server.html
unithttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/6/artifact/out/patch-unit-hbase-server.txt
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/6/testReport/
Max. process+thread count4154 (vs. ulimit of 10000)
modulesC: hbase-common hbase-server U: .
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/6/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 41sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
-1 ❌hbaseanti0m 0sThe patch appears use Hadoop classification instead of HBase.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 3 new or modified test files.
_ branch-1 Compile Tests _
+0 🆗mvndep1m 22sMaven dependency ordering for branch
+1 💚mvninstall7m 22sbranch-1 passed
+1 💚compile1m 1sbranch-1 passed with JDK v1.8.0_232
+1 💚compile1m 7sbranch-1 passed with JDK v1.7.0_242
+1 💚checkstyle2m 10sbranch-1 passed
+1 💚shadedjars2m 58sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 51sbranch-1 passed with JDK v1.8.0_232
+1 💚javadoc1m 7sbranch-1 passed with JDK v1.7.0_242
+0 🆗spotbugs2m 45sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs3m 54sbranch-1 passed
_ Patch Compile Tests _
+0 🆗mvndep0m 19sMaven dependency ordering for patch
+1 💚mvninstall2m 4sthe patch passed
+1 💚compile0m 59sthe patch passed with JDK v1.8.0_232
+1 💚javac0m 59sthe patch passed
+1 💚compile1m 9sthe patch passed with JDK v1.7.0_242
+1 💚javac1m 8sthe patch passed
+1 💚checkstyle0m 29sThe patch passed checkstyle in hbase-common
+1 💚checkstyle1m 37shbase-server: The patch generated 0 new + 0 unchanged - 6 fixed = 0 total (was 6)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars2m 48spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck5m 16sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 50sthe patch passed with JDK v1.8.0_232
+1 💚javadoc1m 6sthe patch passed with JDK v1.7.0_242
+1 💚findbugs4m 11sthe patch passed
_ Other Tests _
+1 💚unit2m 34shbase-common in the patch passed.
-1 ❌unit127m 14shbase-server in the patch failed.
+1 💚asflicense0m 53sThe patch does not generate ASF License warnings.
178m 2s
ReasonTests
Failed junit testshadoop.hbase.security.token.TestGenerateDelegationToken
SubsystemReport/Notes
DockerClient=19.03.5 Server=19.03.5 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/7/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux daf16f1c9047 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 27fc96e
Default Java1.7.0_242
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_232 /usr/lib/jvm/zulu-7-amd64:1.7.0_242
unithttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/7/artifact/out/patch-unit-hbase-server.txt
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/7/testReport/
Max. process+thread count4412 (vs. ulimit of 10000)
modulesC: hbase-common hbase-server U: .
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/7/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.


int candidateIdx = 0;
while (candidateIdx < tableRegions.size()) {
if (candidateIdx == tableRegions.size() - 1) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can get rid of this if condition with while( candidateIdx < tableRegions.size()-1 )

plans.add(new MergeNormalizationPlan(hri, hri2));
candidateIdx++;
} else {
LOG.debug("Skipping region {} of table {} with size {}", hri.getRegionId(), table,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of regionId, may be good to print region name with hri.getRegionNameAsString()

if (splitEnabled) {
List<NormalizationPlan> splitNormalizationPlan = getSplitNormalizationPlan(table);
if (splitNormalizationPlan != null) {
plans = splitNormalizationPlan;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To keep it aligned with mergeNormalization, here also, it's good to add all: plans.addAll(splitNormalizationPlan)

}
}
if (mergeEnabled) {
List<NormalizationPlan> normalizationPlans = getMergeNormalizationPlan(table);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: rename to mergeNormalizationPlans?

private boolean shouldNormalize(TableName table) {
boolean normalize = false;
if (table == null || table.isSystemTable()) {
LOG.debug("Normalization of system table {} isn't allowed", table);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think table could be null here, and we can remove null check from this if condition. Even if null was possible, log message would not be appropriate: Normalization of system table null isn't allowed

@Apache-HBase

Copy link
Copy Markdown

💔 -1 overall

VoteSubsystemRuntimeComment
+0 🆗reexec0m 48sDocker mode activated.
_ Prechecks _
+1 💚dupname0m 0sNo case conflicting files found.
-1 ❌hbaseanti0m 0sThe patch appears use Hadoop classification instead of HBase.
+1 💚@author0m 0sThe patch does not contain any @author tags.
+1 💚test4tests0m 0sThe patch appears to include 3 new or modified test files.
_ branch-1 Compile Tests _
+0 🆗mvndep2m 23sMaven dependency ordering for branch
+1 💚mvninstall7m 56sbranch-1 passed
+1 💚compile0m 58sbranch-1 passed with JDK v1.8.0_252
+1 💚compile1m 6sbranch-1 passed with JDK v1.7.0_262
+1 💚checkstyle2m 12sbranch-1 passed
+1 💚shadedjars3m 1sbranch has no errors when building our shaded downstream artifacts.
+1 💚javadoc0m 59sbranch-1 passed with JDK v1.8.0_252
+1 💚javadoc1m 7sbranch-1 passed with JDK v1.7.0_262
+0 🆗spotbugs2m 59sUsed deprecated FindBugs config; considering switching to SpotBugs.
+1 💚findbugs4m 15sbranch-1 passed
_ Patch Compile Tests _
+0 🆗mvndep0m 17sMaven dependency ordering for patch
+1 💚mvninstall2m 2sthe patch passed
+1 💚compile1m 6sthe patch passed with JDK v1.8.0_252
+1 💚javac1m 6sthe patch passed
+1 💚compile1m 13sthe patch passed with JDK v1.7.0_262
+1 💚javac1m 13sthe patch passed
+1 💚checkstyle0m 28sThe patch passed checkstyle in hbase-common
+1 💚checkstyle1m 33shbase-server: The patch generated 0 new + 0 unchanged - 6 fixed = 0 total (was 6)
+1 💚whitespace0m 0sThe patch has no whitespace issues.
+1 💚shadedjars2m 58spatch has no errors when building our shaded downstream artifacts.
+1 💚hadoopcheck4m 53sPatch does not cause any errors with Hadoop 2.8.5 2.9.2.
+1 💚javadoc0m 50sthe patch passed with JDK v1.8.0_252
+1 💚javadoc1m 9sthe patch passed with JDK v1.7.0_262
+1 💚findbugs4m 28sthe patch passed
_ Other Tests _
+1 💚unit2m 40shbase-common in the patch passed.
-1 ❌unit136m 20shbase-server in the patch failed.
+1 💚asflicense0m 54sThe patch does not generate ASF License warnings.
189m 32s
ReasonTests
Failed junit testshadoop.hbase.master.TestWarmupRegion
SubsystemReport/Notes
DockerClient=19.03.9 Server=19.03.9 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/Dockerfile
GITHUB PR#931
Optional Testsdupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
unameLinux f839211cc491 4.15.0-58-generic #64-Ubuntu SMP Tue Aug 6 11:12:41 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build toolmaven
Personality/home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-931/out/precommit/personality/provided.sh
git revisionbranch-1 / 3235b56
Default Java1.7.0_262
Multi-JDK versions/usr/lib/jvm/zulu-8-amd64:1.8.0_252 /usr/lib/jvm/zulu-7-amd64:1.7.0_262
unithttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/artifact/out/patch-unit-hbase-server.txt
Test Resultshttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/testReport/
Max. process+thread count4430 (vs. ulimit of 10000)
modulesC: hbase-common hbase-server U: .
Console outputhttps://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-931/1/console
versionsgit=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered byApache Yetus 0.11.1 https://yetus.apache.org

This message was automatically generated.

@mnpoonia
mnpoonia deleted the HBASE-22285 branch August 30, 2020 16:08
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@mnpoonia@Apache-HBase@wchevreuil@virajjasani