Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HBASE-23205 Correctly update the position of WALs currently being replicated #749

Closed
wants to merge 52 commits into from

Conversation

JeongDaeKim
Copy link

@JeongDaeKim JeongDaeKim commented Oct 23, 2019

https://issues.apache.org/jira/browse/HBASE-23205

I fixed a failed test which is not related with this PR. TestReplicationSmallTests.testEmptyWALRecovery,
and a minor bug which is updating replication buffer size wrongly by decreasing total buffer size with the size of bulk loaded files.

I removed the changes above and made a separate jira : https://issues.apache.org/jira/browse/HBASE-23254

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
💙 reexec 0m 49s Docker mode activated.
_ Prechecks _
💚 dupname 0m 0s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 9m 27s branch-1 passed
💚 compile 0m 50s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 52s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 1m 51s branch-1 passed
💚 shadedjars 3m 26s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 42s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 51s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 15s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 11s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 19s the patch passed
💚 compile 0m 48s the patch passed with JDK v1.8.0_232
💚 javac 0m 48s the patch passed
💚 compile 0m 49s the patch passed with JDK v1.7.0_242
💚 javac 0m 49s the patch passed
💔 checkstyle 1m 46s hbase-server: The patch generated 30 new + 44 unchanged - 10 fixed = 74 total (was 54)
💚 whitespace 0m 1s The patch has no whitespace issues.
💚 shadedjars 3m 10s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 30s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 40s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 46s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 30s the patch passed
_ Other Tests _
💔 unit 30m 44s hbase-server in the patch failed.
💚 asflicense 0m 20s The patch does not generate ASF License warnings.
76m 33s
Reason Tests
Failed junit tests hadoop.hbase.master.TestCatalogJanitor
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/1/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux aa16fec098c2 4.15.0-60-generic #67-Ubuntu SMP Thu Aug 22 16:55:30 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / ce65db3
Default Java 1.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
checkstyle https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/1/artifact/out/diff-checkstyle-hbase-server.txt
unit https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/1/artifact/out/patch-unit-hbase-server.txt
Test Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/1/testReport/
Max. process+thread count 740 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/1/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

@JeongDaeKim
Copy link
Author

JeongDaeKim commented Oct 24, 2019

Failed tests are not related to this PR. Tests has broken since #731, and Those will be fixed at #748.

image

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
💙 reexec 0m 41s Docker mode activated.
_ Prechecks _
💚 dupname 0m 0s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 25s branch-1 passed
💚 compile 0m 45s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 46s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 1m 48s branch-1 passed
💚 shadedjars 3m 10s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 44s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 43s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 9s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 4s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 5s the patch passed
💚 compile 0m 41s the patch passed with JDK v1.8.0_232
💚 javac 0m 41s the patch passed
💚 compile 0m 47s the patch passed with JDK v1.7.0_242
💚 javac 0m 47s the patch passed
💚 checkstyle 1m 44s hbase-server: The patch generated 0 new + 41 unchanged - 13 fixed = 41 total (was 54)
💚 whitespace 0m 0s The patch has no whitespace issues.
💚 shadedjars 3m 4s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 8s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 30s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 42s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 5s the patch passed
_ Other Tests _
💔 unit 139m 44s hbase-server in the patch failed.
💚 asflicense 0m 29s The patch does not generate ASF License warnings.
181m 50s
Reason Tests
Failed junit tests hadoop.hbase.replication.TestReplicationKillMasterRS
hadoop.hbase.replication.multiwal.TestReplicationSyncUpToolWithMultipleWAL
hadoop.hbase.replication.regionserver.TestGlobalReplicationThrottler
hadoop.hbase.replication.TestReplicationSyncUpTool
hadoop.hbase.replication.TestReplicationMetricsforUI
hadoop.hbase.replication.TestPerTableCFReplication
hadoop.hbase.replication.TestReplicationConfigTracker
hadoop.hbase.replication.TestVerifyCellsReplicationEndpoint
hadoop.hbase.replication.TestReplicationSyncUpToolWithBulkLoadedData
hadoop.hbase.security.visibility.TestVisibilityLabelReplicationWithExpAsString
hadoop.hbase.replication.multiwal.TestReplicationKillMasterRSCompressedWithMultipleWAL
hadoop.hbase.regionserver.TestRegionReplicaFailover
hadoop.hbase.replication.TestReplicationDisableInactivePeer
hadoop.hbase.replication.TestReplicationStatus
hadoop.hbase.replication.TestReplicationSmallTests
hadoop.hbase.replication.TestReplicationKillSlaveRS
hadoop.hbase.security.visibility.TestVisibilityLabelsReplication
hadoop.hbase.replication.multiwal.TestReplicationEndpointWithMultipleWAL
hadoop.hbase.regionserver.TestBulkLoadReplication
hadoop.hbase.replication.TestReplicationWithTags
hadoop.hbase.replication.TestReplicationEndpoint
hadoop.hbase.replication.TestMultiSlaveReplication
hadoop.hbase.replication.TestReplicationKillMasterRSCompressed
hadoop.hbase.client.replication.TestReplicationAdminWithClusters
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/2/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux aa4ca70f49f8 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / f0999a1
Default Java 1.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
unit https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/2/artifact/out/patch-unit-hbase-server.txt
Test Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/2/testReport/
Max. process+thread count 3803 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/2/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

