Vihang Karajgaonkar has uploaded this change for review. ( http://gerrit.cloudera.org:8080/16129
Change subject: IMPALA-9913: Use table id to match the table in drop table event ...................................................................... IMPALA-9913: Use table id to match the table in drop table event This patch modifies the matching logic of the table while processing a DROP_TABLE event. The EventsProcessor currently relies on createTime of the table to determine if the table in the catalog matching with the table in the event. It is possible that if there is a time-skew between the different HMS instances and a same table is dropped and recreated, the the creation time of the table which is present in the catalog is less than or equals to the creationTime of a table which is dropped. In such case, there is a false negative during the matching and the DROP_TABLE event is skipped. HIVE-20556 exposes a id field of the table in which can be used to uniquely identify a table. A table which is dropped and recreated with the same name has a different id. This patch makes use of this id to match the table in catalog with the table from the HMS event. Note that the DROP_DATABASE event continues to use createTime for matching. We should use a database id for it when it is available. I have created HIVE-23785 for tracking that on the HMS side. Testing: 1. Ran Events processor tests. Change-Id: Id6a80bbf5757e46318af1b57911fc127d7dd1f01 --- M fe/src/main/java/org/apache/impala/catalog/CatalogServiceCatalog.java M fe/src/test/java/org/apache/impala/catalog/events/MetastoreEventsProcessorTest.java 2 files changed, 10 insertions(+), 10 deletions(-) git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/29/16129/1 -- To view, visit http://gerrit.cloudera.org:8080/16129 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: Id6a80bbf5757e46318af1b57911fc127d7dd1f01 Gerrit-Change-Number: 16129 Gerrit-PatchSet: 1 Gerrit-Owner: Vihang Karajgaonkar <vih...@cloudera.com>