Skip to content

Commit 2d5dfeb

Browse files
committed
HBASE-23746 [Flakey Tests] Caused by: org.apache.hadoop.hbase.util.CommonFSUtils$StreamLacksCapabilityException: hflush and hsync; ADDENDUM add a few more tests
1 parent e0f9133 commit 2d5dfeb

3 files changed

Lines changed: 8 additions & 0 deletions

File tree

hbase-server/src/test/java/org/apache/hadoop/hbase/procedure2/store/region/RegionProcedureStoreTestBase.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@
2929
import org.junit.After;
3030
import org.junit.Before;
3131

32+
/**
33+
* This runs on local filesystem. hsync and hflush are not supported. May lose data!
34+
* Only use where data loss is not of consequence.
35+
*/
3236
public class RegionProcedureStoreTestBase {
3337

3438
protected HBaseCommonTestingUtility htu;

hbase-server/src/test/java/org/apache/hadoop/hbase/procedure2/store/region/TestRegionProcedureStoreMigration.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,8 @@ public void setUp() throws IOException {
7878
htu = new HBaseCommonTestingUtility();
7979
Configuration conf = htu.getConfiguration();
8080
conf.setBoolean(MemStoreLAB.USEMSLAB_KEY, false);
81+
// Runs on local filesystem. Test does not need sync. Turn off checks.
82+
htu.getConfiguration().setBoolean(CommonFSUtils.UNSAFE_STREAM_CAPABILITY_ENFORCE, false);
8183
Path testDir = htu.getDataTestDir();
8284
CommonFSUtils.setWALRootDir(conf, testDir);
8385
walStore = new WALProcedureStore(conf, new LeaseRecovery() {

hbase-server/src/test/java/org/apache/hadoop/hbase/procedure2/store/region/TestRegionProcedureStoreWALCleaner.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ public void setUp() throws IOException {
7272
htu = new HBaseCommonTestingUtility();
7373
Configuration conf = htu.getConfiguration();
7474
conf.setBoolean(MemStoreLAB.USEMSLAB_KEY, false);
75+
// Runs on local filesystem. Test does not need sync. Turn off checks.
76+
htu.getConfiguration().setBoolean(CommonFSUtils.UNSAFE_STREAM_CAPABILITY_ENFORCE, false);
7577
Path testDir = htu.getDataTestDir();
7678
fs = testDir.getFileSystem(conf);
7779
CommonFSUtils.setWALRootDir(conf, testDir);

0 commit comments

Comments
 (0)