Quanlong Huang has posted comments on this change. ( http://gerrit.cloudera.org:8080/14799 )
Change subject: IMPALA-9101: Add support for detecting self-events on partition events ...................................................................... Patch Set 5: (12 comments) It takes some time to review since this patch is larger... Still looking at the DDL code paths. http://gerrit.cloudera.org:8080/#/c/14799/2//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/14799/2//COMMIT_MSG@9 PS2, Line 9: This commit redoes some of the self-event detection logic, specifically for the partition > Please wrap the lines to fix the 72 character limit (to be consistent with Could you address on this? http://gerrit.cloudera.org:8080/#/c/14799/5//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/14799/5//COMMIT_MSG@14 PS5, Line 14: reset rest? http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/CatalogServiceCatalog.java File fe/src/main/java/org/apache/impala/catalog/CatalogServiceCatalog.java: http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/CatalogServiceCatalog.java@2251 PS5, Line 2251: Returns true if partition is found and is refreshed, : * false otherwise. stale comment http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/CatalogServiceCatalog.java@2262 PS5, Line 2262: if (table == null || table instanceof IncompleteTable) return new Pair<>(false, : false); nit: refactor into multiple lines if-clause http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/HdfsPartition.java File fe/src/main/java/org/apache/impala/catalog/HdfsPartition.java: http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/HdfsPartition.java@863 PS5, Line 863: did'nt typo: didn't http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/HdfsPartition.java@875 PS5, Line 875: . Also log the table name here? http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/events/MetastoreEvents.java File fe/src/main/java/org/apache/impala/catalog/events/MetastoreEvents.java: http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/events/MetastoreEvents.java@595 PS5, Line 595: Pair<Boolean, Boolean> result = catalog_.reloadPartitionIfExists(dbName_, Codes not quite clear due to the use of Pair. I think we can throw an exception (e.g. TableNotLoadedException) from reloadPartitionIfExists() if the first boolean is false. And deal with the exception in the catch-clause. http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/catalog/events/MetastoreEvents.java@906 PS5, Line 906: Else, this just issues a invalidate : * table on the tblName from the event this comment needs updates too http://gerrit.cloudera.org:8080/#/c/14799/5/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/14799/5/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@3527 PS5, Line 3527: if the HDFSPartition is provided Now the callers all provide it. Add skip logic for null partition at the end? http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/main/java/org/apache/impala/service/CatalogOpExecutor.java@3564 PS5, Line 3564: { return; } nit: don't need braces http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/test/java/org/apache/impala/catalog/events/MetastoreEventsProcessorTest.java File fe/src/test/java/org/apache/impala/catalog/events/MetastoreEventsProcessorTest.java: http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/test/java/org/apache/impala/catalog/events/MetastoreEventsProcessorTest.java@891 PS5, Line 891: invalidate stale comment: refresh. Same in the following comments. http://gerrit.cloudera.org:8080/#/c/14799/5/fe/src/test/java/org/apache/impala/catalog/events/MetastoreEventsProcessorTest.java@892 PS5, Line 892: loadTable(testTblName); Is there test coverage on alter events on unloaded tables? -- To view, visit http://gerrit.cloudera.org:8080/14799 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I9b4148f6be0f9f946c8ad8f314d64b095731744c Gerrit-Change-Number: 14799 Gerrit-PatchSet: 5 Gerrit-Owner: Vihang Karajgaonkar <[email protected]> Gerrit-Reviewer: Anurag Mantripragada <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Quanlong Huang <[email protected]> Gerrit-Reviewer: Vihang Karajgaonkar <[email protected]> Gerrit-Comment-Date: Wed, 08 Jan 2020 09:38:57 +0000 Gerrit-HasComments: Yes
