From 5a3ad6f08f4304f73c911726cf2e33b9ced1f43a Mon Sep 17 00:00:00 2001 From: Jan Hentschel Date: Sun, 2 Feb 2020 00:28:25 +0100 Subject: [PATCH] HBASE-23776 Removed deprecated method createLocalHTU() from HBaseTestingUtility Signed-off-by: stack --- .../hadoop/hbase/HBaseTestingUtility.java | 22 ------------------- .../coprocessor/TestCoprocessorInterface.java | 2 +- .../TestCoreMasterCoprocessor.java | 2 +- .../TestCoreRegionCoprocessor.java | 2 +- .../TestCoreRegionServerCoprocessor.java | 2 +- .../hbase/io/encoding/TestEncodedSeekers.java | 2 +- .../hbase/io/hfile/TestCacheOnWrite.java | 2 +- .../hfile/TestForceCacheImportantBlocks.java | 2 +- .../io/hfile/TestScannerFromBucketCache.java | 2 +- .../TestScannerSelectionUsingKeyRange.java | 2 +- .../hfile/TestScannerSelectionUsingTTL.java | 2 +- .../hbase/master/TestHMasterRPCException.java | 2 +- .../hadoop/hbase/mob/TestMobFileCache.java | 2 +- .../regionserver/TestAtomicOperation.java | 2 +- .../TestCacheOnWriteInSchema.java | 2 +- .../hbase/regionserver/TestColumnSeeking.java | 2 +- .../hbase/regionserver/TestCompaction.java | 2 +- .../TestCompactionArchiveConcurrentClose.java | 2 +- .../regionserver/TestFailedAppendAndSync.java | 2 +- .../hbase/regionserver/TestHRegion.java | 2 +- .../hbase/regionserver/TestKeepDeletes.java | 2 +- .../regionserver/TestMajorCompaction.java | 2 +- .../regionserver/TestMinorCompaction.java | 2 +- .../regionserver/TestMultiColumnScanner.java | 2 +- .../regionserver/TestMultiLogThreshold.java | 2 +- .../regionserver/TestRegionIncrement.java | 2 +- .../hbase/regionserver/TestRowTooBig.java | 2 +- .../regionserver/TestScanWithBloomError.java | 2 +- .../hbase/regionserver/TestScanner.java | 2 +- .../TestScannerWithCorruptHFile.java | 2 +- .../regionserver/TestSeekOptimizations.java | 2 +- .../TestTimestampFilterSeekHint.java | 2 +- .../hbase/snapshot/TestSnapshotManifest.java | 2 +- 33 files changed, 32 insertions(+), 54 deletions(-) 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 3f4013008b4d..864a14d4a90b 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 @@ -302,11 +302,6 @@ public static List memStoreTSTagsAndOffheapCombination() { *

Initially, all tmp files are written to a local test data directory. * Once {@link #startMiniDFSCluster} is called, either directly or via * {@link #startMiniCluster()}, tmp data will be written to the DFS directory instead. - * - *

Previously, there was a distinction between the type of utility returned by - * {@link #createLocalHTU()} and this constructor; this is no longer the case. All - * HBaseTestingUtility objects will behave as local until a DFS cluster is started, - * at which point they will switch to using mini DFS for storage. */ public HBaseTestingUtility() { this(HBaseConfiguration.create()); @@ -319,11 +314,6 @@ public HBaseTestingUtility() { * Once {@link #startMiniDFSCluster} is called, either directly or via * {@link #startMiniCluster()}, tmp data will be written to the DFS directory instead. * - *

Previously, there was a distinction between the type of utility returned by - * {@link #createLocalHTU()} and this constructor; this is no longer the case. All - * HBaseTestingUtility objects will behave as local until a DFS cluster is started, - * at which point they will switch to using mini DFS for storage. - * * @param conf The configuration to use for further operations */ public HBaseTestingUtility(@Nullable Configuration conf) { @@ -352,18 +342,6 @@ public HBaseTestingUtility(@Nullable Configuration conf) { this.conf.getBoolean(LocalHBaseCluster.ASSIGN_RANDOM_PORTS, true)); } - /** - * @deprecated since 2.0.0 and will be removed in 3.0.0. Use {@link #HBaseTestingUtility()} - * instead. - * @return a normal HBaseTestingUtility - * @see #HBaseTestingUtility() - * @see HBASE-19841 - */ - @Deprecated - public static HBaseTestingUtility createLocalHTU() { - return new HBaseTestingUtility(); - } - /** * @deprecated since 2.0.0 and will be removed in 3.0.0. Use * {@link #HBaseTestingUtility(Configuration)} instead. diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoprocessorInterface.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoprocessorInterface.java index 6b37db6c09a0..8699abfa7e51 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoprocessorInterface.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoprocessorInterface.java @@ -82,7 +82,7 @@ public class TestCoprocessorInterface { @Rule public TestName name = new TestName(); private static final Logger LOG = LoggerFactory.getLogger(TestCoprocessorInterface.class); - private static final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); static final Path DIR = TEST_UTIL.getDataTestDir(); private static class CustomScanner implements RegionScanner { diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreMasterCoprocessor.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreMasterCoprocessor.java index 5afc7b07cfe8..dcf1ad3290a8 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreMasterCoprocessor.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreMasterCoprocessor.java @@ -49,7 +49,7 @@ public class TestCoreMasterCoprocessor { HBaseClassTestRule.forClass(TestCoreMasterCoprocessor.class); @Rule public TestName name = new TestName(); - private static final HBaseTestingUtility HTU = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility HTU = new HBaseTestingUtility(); private MasterServices ms; private MasterCoprocessorHost mch; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionCoprocessor.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionCoprocessor.java index ceb6b5c9e1ec..6165e46223ef 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionCoprocessor.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionCoprocessor.java @@ -58,7 +58,7 @@ public class TestCoreRegionCoprocessor { HBaseClassTestRule.forClass(TestCoreRegionCoprocessor.class); @Rule public TestName name = new TestName(); - HBaseTestingUtility HTU = HBaseTestingUtility.createLocalHTU(); + HBaseTestingUtility HTU = new HBaseTestingUtility(); private HRegion region = null; private RegionServerServices rss; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionServerCoprocessor.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionServerCoprocessor.java index 4e14867c8dfb..b530423297de 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionServerCoprocessor.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/coprocessor/TestCoreRegionServerCoprocessor.java @@ -49,7 +49,7 @@ public class TestCoreRegionServerCoprocessor { HBaseClassTestRule.forClass(TestCoreRegionServerCoprocessor.class); @Rule public TestName name = new TestName(); - private static final HBaseTestingUtility HTU = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility HTU = new HBaseTestingUtility(); private RegionServerServices rss; private RegionServerCoprocessorHost rsch; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/encoding/TestEncodedSeekers.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/encoding/TestEncodedSeekers.java index 12f2121872fa..856df096d9b4 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/encoding/TestEncodedSeekers.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/encoding/TestEncodedSeekers.java @@ -79,7 +79,7 @@ public class TestEncodedSeekers { private static final int NUM_HFILES = 4; private static final int NUM_ROWS_PER_FLUSH = NUM_ROWS / NUM_HFILES; - private final HBaseTestingUtility testUtil = HBaseTestingUtility.createLocalHTU(); + private final HBaseTestingUtility testUtil = new HBaseTestingUtility(); private final DataBlockEncoding encoding; private final boolean includeTags; private final boolean compressTags; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestCacheOnWrite.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestCacheOnWrite.java index 119d26cec867..8839bcaf8307 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestCacheOnWrite.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestCacheOnWrite.java @@ -90,7 +90,7 @@ public class TestCacheOnWrite { private static final Logger LOG = LoggerFactory.getLogger(TestCacheOnWrite.class); - private static final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private Configuration conf; private CacheConfig cacheConf; private FileSystem fs; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestForceCacheImportantBlocks.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestForceCacheImportantBlocks.java index fd39f4817dc6..6023991ae9d4 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestForceCacheImportantBlocks.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestForceCacheImportantBlocks.java @@ -61,7 +61,7 @@ public class TestForceCacheImportantBlocks { public static final HBaseClassTestRule CLASS_RULE = HBaseClassTestRule.forClass(TestForceCacheImportantBlocks.class); - private final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static final String TABLE = "myTable"; private static final String CF = "myCF"; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerFromBucketCache.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerFromBucketCache.java index ad6a0ab8c76a..75e5575e76fe 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerFromBucketCache.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerFromBucketCache.java @@ -77,7 +77,7 @@ public class TestScannerFromBucketCache { private TableName tableName; private void setUp(boolean useBucketCache) throws IOException { - test_util = HBaseTestingUtility.createLocalHTU(); + test_util = new HBaseTestingUtility(); conf = test_util.getConfiguration(); if (useBucketCache) { conf.setInt("hbase.bucketcache.size", 400); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingKeyRange.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingKeyRange.java index 09f9d45a7acb..72eb5c06cab3 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingKeyRange.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingKeyRange.java @@ -61,7 +61,7 @@ public class TestScannerSelectionUsingKeyRange { public static final HBaseClassTestRule CLASS_RULE = HBaseClassTestRule.forClass(TestScannerSelectionUsingKeyRange.class); - private static final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static TableName TABLE = TableName.valueOf("myTable"); private static String FAMILY = "myCF"; private static byte[] FAMILY_BYTES = Bytes.toBytes(FAMILY); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingTTL.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingTTL.java index 2065c0cc1892..2bf9ea312fef 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingTTL.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TestScannerSelectionUsingTTL.java @@ -68,7 +68,7 @@ public class TestScannerSelectionUsingTTL { private static final Logger LOG = LoggerFactory.getLogger(TestScannerSelectionUsingTTL.class); - private static final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static TableName TABLE = TableName.valueOf("myTable"); private static String FAMILY = "myCF"; private static byte[] FAMILY_BYTES = Bytes.toBytes(FAMILY); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/master/TestHMasterRPCException.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/master/TestHMasterRPCException.java index 197073746423..71cc49ec927d 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/master/TestHMasterRPCException.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/master/TestHMasterRPCException.java @@ -58,7 +58,7 @@ public class TestHMasterRPCException { private static final Logger LOG = LoggerFactory.getLogger(TestHMasterRPCException.class); - private final HBaseTestingUtility testUtil = HBaseTestingUtility.createLocalHTU(); + private final HBaseTestingUtility testUtil = new HBaseTestingUtility(); private HMaster master; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/mob/TestMobFileCache.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/mob/TestMobFileCache.java index a8cbeab6d907..7e18f45bea33 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/mob/TestMobFileCache.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/mob/TestMobFileCache.java @@ -84,7 +84,7 @@ public class TestMobFileCache { @Before public void setUp() throws Exception { - UTIL = HBaseTestingUtility.createLocalHTU(); + UTIL = new HBaseTestingUtility(); conf = UTIL.getConfiguration(); conf.set(MobConstants.MOB_FILE_CACHE_SIZE_KEY, TEST_CACHE_SIZE); TableDescriptorBuilder tableDescriptorBuilder = diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestAtomicOperation.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestAtomicOperation.java index 79e31527958d..42b86adca026 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestAtomicOperation.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestAtomicOperation.java @@ -98,7 +98,7 @@ public class TestAtomicOperation { @Rule public TestName name = new TestName(); HRegion region = null; - private HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); // Test names static byte[] tableName; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCacheOnWriteInSchema.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCacheOnWriteInSchema.java index 2c5103d64281..c23d56fe5ef3 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCacheOnWriteInSchema.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCacheOnWriteInSchema.java @@ -82,7 +82,7 @@ public class TestCacheOnWriteInSchema { private static final Logger LOG = LoggerFactory.getLogger(TestCacheOnWriteInSchema.class); @Rule public TestName name = new TestName(); - private static final HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static final String DIR = TEST_UTIL.getDataTestDir("TestCacheOnWriteInSchema").toString(); private static byte [] table; private static byte [] family = Bytes.toBytes("family"); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestColumnSeeking.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestColumnSeeking.java index 5ec1808c1a86..43c81a31dccd 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestColumnSeeking.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestColumnSeeking.java @@ -61,7 +61,7 @@ public class TestColumnSeeking { HBaseClassTestRule.forClass(TestColumnSeeking.class); @Rule public TestName name = new TestName(); - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static final Logger LOG = LoggerFactory.getLogger(TestColumnSeeking.class); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompaction.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompaction.java index a1d76fba3f14..fa3e884c9f7d 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompaction.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompaction.java @@ -92,7 +92,7 @@ public class TestCompaction { HBaseClassTestRule.forClass(TestCompaction.class); @Rule public TestName name = new TestName(); - private static final HBaseTestingUtility UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility UTIL = new HBaseTestingUtility(); protected Configuration conf = UTIL.getConfiguration(); private HRegion r = null; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompactionArchiveConcurrentClose.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompactionArchiveConcurrentClose.java index 4263de569550..2684e73ab1ce 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompactionArchiveConcurrentClose.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestCompactionArchiveConcurrentClose.java @@ -76,7 +76,7 @@ public class TestCompactionArchiveConcurrentClose { @Before public void setup() throws Exception { - testUtil = HBaseTestingUtility.createLocalHTU(); + testUtil = new HBaseTestingUtility(); testDir = testUtil.getDataTestDir("TestStoreFileRefresherChore"); FSUtils.setRootDir(testUtil.getConfiguration(), testDir); } diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestFailedAppendAndSync.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestFailedAppendAndSync.java index dd47aa2ed639..d81527325107 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestFailedAppendAndSync.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestFailedAppendAndSync.java @@ -82,7 +82,7 @@ public class TestFailedAppendAndSync { @Before public void setup() throws IOException { - TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + TEST_UTIL = new HBaseTestingUtility(); CONF = TEST_UTIL.getConfiguration(); // Disable block cache. CONF.setFloat(HConstants.HFILE_BLOCK_CACHE_SIZE_KEY, 0f); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestHRegion.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestHRegion.java index 9d9bba3357c1..53ec7d16d4e4 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestHRegion.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestHRegion.java @@ -246,7 +246,7 @@ public class TestHRegion { @Before public void setup() throws IOException { - TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + TEST_UTIL = new HBaseTestingUtility(); CONF = TEST_UTIL.getConfiguration(); NettyAsyncFSWALConfigHelper.setEventLoopConfig(CONF, GROUP, NioSocketChannel.class); dir = TEST_UTIL.getDataTestDir("TestHRegion").toString(); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestKeepDeletes.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestKeepDeletes.java index 6683d845a128..e8d036224096 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestKeepDeletes.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestKeepDeletes.java @@ -61,7 +61,7 @@ public class TestKeepDeletes { public static final HBaseClassTestRule CLASS_RULE = HBaseClassTestRule.forClass(TestKeepDeletes.class); - HBaseTestingUtility hbu = HBaseTestingUtility.createLocalHTU(); + HBaseTestingUtility hbu = new HBaseTestingUtility(); private final byte[] T0 = Bytes.toBytes("0"); private final byte[] T1 = Bytes.toBytes("1"); private final byte[] T2 = Bytes.toBytes("2"); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMajorCompaction.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMajorCompaction.java index 4fdd6b337f67..6b8c949fbbed 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMajorCompaction.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMajorCompaction.java @@ -88,7 +88,7 @@ public static Object[] data() { } @Rule public TestName name; private static final Logger LOG = LoggerFactory.getLogger(TestMajorCompaction.class.getName()); - private static final HBaseTestingUtility UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility UTIL = new HBaseTestingUtility(); protected Configuration conf = UTIL.getConfiguration(); private HRegion r = null; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMinorCompaction.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMinorCompaction.java index 7b531484a6ff..4955414cb5ae 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMinorCompaction.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMinorCompaction.java @@ -59,7 +59,7 @@ public class TestMinorCompaction { @Rule public TestName name = new TestName(); private static final Logger LOG = LoggerFactory.getLogger(TestMinorCompaction.class.getName()); - private static final HBaseTestingUtility UTIL = HBaseTestingUtility.createLocalHTU(); + private static final HBaseTestingUtility UTIL = new HBaseTestingUtility(); protected Configuration conf = UTIL.getConfiguration(); private HRegion r = null; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiColumnScanner.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiColumnScanner.java index 5950b9435848..7d48fce17e7d 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiColumnScanner.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiColumnScanner.java @@ -104,7 +104,7 @@ public abstract class TestMultiColumnScanner { /** The probability to delete a row/column pair */ private static final double DELETE_PROBABILITY = 0.02; - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); @Parameter(0) public Compression.Algorithm comprAlgo; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiLogThreshold.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiLogThreshold.java index 5ce32de3a713..eb5251132c9b 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiLogThreshold.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMultiLogThreshold.java @@ -65,7 +65,7 @@ public class TestMultiLogThreshold { @BeforeClass public static void setup() throws Exception { final TableName tableName = TableName.valueOf("tableName"); - TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + TEST_UTIL = new HBaseTestingUtility(); CONF = TEST_UTIL.getConfiguration(); THRESHOLD = CONF.getInt(RSRpcServices.BATCH_ROWS_THRESHOLD_NAME, RSRpcServices.BATCH_ROWS_THRESHOLD_DEFAULT); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRegionIncrement.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRegionIncrement.java index e5006eafb65d..1a4ab8f66008 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRegionIncrement.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRegionIncrement.java @@ -72,7 +72,7 @@ public class TestRegionIncrement { @Before public void setUp() throws Exception { - TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + TEST_UTIL = new HBaseTestingUtility(); } @After diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRowTooBig.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRowTooBig.java index 5a4cea60b2aa..15c198a90786 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRowTooBig.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestRowTooBig.java @@ -49,7 +49,7 @@ public class TestRowTooBig { public static final HBaseClassTestRule CLASS_RULE = HBaseClassTestRule.forClass(TestRowTooBig.class); - private final static HBaseTestingUtility HTU = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility HTU = new HBaseTestingUtility(); private static Path rootRegionDir; private static final HTableDescriptor TEST_HTD = new HTableDescriptor(TableName.valueOf(TestRowTooBig.class.getSimpleName())); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanWithBloomError.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanWithBloomError.java index c67fd25cf902..527d5a32d5bc 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanWithBloomError.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanWithBloomError.java @@ -86,7 +86,7 @@ public class TestScanWithBloomError { private FileSystem fs; private Configuration conf; - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); @Parameters public static final Collection parameters() { diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanner.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanner.java index 5d915b4e7b2f..b9152eab97e6 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanner.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScanner.java @@ -75,7 +75,7 @@ public class TestScanner { @Rule public TestName name = new TestName(); private static final Logger LOG = LoggerFactory.getLogger(TestScanner.class); - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private static final byte [] FIRST_ROW = HConstants.EMPTY_START_ROW; private static final byte [][] COLS = { HConstants.CATALOG_FAMILY }; diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScannerWithCorruptHFile.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScannerWithCorruptHFile.java index a6ec9fc6fbfb..63935a34cbac 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScannerWithCorruptHFile.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestScannerWithCorruptHFile.java @@ -59,7 +59,7 @@ public class TestScannerWithCorruptHFile { @Rule public TestName name = new TestName(); private static final byte[] FAMILY_NAME = Bytes.toBytes("f"); - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); @BeforeClass diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSeekOptimizations.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSeekOptimizations.java index 1bb9dfde0907..e95e679eb760 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSeekOptimizations.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestSeekOptimizations.java @@ -127,7 +127,7 @@ public class TestSeekOptimizations { private long totalSeekDiligent, totalSeekLazy; - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); @Parameters public static final Collection parameters() { diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestTimestampFilterSeekHint.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestTimestampFilterSeekHint.java index 09a5cfdc65f1..57d252adb55e 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestTimestampFilterSeekHint.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestTimestampFilterSeekHint.java @@ -45,7 +45,7 @@ public class TestTimestampFilterSeekHint { public static final HBaseClassTestRule CLASS_RULE = HBaseClassTestRule.forClass(TestTimestampFilterSeekHint.class); - private final static HBaseTestingUtility TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + private final static HBaseTestingUtility TEST_UTIL = new HBaseTestingUtility(); private final static String RK = "myRK"; private final static byte[] RK_BYTES = Bytes.toBytes(RK); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/snapshot/TestSnapshotManifest.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/snapshot/TestSnapshotManifest.java index 926a7e5f783f..1dff4c0f3cc9 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/snapshot/TestSnapshotManifest.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/snapshot/TestSnapshotManifest.java @@ -71,7 +71,7 @@ public class TestSnapshotManifest { @Before public void setup() throws Exception { - TEST_UTIL = HBaseTestingUtility.createLocalHTU(); + TEST_UTIL = new HBaseTestingUtility(); rootDir = TEST_UTIL.getDataTestDir(TABLE_NAME_STR); fs = TEST_UTIL.getTestFileSystem();