@JeongDaeKim
Copy link
Author

I made a typo when i fixed checkstyle warnings 😭 (a8244d2#diff-7d551f2261f4c83aec8a97b7d04427e2R137)

Let me fix it.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
💙 reexec 0m 35s Docker mode activated.
_ Prechecks _
💚 dupname 0m 1s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 29s branch-1 passed
💚 compile 0m 44s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 49s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 2m 2s branch-1 passed
💚 shadedjars 3m 50s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 44s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 48s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 56s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 53s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 35s the patch passed
💚 compile 1m 3s the patch passed with JDK v1.8.0_232
💚 javac 1m 3s the patch passed
💚 compile 1m 2s the patch passed with JDK v1.7.0_242
💚 javac 1m 2s the patch passed
💚 checkstyle 2m 3s hbase-server: The patch generated 0 new + 41 unchanged - 13 fixed = 41 total (was 54)
💚 whitespace 0m 1s The patch has no whitespace issues.
💚 shadedjars 3m 32s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 6m 2s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 39s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 57s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 56s the patch passed
_ Other Tests _
💔 unit 134m 14s hbase-server in the patch failed.
💚 asflicense 0m 27s The patch does not generate ASF License warnings.
182m 37s
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/3/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux 4e1244156651 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / 41f6713
Default Java 1.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
unit https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/3/artifact/out/patch-unit-hbase-server.txt
Test Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/3/testReport/
Max. process+thread count 3832 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/3/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

@JeongDaeKim
Copy link
Author

added a minor fix in test code and rebased.

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
💙 reexec 10m 24s Docker mode activated.
_ Prechecks _
💚 dupname 0m 0s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 35s branch-1 passed
💚 compile 0m 47s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 50s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 2m 2s branch-1 passed
💚 shadedjars 3m 35s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 45s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 48s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 36s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 32s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 25s the patch passed
💚 compile 0m 47s the patch passed with JDK v1.8.0_232
💚 javac 0m 47s the patch passed
💚 compile 0m 51s the patch passed with JDK v1.7.0_242
💚 javac 0m 51s the patch passed
💚 checkstyle 1m 52s hbase-server: The patch generated 0 new + 41 unchanged - 13 fixed = 41 total (was 54)
💚 whitespace 0m 0s The patch has no whitespace issues.
💚 shadedjars 3m 34s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 52s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 38s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 48s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 45s the patch passed
_ Other Tests _
💚 unit 120m 32s hbase-server in the patch passed.
💚 asflicense 0m 27s The patch does not generate ASF License warnings.
176m 55s
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/4/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux 840d003e793d 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / 5e414f2
Default Java 1.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 Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/4/testReport/
Max. process+thread count 3894 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/4/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

Copy link
Contributor

@wchevreuil wchevreuil left a comment

Choose a reason for hiding this comment

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

Thanks for the analysis. Had done a first round of reading through, but the PR seems a bit large to grasp it all in one go, hence some of the question in my comments.

It would be nice to keep changes to a minimal, adding only modifications really needed to fix the problem. For example, there are few variable/method renaming, moving to different class, just for personal/cosmetic preferences, together with additional unrelated fixes, such as the mentioned metric one (if that's not needed here, please open a separate jira to it).

break;
}
}
} else {
Copy link
Contributor

Choose a reason for hiding this comment

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

Where is the log position getting updated now if the current edit is not targeted to replication?

Copy link
Author

Choose a reason for hiding this comment

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

I tried not to update log position every single filtered entry. because I found a lot of updates (setData) happened in zookeeper tx logs, even though all entries were filtered.

log position will be updated in these case.

  1. limits(quota, size, count) reached, or a batch has entries when eof reached.
  2. wal rolled
  3. when reader read all wals in recovery queue.

I think updating log position is required for 1) cleanup old logs, 2) replication queue recovery.
for 1) it would be enough to update log position only when log rolled.
for 2) the log position should be updated to the position of the last replicated entry.

