Quanlong Huang has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/24629 )

Change subject: IMPALA-14618: Fix EventProcessor race with catalog reset
......................................................................


Patch Set 7:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/24629/7/fe/src/main/java/org/apache/impala/catalog/events/TableEventExecutor.java
File fe/src/main/java/org/apache/impala/catalog/events/TableEventExecutor.java:

http://gerrit.cloudera.org:8080/#/c/24629/7/fe/src/main/java/org/apache/impala/catalog/events/TableEventExecutor.java@196
PS7, Line 196:         
eventProcessor.getDeleteEventLog().addRemovedObject(event.getEventId(),
I think we still need this since the thread in addTableIfNotRemovedLater() 
could get the db before catalog reset thread udpates the db. Then 
addTableIfNotRemovedLater() adds the table to the stale db. It won't be a 
correctness issue since catalog reset replaces the db with a new one. But it's 
more clean to skip the on-going CREATE_TABLE when we see the corresponding 
DROP_TABLE event.

On the other hand, even without resets, I think it could still happen that a 
CREATE_TABLE is being processing (in addTableIfNotRemovedLater) and then the 
DROP_TABLE event is enqueued. Adding this to DeleteEventLog increases the 
chance to skip the CREATE_TABLE event. So we won't see an ephemeral table being 
added and then dropped by DROP_TABLE.

Adding this to DeleteEventLog is harmless and consistent with the removal code 
at
https://github.com/apache/impala/blob/e2aeb0a6bda7012f8aba083f74c61cbaaa16d635/fe/src/main/java/org/apache/impala/catalog/events/TableEventExecutor.java#L279

> We can remove TODO added in MetastoreEventsProcessor.java as well.

Could you leave a comment on that line mentioning the reason? We can discuss 
more there.



--
To view, visit http://gerrit.cloudera.org:8080/24629
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifa0833c09cd7ec2461a0f2d1db7ab5a72ab6822b
Gerrit-Change-Number: 24629
Gerrit-PatchSet: 7
Gerrit-Owner: Quanlong Huang <[email protected]>
Gerrit-Reviewer: Anonymous Coward <[email protected]>
Gerrit-Reviewer: Csaba Ringhofer <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Joe McDonnell <[email protected]>
Gerrit-Reviewer: Nandor Kollar <[email protected]>
Gerrit-Reviewer: Quanlong Huang <[email protected]>
Gerrit-Reviewer: Sai Hemanth Gantasala <[email protected]>
Gerrit-Reviewer: Yida Wu <[email protected]>
Gerrit-Comment-Date: Sun, 23 Aug 2026 13:53:35 +0000
Gerrit-HasComments: Yes

Reply via email to