Skip to content

Commit 1bdc7dd

Browse files
infraioJenkins
authored andcommitted
HBASE-22808: HBCK Report showed the offline regions which belong to disabled table (addendum)
(cherry picked from commit 044e768) Change-Id: I11b01418d128807fab4c01e42724bca9fe23af46
1 parent f1cca41 commit 1bdc7dd

File tree

1 file changed

+12
-0
lines changed
  • hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver

1 file changed

+12
-0
lines changed

hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7086,6 +7086,18 @@ public static HRegion createHRegion(final RegionInfo info, final Path rootDir,
70867086
return region;
70877087
}
70887088

7089+
/**
7090+
* Create the region directory in the filesystem.
7091+
*/
7092+
public static HRegionFileSystem createRegionDir(Configuration configuration, RegionInfo ri,
7093+
Path rootDir) throws IOException {
7094+
FileSystem fs = rootDir.getFileSystem(configuration);
7095+
Path tableDir = FSUtils.getTableDir(rootDir, ri.getTable());
7096+
// If directory already exists, will log warning and keep going. Will try to create
7097+
// .regioninfo. If one exists, will overwrite.
7098+
return HRegionFileSystem.createRegionOnFileSystem(configuration, fs, tableDir, ri);
7099+
}
7100+
70897101
public static HRegion createHRegion(final RegionInfo info, final Path rootDir,
70907102
final Configuration conf,
70917103
final TableDescriptor hTableDescriptor,

0 commit comments

Comments
 (0)