Rollup node: run store migration (to SQLite) in the background
What
This MR makes the rollup node run the v4 -> v5 (i.e. sqlite) migration in the background automatically when started.
This MR is an improvement on !15059 (merged).
Fixes #7526 (closed).
Why
The store migration can be quite long (~1h for an etherlink ghostnet archive node) which might imply a downtime for rollup operators. This MR allows to migrate the data to the SQLite store while the node is running, without any downtime.
How
When the node detects there is a V4 -> V5 store migration to apply, it opens a store in a hybrid mode. In this mode the store is composed both of a read only V4 store in which we fetch information missing from the V5 store and a read-write V5 store in which (1) the rollup node writes new information as it follows the rollup, and (2) migrate data over from the V4 store in a background Lwt thread.
Manually testing the MR
Run a rollup node with this branch on an older (<= v21) data dir and observe the rollup node continues to progress as the migration occurs. The migration should also successfully terminate. (Backup the data dir before running this test.)