You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by hu...@apache.org on 2020/03/30 21:26:52 UTC
[hbase] branch branch-2.3 updated: HBASE-24073 [flakey test]
client.TestAsyncRegionAdminApi messed up compaction state. (#1387) (#1389)
(#1390)
This is an automated email from the ASF dual-hosted git repository.
huaxiangsun pushed a commit to branch branch-2.3
in repository https://gitbox.apache.org/repos/asf/hbase.git
The following commit(s) were added to refs/heads/branch-2.3 by this push:
new 076aa54 HBASE-24073 [flakey test] client.TestAsyncRegionAdminApi messed up compaction state. (#1387) (#1389) (#1390)
076aa54 is described below
commit 076aa545d8879c533919c220d18e0527f5abb158
Author: huaxiangsun <hu...@apache.org>
AuthorDate: Mon Mar 30 14:26:39 2020 -0700
HBASE-24073 [flakey test] client.TestAsyncRegionAdminApi messed up compaction state. (#1387) (#1389) (#1390)
Signed-off-by: Viraj Jasani <vj...@apache.org>
---
.../apache/hadoop/hbase/client/TestAsyncRegionAdminApi.java | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAsyncRegionAdminApi.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAsyncRegionAdminApi.java
index 38f19c4..4cb1174 100644
--- a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAsyncRegionAdminApi.java
+++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestAsyncRegionAdminApi.java
@@ -372,7 +372,18 @@ public class TestAsyncRegionAdminApi extends TestAsyncAdminBase {
byte[][] families =
{ family, Bytes.add(family, Bytes.toBytes("2")), Bytes.add(family, Bytes.toBytes("3")) };
createTableWithDefaultConf(tableName, null, families);
- loadData(tableName, families, 3000, flushes);
+
+ byte[][] singleFamilyArray = { family };
+
+ // When singleFamily is true, only load data for the family being tested. This is to avoid
+ // the case that while major compaction is going on for the family, minor compaction could
+ // happen for other families at the same time (Two compaction threads long/short), thus
+ // pollute the compaction and store file numbers for the region.
+ if (singleFamily) {
+ loadData(tableName, singleFamilyArray, 3000, flushes);
+ } else {
+ loadData(tableName, families, 3000, flushes);
+ }
List<Region> regions = new ArrayList<>();
TEST_UTIL