1
0

Fixing bug introducted in rollback for MOR table type with inserts into log files

This commit is contained in:
Nishith Agarwal
2018-07-09 16:58:05 -07:00
committed by vinoth chandar
parent a6fe96fdfe
commit 34ab54a9d3
3 changed files with 93 additions and 39 deletions

View File

@@ -213,6 +213,16 @@ public class FSUtils {
return matcher.group(1);
}
/**
* Check if the file is a parquet file of a log file. Then get the fileId appropriately.
*/
public static String getFileIdFromFilePath(Path filePath) {
if (FSUtils.isLogFile(filePath)) {
return FSUtils.getFileIdFromLogPath(filePath);
}
return FSUtils.getFileId(filePath.getName());
}
/**
* Get the first part of the file name in the log file. That will be the fileId. Log file do not
* have commitTime in the file name.