Using a large -dbcache
leads to “minutes” longs leveldb cache flushes.
Right now, the GUI freezes during FlushStateToDisk
which means one can’t even bring the window to the front.
It would be great to either display a modal dialog “flushing database state” (and lock GUI interactions) or even allow interacting with the GUI during a flush (may be non trivial to solve).
Moved from bitcoin/bitcoin#18137.