Skip to content
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 @@ -186,7 +186,7 @@ protected List<PartitionPath> getAllQueryPartitionPaths() {

// Load all the partition path from the basePath, and filter by the query partition path.
// TODO load files from the queryRelativePartitionPaths directly.
List<String> matchedPartitionPaths = getAllPartitionPathsUnchecked()
List<String> matchedPartitionPaths = FSUtils.getAllPartitionPaths(engineContext, metadataConfig, basePath.toString())
.stream()
.filter(path -> queryRelativePartitionPaths.stream().anyMatch(path::startsWith))
.collect(Collectors.toList());
Expand Down Expand Up @@ -331,14 +331,6 @@ private Map<String, FileStatus[]> getAllFilesInPartitionsUnchecked(Collection<St
}
}

private List<String> getAllPartitionPathsUnchecked() {
try {
return isPartitionedTable() ? tableMetadata.getAllPartitionPaths() : Collections.singletonList("");
} catch (IOException e) {
throw new HoodieIOException("Failed to fetch partition paths for a table", e);
}
}

private void validate(HoodieTimeline activeTimeline, Option<String> queryInstant) {
if (shouldValidateInstant) {
if (queryInstant.isPresent() && !activeTimeline.containsInstant(queryInstant.get())) {
Expand Down Expand Up @@ -366,10 +358,6 @@ private void resetTableMetadata(HoodieTableMetadata newTableMetadata) {
tableMetadata = newTableMetadata;
}

private boolean isPartitionedTable() {
return partitionColumns.length > 0 || HoodieTableMetadata.isMetadataTable(basePath.toString());
}

public static final class PartitionPath {

final String path;
Expand Down