Config keys

The following section provide more details on configuration options.

Top level

Top-level general config options. These are defined without any sub-section.

KeyTypeDefaultValuesDescription
networkstring"Mainnet""Mainnet", "Testnet", "Stagenet"The network to run on.

[tracing.stdout]

Logging configuration.

KeyTypeDefaultValuesDescription
levelstring"info""error", "warn", "info", "debug", "trace"The minimum level for log events to be displayed.

[p2p.clear_net]

P2P configuration for clear-net.

KeyTypeDefaultValuesDescription
outbound_connectionsunsigned integer640 to MAXThe number of outbound connections to create and maintain.
extra_outbound_connectionsunsigned integer80 to MAXThe number of extra connections to create when under load from the rest of Cuprate, i.e. when syncing.
max_inbound_connectionsunsigned integer1280 to MAXThe maximum number of incoming to allow.
gray_peers_percentdecimal number0.70.0 to 1.0The percent of outbound connections that should be to nodes we have not connected to before.
p2p_portPort (unsigned integer)00 to 65535The port to accept connections on, if left 0 no connections will be accepted.
listen_onIPv4 address (string)"0.0.0.0"The IP address to listen to connections on.

[p2p.clear_net.address_book_config]

P2P configuration for the clear-net address book.

KeyTypeDefaultValuesDescription
max_white_list_lengthunsigned integer1_0000 to MAXThe size of the white peer list, which contains peers we have made a connection to before.
max_gray_list_lengthunsigned integer5_0000 to MAXThe size of the gray peer list, which contains peers we have not made a connection to before.
peer_save_period{ seconds, nanoseconds }{ secs = 90, nanos = 0 }0 to MAXThe amount of time between address book saves.

[p2p.block_downloader]

Block downloader configuration.

KeyTypeDefaultValuesDescription
buffer_sizeunsigned integer50_000_0000 to MAXThe size of the buffer of sequential blocks waiting to be verified and added to the chain in bytes.
in_progress_queue_sizeunsigned integer50_000_0000 to MAXThe size of the queue of blocks which are waiting for a parent block to be downloaded in bytes.
target_batch_sizeunsigned integer5_000_0000 to 100_000_000The target size of a batch of blocks in bytes.
check_client_pool_interval{ seconds, nanoseconds }{ secs = 30, nanos = 0 }0 to MAXThe amount of time between checking the pool of connected peers for free peers to download blocks.

[storage]

Storage configuration.

KeyTypeDefaultValuesDescription
reader_threadsstring"OnePerThread"TODOThe amount of database reader threads to spawn.

[storage.txpool]

Transaction pool configuration.

KeyTypeDefaultValuesDescription
sync_modestring"Async"TODOThe database sync mode for the transaction pool.
max_txpool_byte_sizeunsigned integer100_000_000TODOThe maximum size of all the transaction in the pool in bytes.

[storage.blockchain]

Blockchain configuration.

KeyTypeDefaultValuesDescription
sync_modestring"Async"TODOThe database sync mode for the blockchain.