Repository: hbase
Updated Branches:
  refs/heads/branch-2 57291108e -> ade66e286


HBASE-19273 IntegrationTestBulkLoad#installSlowingCoproc() uses read-only 
HTableDescriptor


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/ade66e28
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/ade66e28
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/ade66e28

Branch: refs/heads/branch-2
Commit: ade66e286861a86f9d7c99f9d6cf78f94b427848
Parents: 5729110
Author: tedyu <yuzhih...@gmail.com>
Authored: Thu Nov 16 21:07:52 2017 -0800
Committer: tedyu <yuzhih...@gmail.com>
Committed: Thu Nov 16 21:07:52 2017 -0800

----------------------------------------------------------------------
 .../hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java   | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/ade66e28/hbase-it/src/test/java/org/apache/hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java
----------------------------------------------------------------------
diff --git 
a/hbase-it/src/test/java/org/apache/hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java
 
b/hbase-it/src/test/java/org/apache/hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java
index 3881097..3fa1054 100644
--- 
a/hbase-it/src/test/java/org/apache/hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java
+++ 
b/hbase-it/src/test/java/org/apache/hadoop/hbase/mapreduce/IntegrationTestBulkLoad.java
@@ -43,7 +43,6 @@ import org.apache.hadoop.hbase.CellUtil;
 import org.apache.hadoop.hbase.ClusterStatus.Option;
 import org.apache.hadoop.hbase.HBaseConfiguration;
 import org.apache.hadoop.hbase.HBaseTestingUtility;
-import org.apache.hadoop.hbase.HTableDescriptor;
 import org.apache.hadoop.hbase.IntegrationTestBase;
 import org.apache.hadoop.hbase.IntegrationTestingUtility;
 import org.apache.hadoop.hbase.KeyValue;
@@ -56,6 +55,8 @@ import org.apache.hadoop.hbase.client.RegionLocator;
 import org.apache.hadoop.hbase.client.Result;
 import org.apache.hadoop.hbase.client.Scan;
 import org.apache.hadoop.hbase.client.Table;
+import org.apache.hadoop.hbase.client.TableDescriptor;
+import org.apache.hadoop.hbase.client.TableDescriptorBuilder;
 import org.apache.hadoop.hbase.coprocessor.ObserverContext;
 import org.apache.hadoop.hbase.coprocessor.RegionCoprocessor;
 import org.apache.hadoop.hbase.coprocessor.RegionCoprocessorEnvironment;
@@ -211,9 +212,10 @@ public class IntegrationTestBulkLoad extends 
IntegrationTestBase {
 
     TableName t = getTablename();
     Admin admin = util.getAdmin();
-    HTableDescriptor desc = admin.getTableDescriptor(t);
-    desc.addCoprocessor(SlowMeCoproScanOperations.class.getName());
-    HBaseTestingUtility.modifyTableSync(admin, desc);
+    TableDescriptor desc = admin.getDescriptor(t);
+    TableDescriptorBuilder builder = TableDescriptorBuilder.newBuilder(desc);
+    builder.addCoprocessor(SlowMeCoproScanOperations.class.getName());
+    HBaseTestingUtility.modifyTableSync(admin, builder.build());
   }
 
   @Test

Reply via email to