You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by GitBox <gi...@apache.org> on 2021/06/09 06:28:36 UTC

[GitHub] [hudi] pengzhiwei2018 commented on a change in pull request #2925: [HUDI-1879] Fix RO Tables Returning Snapshot Result

pengzhiwei2018 commented on a change in pull request #2925:
URL: https://github.com/apache/hudi/pull/2925#discussion_r648003005



##########
File path: hudi-sync/hudi-hive-sync/src/main/java/org/apache/hudi/hive/HiveSyncTool.java
##########
@@ -106,13 +106,13 @@ public void syncHoodieTable() {
       if (hoodieHiveClient != null) {
         switch (hoodieHiveClient.getTableType()) {
           case COPY_ON_WRITE:
-            syncHoodieTable(snapshotTableName, false);
+            syncHoodieTable(snapshotTableName, false, false);

Review comment:
       Hi @nsivabalan, we use the `getBaseFileOnlyView` to read data for COW for both read-optimized & snapshot in `DefaultSource`. So it does not matter here. we can see the code in `DefaultSource`:
   
   > (tableType, queryType, isBootstrappedTable) match {
         case (COPY_ON_WRITE, QUERY_TYPE_SNAPSHOT_OPT_VAL, false) |
              (COPY_ON_WRITE, QUERY_TYPE_READ_OPTIMIZED_OPT_VAL, false) |
              (MERGE_ON_READ, QUERY_TYPE_READ_OPTIMIZED_OPT_VAL, false) =>
           getBaseFileOnlyView(useHoodieFileIndex, sqlContext, parameters, schema, tablePath,
             readPaths, metaClient)
   
   




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org