gvprathyusha6 commented on code in PR #7406:
URL: https://github.com/apache/hbase/pull/7406#discussion_r2486949785
##########
hbase-server/src/main/java/org/apache/hadoop/hbase/master/janitor/MetaFixer.java:
##########
@@ -217,6 +222,27 @@ private static List<RegionInfo> createMetaEntries(final
MasterServices masterSer
return createMetaEntriesSuccesses;
}
+ private static void createRegionDirectories(final MasterServices
masterServices,
+ final List<RegionInfo> regions) {
+ if (regions.isEmpty()) {
+ return;
+ }
+ final MasterFileSystem mfs = masterServices.getMasterFileSystem();
+ final Path rootDir = mfs.getRootDir();
+ for (RegionInfo regionInfo : regions) {
+ if (regionInfo.getReplicaId() == RegionInfo.DEFAULT_REPLICA_ID) {
+ try {
+ Path tableDir = CommonFSUtils.getTableDir(rootDir,
regionInfo.getTable());
+
HRegionFileSystem.createRegionOnFileSystem(masterServices.getConfiguration(),
+ mfs.getFileSystem(), tableDir, regionInfo);
+ } catch (IOException e) {
+ LOG.warn("Failed to create region directory for {}: {}",
+ regionInfo.getRegionNameAsString(), e.getMessage());
Review Comment:
> how can fixHoles progress
It shall continue to fix hole for other regions, right now also that part is
taken care of by the procedure logic, as part of Assign it is creating the
region directory, so if region directory creation fails, it would only effect
that region and not rest of them, so I tried to keep it similar
>I hope that's the only place using this utility?
yes and its private
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]