in any case, we don't need to update log position aggressively for filtered entries. entries would be filtered again for recovery case.

Copy link
Contributor

Choose a reason for hiding this comment

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

So if a filtered edit came, any sub-sequent non-filterable one would need to wait for a log roll? That could take too long for some use cases.

Copy link
Author

Choose a reason for hiding this comment

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

any sub-sequent non-filterable one would need to wait for a log roll? That could take too long for some use cases.

If some use cases means "no mutations come for a long time, but a batch has entries", this case is the one of the 1) case i mentioned a batch has entries when eof reached. reader would reach the eof, and log position would be updated.

In addition, even while testing this issue with heavy writes, I observed the reader frequently reached EOF.

Copy link
Contributor

Choose a reason for hiding this comment

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

If some use cases means "no mutations come for a long time, but a batch has entries"

What if the whole WAL section read got no entries for replication? In this case, batch would be empty, so ReplicationSourceManager.logPositionAndCleanOldLogs does not ever get called (at least, I guess, until the log is rolled).

Copy link
Contributor

Choose a reason for hiding this comment

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

I think the answer to my question above is in the resetStream() that gets called at the end of the second while loop, which will update lastReadPosition variable that is now used for reading here.

Copy link
Author

Choose a reason for hiding this comment

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

What if the whole WAL section read got no entries for replication? In this case, batch would be empty, so ReplicationSourceManager.logPositionAndCleanOldLogs does not ever get called (at least, I guess, until the log is rolled).

Yes, In that case, the position will be updated when log rolled. That is my intention. #749 (comment)

I think the answer to my question above is in the resetStream() that gets called at the end of the second while loop, which will update lastReadPosition variable that is now used for reading here.

Oh? Then, I think i didn't understand what your question is. 🤣

Copy link
Contributor

Choose a reason for hiding this comment

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

I guess this is fine for the replication progress problem. One additional issue, though, is regarding monitoring. IIRC, DumpReplicationQueues relies on replication info available at ZK, so now it may not show an accurate position for the log queue. We may need to expose ReplicationSourceWALReaderThread.lastReadPosition via getter method for monitoring purposes.

@@ -378,37 +380,35 @@ public void testReplicationSourceWALReaderThread() throws Exception {
}

