github-actions[bot] commented on code in PR #69028:
URL: https://github.com/apache/doris/pull/69028#discussion_r4355140831
##########
fe/fe-core/src/main/java/org/apache/doris/statistics/repository/StatisticsCleaner.java:
##########
@@ -140,6 +140,8 @@ private void clearTableStats() {
}
LOG.info("Table {}.{}.{} with id {} not exist, remove its
table stats record.",
stats.ctlName, stats.dbName, stats.tblName, id);
+ // No table lock: the table is gone, so no load can recreate
the record of this id while the
Review Comment:
[P2] Order cleaner deletion with recovery of the same table ID
`RECOVER TABLE` re-registers the recycled `Table` with its original ID, so
the absence observed here does not prevent load-driven recreation. The cleaner
can capture `stats` before DROP, observe the dropped table, remove its record,
and pause before journaling DELETE. Run `RECOVER TABLE t; TRUNCATE TABLE t;
INSERT ...` with N rows, then resume the cleaner: the master retains the
load-created record, while replay applies RECOVER -> TRUNCATE -> VISIBLE
(create N) -> DELETE (remove). With the replacement tablets still unreported,
`Project(*) -> OlapScan(t)` consequently estimates N on the master but 1 after
replay/failover. The old get-only load path left both records absent. This is a
separate remover from the existing DROP STATS/schema threads. Serialize the
cleaner's absence check and removal/journal with recovery/load publication, and
cover this interleaving with barriers.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]