Vihang Karajgaonkar has posted comments on this change. ( http://gerrit.cloudera.org:8080/17313 )
Change subject: IMPALA-10656: Fire insert events before commit ...................................................................... Patch Set 8: (6 comments) http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java File fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java: http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4672 PS8, Line 4672: and nit, s/and/an http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4868 PS8, Line 4868: * @param partitionFilesMapBeforeInsert List of files for each partition in which data : * was inserted. : * @param affectedExistingPartitions List of all affected partitions that were already : * existed. : * @param newPartsCreated represents all the partitions names which got created by : * the insert operation. : * @param isInsertOverwrite indicates if the operation was an insert overwrite. can you update the comment with the new params? http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4902 PS8, Line 4902: if (!isTransactional) { : // add_partitions() RPC have already fired events for new partitions in the : // non-transactional case. : partSet = new HashSet<String>(partSet); : partSet.removeAll(addedPartitionNames); : } It is not clear to me why we do this for non-transactional tables. IIUC addedPartitionNames represents the newly added partitions. These partitions do not need a INSERT event irrespective of whether the table is transactional or not since HMS will generate a ADD_PARTITION event when we added them on line 4740. So this block will need to be done both transactional and non-transactional table right? http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4912 PS8, Line 4912: get("") I think it is worth a comment here to mention that in case of unpartitioned table the key is "" and may be provide the method name in the backend as reference. http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4916 PS8, Line 4916: Preconditions nit, move the preconditions above line 4914. http://gerrit.cloudera.org:8080/#/c/17313/8/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@4926 PS8, Line 4926: Preconditions.checkState(!newFiles.isEmpty() || isInsertOverwrite); : Preconditions.checkState(!partVals.isEmpty()); nit, move the preconditions check before line 4924 -- To view, visit http://gerrit.cloudera.org:8080/17313 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I2ed812dbcb5f55efff3a910a3daeeb76cd3295b9 Gerrit-Change-Number: 17313 Gerrit-PatchSet: 8 Gerrit-Owner: Csaba Ringhofer <csringho...@cloudera.com> Gerrit-Reviewer: Csaba Ringhofer <csringho...@cloudera.com> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Vihang Karajgaonkar <vih...@cloudera.com> Gerrit-Reviewer: Zoltan Borok-Nagy <borokna...@cloudera.com> Gerrit-Comment-Date: Tue, 20 Apr 2021 15:56:04 +0000 Gerrit-HasComments: Yes