From 2ec0f55f84a63117c99b2e52ceae27d7ff6e1364 Mon Sep 17 00:00:00 2001 From: Zhihong Yu Date: Mon, 1 Apr 2013 22:29:33 +0000 Subject: [PATCH] HBASE-7904 Revert, due to concern over coprocessor exposure git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1463326 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/hadoop/hbase/regionserver/HRegion.java | 2 +- .../org/apache/hadoop/hbase/HBaseTestingUtility.java | 7 ++----- .../hadoop/hbase/mapreduce/TestImportExport.java | 11 +---------- pom.xml | 2 +- 4 files changed, 5 insertions(+), 17 deletions(-) diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java index 25e4859e5f7..5f597043853 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java @@ -484,7 +484,7 @@ public class HRegion implements HeapSize { // , Writable{ this.rsAccounting = this.rsServices.getRegionServerAccounting(); // don't initialize coprocessors if not running within a regionserver // TODO: revisit if coprocessors should load in other cases - this.coprocessorHost = new RegionCoprocessorHost(this, rsServices, baseConf); + this.coprocessorHost = new RegionCoprocessorHost(this, rsServices, conf); this.metricsRegionWrapper = new MetricsRegionWrapperImpl(this); this.metricsRegion = new MetricsRegion(this.metricsRegionWrapper); } else { diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java index 5b767fef271..fc4e67b0c63 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/HBaseTestingUtility.java @@ -1,3 +1,5 @@ + + /** * * Licensed to the Apache Software Foundation (ASF) under one @@ -36,10 +38,8 @@ import java.util.Arrays; import java.util.Collection; import java.util.Collections; import java.util.HashSet; -import java.util.Iterator; import java.util.List; import java.util.Map; -import java.util.Map.Entry; import java.util.NavigableSet; import java.util.Random; import java.util.Set; @@ -1648,8 +1648,6 @@ public class HBaseTestingUtility extends HBaseCommonTestingUtility { forceChangeTaskLogDir(); - conf.setBoolean("yarn.nodemanager.pmem-check-enabled", false); - conf.setBoolean("yarn.nodemanager.vmem-check-enabled", false); // Allow the user to override FS URI for this map-reduce cluster to use. mrCluster = new MiniMRCluster(servers, FS_URI != null ? FS_URI : FileSystem.get(conf).getUri().toString(), 1, @@ -1658,7 +1656,6 @@ public class HBaseTestingUtility extends HBaseCommonTestingUtility { if (jobConf == null) { jobConf = mrCluster.createJobConf(); } - HBaseConfiguration.merge(this.conf, jobConf); jobConf.set("mapred.local.dir", conf.get("mapred.local.dir")); //Hadoop MiniMR overwrites this while it should not LOG.info("Mini mapreduce cluster started"); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/mapreduce/TestImportExport.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/mapreduce/TestImportExport.java index 2fbdd064cf0..138e8ee0d2b 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/mapreduce/TestImportExport.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/mapreduce/TestImportExport.java @@ -228,11 +228,8 @@ public class TestImportExport { OUTPUT_DIR }; - GenericOptionsParser opts = new GenericOptionsParser(new Configuration( - cluster.getConfiguration()), args); + GenericOptionsParser opts = new GenericOptionsParser(new Configuration(cluster.getConfiguration()), args); Configuration conf = opts.getConfiguration(); - // copy or add the necessary configuration values from the map reduce config to the hbase config - copyConfigurationValues(UTIL.getConfiguration(), conf); args = opts.getRemainingArgs(); assertEquals(conf.get(Export.EXPORT_BATCHING), EXPORT_BATCH_SIZE); @@ -353,8 +350,6 @@ public class TestImportExport { GenericOptionsParser opts = new GenericOptionsParser(new Configuration( cluster.getConfiguration()), args); Configuration conf = opts.getConfiguration(); - // copy or add the necessary configuration values from the map reduce config to the hbase config - copyConfigurationValues(UTIL.getConfiguration(), conf); args = opts.getRemainingArgs(); Job job = Export.createSubmittableJob(conf, args); @@ -374,8 +369,6 @@ public class TestImportExport { opts = new GenericOptionsParser(new Configuration(cluster.getConfiguration()), args); conf = opts.getConfiguration(); - // copy or add the necessary configuration values from the map reduce config to the hbase config - copyConfigurationValues(UTIL.getConfiguration(), conf); args = opts.getRemainingArgs(); job = Import.createSubmittableJob(conf, args); @@ -399,8 +392,6 @@ public class TestImportExport { opts = new GenericOptionsParser(new Configuration(cluster.getConfiguration()), args); conf = opts.getConfiguration(); - // copy or add the necessary configuration values from the map reduce config to the hbase config - copyConfigurationValues(UTIL.getConfiguration(), conf); args = opts.getRemainingArgs(); job = Import.createSubmittableJob(conf, args); diff --git a/pom.xml b/pom.xml index cd6a6bb8cb5..fa2b0573363 100644 --- a/pom.xml +++ b/pom.xml @@ -733,7 +733,7 @@ ${maven.build.timestamp} 1.6 - 2.0.4-SNAPSHOT + 2.0.2-alpha 1.1.2 1.2 1.7