HBASE-27602 Remove the impact of operating env on testHFileCleaning (#5003)
Co-authored-by: tianhang.tang <tianhang.tang@shopee.com> Signed-off-by: Duo Zhang <zhangduo@apache.org>
This commit is contained in:
parent
833b10e8ba
commit
e71253f4d8
|
@ -67,6 +67,9 @@ public class TestHFileCleaner {
|
|||
|
||||
private static DirScanPool POOL;
|
||||
|
||||
private static String MOCK_ARCHIVED_HFILE_DIR =
|
||||
HConstants.HFILE_ARCHIVE_DIRECTORY + "/namespace/table/region";
|
||||
|
||||
@BeforeClass
|
||||
public static void setupCluster() throws Exception {
|
||||
// have to use a minidfs cluster because the localfs doesn't modify file times correctly
|
||||
|
@ -158,8 +161,7 @@ public class TestHFileCleaner {
|
|||
+ "org.apache.hadoop.hbase.mob.ManualMobMaintHFileCleaner");
|
||||
conf.setLong(TimeToLiveHFileCleaner.TTL_CONF_KEY, ttl);
|
||||
Server server = new DummyServer();
|
||||
Path archivedHfileDir =
|
||||
new Path(UTIL.getDataTestDirOnTestFS(), HConstants.HFILE_ARCHIVE_DIRECTORY);
|
||||
Path archivedHfileDir = new Path(UTIL.getDataTestDirOnTestFS(), MOCK_ARCHIVED_HFILE_DIR);
|
||||
FileSystem fs = FileSystem.get(conf);
|
||||
HFileCleaner cleaner = new HFileCleaner(1000, server, conf, fs, archivedHfileDir, POOL);
|
||||
|
||||
|
|
Loading…
Reference in New Issue