@Test
public void testReplicationSourceUpdatesLogPositionOnFilteredEntries() throws Exception {
public void testReplicationSourceWALReaderThreadRecoveredQueue() throws Exception {
Copy link
Contributor

Choose a reason for hiding this comment

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

Why this test has been changed from it's original purpose of checking for upating wal position when no edits targeted to replication are read? Also the name does not seem accurate, it does not seem to create a recovered queue scenario.

Copy link
Author

Choose a reason for hiding this comment

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

I removed testReplicationSourceUpdatesLogPositionOnFilteredEntries, because the behavior of the reader is changed. (no updates every filtered entry).

And, i made recovered queue scenario by setting queue info as recovered queue. getQueueInfo("1-1")
https://github.com/apache/hbase/pull/749/files/114aa1b1a7b9919c5429fadcb74079cd08629513#diff-05e8e2a626166f52e5737f8bcdc49e39R401

If it is not well recognized as intended, let me add comments or getRecoveredQueueInfo()?

Copy link
Author

Choose a reason for hiding this comment

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

I changed the method name to getRecoveredQueueInfo()

Copy link
Contributor

Choose a reason for hiding this comment

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

Actually yeah, this is indeed simulating recovered queue when creating it as recovered. I think this test is fine.

Signed-off-by: Wellington Chevreuil <wchevreuil@apache.org>
@JeongDaeKim
Copy link
Author

Thanks for the review!

there are few variable/method renaming, moving to different class, just for personal/cosmetic preferences

I see. I'll make my changes smaller to remain only necessary ones.

together with additional unrelated fixes, such as the mentioned metric one (if that's not needed here, please open a separate jira to it).

Let me file a new jira then 👍

@Apache-HBase
Copy link

🎊 +1 overall

Vote Subsystem Runtime Comment
💙 reexec 0m 35s Docker mode activated.
_ Prechecks _
💚 dupname 0m 0s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 26s branch-1 passed
💚 compile 0m 42s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 48s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 1m 47s branch-1 passed
💚 shadedjars 3m 9s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 36s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 42s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 3s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 1s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 5s the patch passed
💚 compile 0m 41s the patch passed with JDK v1.8.0_232
💚 javac 0m 41s the patch passed
💚 compile 0m 46s the patch passed with JDK v1.7.0_242
💚 javac 0m 46s the patch passed
💚 checkstyle 1m 41s hbase-server: The patch generated 0 new + 42 unchanged - 12 fixed = 42 total (was 54)
💚 whitespace 0m 0s The patch has no whitespace issues.
💚 shadedjars 3m 7s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 11s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 30s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 42s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 6s the patch passed
_ Other Tests _
💚 unit 118m 17s hbase-server in the patch passed.
💚 asflicense 0m 28s The patch does not generate ASF License warnings.
159m 54s
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/5/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux f4a65f785f70 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / 4bcc397
Default Java 1.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 Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/5/testReport/
Max. process+thread count 3765 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/5/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

wchevreuil and others added 6 commits October 31, 2019 17:11
…CallableWithReplicas (apache#780)

Signed-off-by: Sean Busbey <busbey@apache.org>
…alue every time [Take2] (apache#748)

* HBASE-23185 Fix test failure by HBASE-23185 changes

* HBASE-23185 Fix high cpu usage because getTable()#put() gets config value every time

This reverts commit db2ce23.
Signed-off-by: Andrew Purtell <apurtell@apache.org>
…che#789)

Signed-off-by: Sean Busbey <busbey@apache.org>
Signed-off-by: Guangxu Cheng <guangxucheng@gmail.com>
@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
💙 reexec 9m 52s Docker mode activated.
_ Prechecks _
💚 dupname 0m 0s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 33s branch-1 passed
💚 compile 0m 40s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 47s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 1m 47s branch-1 passed
💚 shadedjars 3m 7s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 37s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 42s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 4s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 3m 0s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 5s the patch passed
💚 compile 0m 42s the patch passed with JDK v1.8.0_232
💚 javac 0m 42s the patch passed
💚 compile 0m 47s the patch passed with JDK v1.7.0_242
💚 javac 0m 47s the patch passed
💔 checkstyle 1m 44s hbase-server: The patch generated 1 new + 42 unchanged - 12 fixed = 43 total (was 54)
💚 whitespace 0m 0s The patch has no whitespace issues.
💚 shadedjars 3m 4s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 10s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 31s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 42s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 7s the patch passed
_ Other Tests _
💚 unit 119m 47s hbase-server in the patch passed.
💚 asflicense 0m 27s The patch does not generate ASF License warnings.
170m 44s
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/6/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux e4ff635ca663 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / 3f9ce86
Default Java 1.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
checkstyle https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/6/artifact/out/diff-checkstyle-hbase-server.txt
Test Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/6/testReport/
Max. process+thread count 3964 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/6/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

@Apache-HBase
Copy link

💔 -1 overall

Vote Subsystem Runtime Comment
💙 reexec 0m 35s Docker mode activated.
_ Prechecks _
💚 dupname 0m 1s No case conflicting files found.
💚 hbaseanti 0m 0s Patch does not have any anti-patterns.
💚 @author 0m 0s The patch does not contain any @author tags.
💚 test4tests 0m 0s The patch appears to include 4 new or modified test files.
_ branch-1 Compile Tests _
💚 mvninstall 8m 28s branch-1 passed
💚 compile 0m 41s branch-1 passed with JDK v1.8.0_232
💚 compile 0m 48s branch-1 passed with JDK v1.7.0_242
💚 checkstyle 1m 47s branch-1 passed
💚 shadedjars 3m 8s branch has no errors when building our shaded downstream artifacts.
💚 javadoc 0m 37s branch-1 passed with JDK v1.8.0_232
💚 javadoc 0m 41s branch-1 passed with JDK v1.7.0_242
💙 spotbugs 3m 2s Used deprecated FindBugs config; considering switching to SpotBugs.
💚 findbugs 2m 58s branch-1 passed
_ Patch Compile Tests _
💚 mvninstall 2m 5s the patch passed
💚 compile 0m 40s the patch passed with JDK v1.8.0_232
💚 javac 0m 40s the patch passed
💚 compile 0m 48s the patch passed with JDK v1.7.0_242
💚 javac 0m 48s the patch passed
💚 checkstyle 1m 44s hbase-server: The patch generated 0 new + 42 unchanged - 12 fixed = 42 total (was 54)
💚 whitespace 0m 0s The patch has no whitespace issues.
💚 shadedjars 3m 4s patch has no errors when building our shaded downstream artifacts.
💚 hadoopcheck 5m 8s Patch does not cause any errors with Hadoop 2.8.5 2.9.2.
💚 javadoc 0m 30s the patch passed with JDK v1.8.0_232
💚 javadoc 0m 42s the patch passed with JDK v1.7.0_242
💚 findbugs 3m 7s the patch passed
_ Other Tests _
💔 unit 121m 10s hbase-server in the patch failed.
💚 asflicense 0m 27s The patch does not generate ASF License warnings.
162m 39s
Reason Tests
Failed junit tests hadoop.hbase.client.TestReplicasClient
Subsystem Report/Notes
Docker Client=19.03.4 Server=19.03.4 base: https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/7/artifact/out/Dockerfile
GITHUB PR #749
Optional Tests dupname asflicense javac javadoc unit spotbugs findbugs shadedjars hadoopcheck hbaseanti checkstyle compile
uname Linux 65d46fa7b0b2 4.15.0-66-generic #75-Ubuntu SMP Tue Oct 1 05:24:09 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality /home/jenkins/jenkins-slave/workspace/HBase-PreCommit-GitHub-PR_PR-749/out/precommit/personality/provided.sh
git revision branch-1 / 3f9ce86
Default Java 1.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
unit https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/7/artifact/out/patch-unit-hbase-server.txt
Test Results https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/7/testReport/
Max. process+thread count 3887 (vs. ulimit of 10000)
modules C: hbase-server U: hbase-server
Console output https://builds.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-749/7/console
versions git=1.9.1 maven=3.0.5 findbugs=3.0.1
Powered by Apache Yetus 0.11.0 https://yetus.apache.org

This message was automatically generated.

…ould be at INFO

Signed-off-by: Jan Hentschel <jan.hentschel@ultratendency.com>
@JeongDaeKim
Copy link
Author

JeongDaeKim commented Nov 6, 2019

image

The failed test seems not related to this pr. (It failed after a commit just adding a new line), and I can't reproduce it in my local repo.

I think PR is ready to get review. please have a look. @wchevreuil

@JeongDaeKim
Copy link
Author

No further comments on this PR? If any lacks of description or something for code reviews, please let me know. If not, I just want this PR to be merged, and backported to 1.4.

@wchevreuil Do you still have something to be changed in this PR?

@wchevreuil
Copy link
Contributor

Hi @JeongDaeKim , apologies for the delay. I think the solution is good, but since this is changing considerably how we track log reading position, am just taking a conservative approach. I would like to do a bit of testing. Please give me until end of this week to approve it, or suggest changes.

Copy link
Contributor

@wchevreuil wchevreuil left a comment

Choose a reason for hiding this comment

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

Thanks for your patience, @JeongDaeKim ! I think I finally got a better understanding of the chages logic, along with the new and modified tests. I had put on some additional comments within the code, but some additional thoughts:

  1. We might want to expose ReplicationSourceWALReaderThread.lastReadPosition, in order to eventually have an accurate monitoring info. Currently we have _DumpReplicationQueues` which just reads info from ZK. Maybe we should print a warning there that reported log position may not be accurate.
  2. Can we add a 3rd test on TestWalEntryStream that adds few filterable entries, then adds a non filterable one, and checks if this non filterable comes in from the batch?

@@ -378,37 +380,35 @@ public void testReplicationSourceWALReaderThread() throws Exception {
}

@Test
public void testReplicationSourceUpdatesLogPositionOnFilteredEntries() throws Exception {
public void testReplicationSourceWALReaderThreadRecoveredQueue() throws Exception {
Copy link
Contributor

Choose a reason for hiding this comment

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

Actually yeah, this is indeed simulating recovered queue when creating it as recovered. I think this test is fine.

break;
}
}
} else {
Copy link
Contributor

Choose a reason for hiding this comment

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

I guess this is fine for the replication progress problem. One additional issue, though, is regarding monitoring. IIRC, DumpReplicationQueues relies on replication info available at ZK, so now it may not show an accurate position for the log queue. We may need to expose ReplicationSourceWALReaderThread.lastReadPosition via getter method for monitoring purposes.

Comment on lines 461 to 470
// reader won't put any batch, even if EOF reached.
ExecutorService executor = Executors.newSingleThreadExecutor();
Future<WALEntryBatch> future = executor.submit(new Callable<WALEntryBatch>() {
@Override
public WALEntryBatch call() throws Exception {
return reader.take();
}
});
Thread.sleep(2000);
assertFalse(future.isDone());
Copy link
Contributor

Choose a reason for hiding this comment

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

Just a heads up here: we may simplify this part if we decide to make ReplicationSourceWALReaderThread.lastReadPosition exposed via getter method.

Copy link
Author

Choose a reason for hiding this comment

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

👍

busbey and others added 7 commits December 3, 2019 23:03
)

- switch to nexus-staging-maven-plugin for asf-release
- cleaned up some tabs in the root pom

(differs from master because there are no release scripts here.)

Signed-off-by: stack <stack@apache.org>
(cherry picked from commit 97e0107)
…ction disabled in branch-1 (apache#899)

Signed-off-by: Balazs Meszaros <meszibalu@apache.org>
Signed-off-by Anoop Sam John <anoopsamjohn@apache.org>
…File is a reference file

Signed-off-by: Lijin Bin <binlijin@apache.org>
… to a capacity rule (apache#894)

Signed-off-by Wellington Chevreuil <wchevreuil@apache.org>
We have this nice description in the java doc on ITBLL but it's
unformatted and thus illegible. Add some formatting so that it can be
read by humans.

Signed-off-by: Jan Hentschel <janh@apache.org>
Signed-off-by: Josh Elser <elserj@apache.org>
@JeongDaeKim
Copy link
Author

We might want to expose ReplicationSourceWALReaderThread.lastReadPosition, in order to eventually have an accurate monitoring info. Currently we have _DumpReplicationQueues` which just reads info from ZK. Maybe we should print a warning there that reported log position may not be accurate

I think "reported log position" from DumpReplicationQueues could not be current read position before this PR (no updates during making a batch). DumpReplicationQueues works well for their purpose.
If we want to see lastReadPosition for monitoring, what about adding some messages to https://github.com/apache/hbase/blob/branch-1.4/hbase-server/src/main/java/org/apache/hadoop/hbase/replication/regionserver/ReplicationSource.java#L474

Can we add a 3rd test on TestWalEntryStream that adds few filterable entries, then adds a non filterable one, and checks if this non filterable comes in from the batch?

I see, added a new test

…pache#896)

Differs from original by removing Capacity Unit examples since that feature isn't on this branch.

(cherry picked from commit a553b78)
(cherry picked from commit 2a1efe0)
Copy link
Contributor

@wchevreuil wchevreuil left a comment

Choose a reason for hiding this comment

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

LGTM +1.

Let me try run the pre-commit hook before merging just to make sure.

@wchevreuil
Copy link
Contributor

No luck with the pre-commit. I tried a rebase, but still the job fails while starting. Ain't sure if it's something specific to the PR commits. @JeongDaeKim , would u mind squash these commits on one of you local branches, then open a new PR for branch-1 with this? Please ping me once you open the new PR.

@wchevreuil
Copy link
Contributor

Merged PR 944, so am closing this one. Thanks for the contribution and patience, @JeongDaeKim !

@wchevreuil wchevreuil closed this Jan 2, 2020
@JeongDaeKim JeongDaeKim deleted the HBASE-23205 branch January 3, 2020 07:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet