hgromer commented on code in PR #7151:
URL: https://github.com/apache/hbase/pull/7151#discussion_r2207575731


##########
hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/WALInputFormat.java:
##########
@@ -396,4 +396,28 @@ public RecordReader<WALKey, WALEdit> 
createRecordReader(InputSplit split,
     TaskAttemptContext context) throws IOException, InterruptedException {
     return new WALKeyRecordReader();
   }
+
+  /**
+   * Attempts to return the {@link LocatedFileStatus} for the given directory. 
If the directory does
+   * not exist, it will check if the directory is an archived log file and try 
to find it
+   */
+  private static RemoteIterator<LocatedFileStatus> 
listLocatedFileStatus(FileSystem fs, Path dir,
+    Configuration conf) throws IOException {
+    try {
+      return fs.listLocatedStatus(dir);
+    } catch (FileNotFoundException e) {
+      if (AbstractFSWALProvider.isArchivedLogFile(dir)) {

Review Comment:
   I've decided to make this default behavior, rather than enabling via some 
flag b/c 
[this](https://github.com/apache/hbase/blob/3500d6f2e1735c1c4ed5cff86860f8509753a3b3/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/WALInputFormat.java#L256)
 already exists



-- 
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]

Reply via email to