This is a minimally invasive approach to shutdown on LevelDB read errors from the chainstate, while keeping user interface out of the common library, which is shared between bitcoind, and bitcoin‐qt and non‐server tools.
Synopsis
Declared in <coins.h>
class CCoinsViewErrorCatcher final
: public CCoinsViewBacked
Description
Writes do not need similar protection, as failure to write is handled by the caller.
Base Classes
Name |
Description |
CCoinsView backed by another CCoinsView |
Member Functions
Name |
Description |
|
Construct the error catcher wrapping a backing view. |
Register a callback to run when a LevelDB read error occurs. |
|
|
Forward the bulk write to the backing view. |
|
Forward the size estimate to the backing view. |
|
Forward the best‐block query to the backing view. |
|
Retrieve a coin, running the error callbacks on a read failure. |
|
Forward the head‐blocks query to the backing view. |
|
Check whether an outpoint is unspent, running the error callbacks on a read failure. |
|
Retrieve a coin without caching, running the error callbacks on a read failure. |
Replace the backing view. |