feat: replace LastestDeposit with LastProcessedBlock
Currently the teleportr database supports a LatestDeposit method, which returns the highest block number observed, if any. The intent was to use this as the starting point for syncing, however, this isn't super useful as there may be long periods of inactivity that we have already scanned. Instead, we now store the last processed block in a separate table, and pass the end of the ingestion block range as argument to UpsertDeposits. The list of deposits and last processed block are written atomically to avoid consistency issues. The value can be retrieved using the LastProcessedBlock getter.
Showing
Please register or sign in to comment