yihua commented on code in PR #13007: URL: https://github.com/apache/hudi/pull/13007#discussion_r2019414825
########## hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/marker/DirectWriteMarkers.java: ########## @@ -91,22 +98,10 @@ public boolean doesMarkerDirExist() throws IOException { @Override public Set<String> createdAndMergedDataPaths(HoodieEngineContext context, int parallelism) throws IOException { - Set<String> dataFiles = new HashSet<>(); - - List<StoragePathInfo> topLevelInfoList = storage.listDirectEntries(markerDirPath); - List<String> subDirectories = new ArrayList<>(); - for (StoragePathInfo topLevelInfo: topLevelInfoList) { - if (topLevelInfo.isFile()) { - String pathStr = topLevelInfo.getPath().toString(); - if (pathStr.contains(HoodieTableMetaClient.MARKER_EXTN) && !pathStr.endsWith(IOType.APPEND.name())) { - dataFiles.add(translateMarkerToDataPath(pathStr)); - } - } else { - subDirectories.add(topLevelInfo.getPath().toString()); - } - } - - if (!subDirectories.isEmpty()) { + Pair<List<String>, Set<String>> subDirectoriesAndDataFiles = getSubDirectoriesByMarkerCondition(storage.listDirectEntries(markerDirPath), NOT_APPEND_MARKER_PREDICATE); Review Comment: Fixed by introducing a new `DirectWriteMarkersV1 ` implementation class that implements `AppendMarkerHandler`. -- 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: commits-unsubscr...@hudi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org