lightning-terminal/db/migsets
Elle Mouton fb5863e38c
multi: wait for lnd with a configurable timeout during SQL migration
The kvdb-to-SQL data migration polls lnd's ListMacaroonIDs RPC, which
only becomes available once lnd reaches its "RPC active" state. On
nodes with a large channel/graph state, lnd can take well over a
minute to get there after the wallet is unlocked, which exceeded the
previous fixed 60-second (120 x 500ms) poll budget and caused the
migration - and therefore litd startup - to fail permanently,
requiring a manual restart.

Replace the fixed attempt cap with a wait bounded by the new
--lndreadytimeout config option, defaulting to a generous 10 minutes,
while still aborting early if the daemon is shutting down. The wait
happens inside the migration's SQL write transaction, so it is kept
bounded rather than unbounded as a safety backstop.
2026-07-29 15:47:47 -07:00
..
log.go migstreams: rename package to migsets 2026-05-14 11:39:12 +02:00
programmatic_migrations.go multi: wait for lnd with a configurable timeout during SQL migration 2026-07-29 15:47:47 -07:00
programmatic_migrations_test.go multi: wait for lnd with a configurable timeout during SQL migration 2026-07-29 15:47:47 -07:00
sql_migrations.go multi: wait for lnd with a configurable timeout during SQL migration 2026-07-29 15:47:47 -07:00
sql_migrations_dev.go multi: wait for lnd with a configurable timeout during SQL migration 2026-07-29 15:47:47 -07:00