Commit dd6cb78
committed
core: add runtime endBlock completion check
Add a runtime check in run_indexing that detects when the Amp Flight
server's latest block covers through every data source's endBlock, even
when no entity data exists at the endBlock itself. Previously, the only
completion check compared the persisted block pointer (which only
advances when data is written) against endBlock, causing an infinite
polling loop when endBlock has no data.
The check compares latest_block (min MAX(_block_num) across
non-completed tables) against max_end_block (max end_block across all
data sources). If latest_block >= max_end_block, all SQL queries have
been served and indexing completes.1 parent df73b96 commit dd6cb78
1 file changed
+14
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
127 | 127 | | |
128 | 128 | | |
129 | 129 | | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
130 | 144 | | |
131 | 145 | | |
132 | 146 | | |
| |||
0 commit comments