Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[fix](multi-catalog)filter impala generated path #28786

Merged
merged 1 commit into from
Dec 22, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1068,17 +1068,18 @@ private boolean isFileVisible(Path path) {
return false;
}
for (String name : path.toString().split("/")) {
// generated by hive
if (name.startsWith(".hive-staging")) {
return false;
}
// generated by spark
if ("_temporary".equals(name)) {
if (isGeneratedPath(name)) {
return false;
}
}
return true;
}

private static boolean isGeneratedPath(String name) {
return "_temporary".equals(name) // generated by spark
|| "_imapala_insert_staging".equals(name) // generated by impala
|| name.startsWith(".hive-staging"); // generated by hive
}
}

@Data
Expand Down
Loading