Crate explorerd

Source

Modulesยง

config ๐Ÿ”’
Configuration management across multiple networks (localnet, testnet, mainnet)
error ๐Ÿ”’
Crate errors
rpc ๐Ÿ”’
Manages JSON-RPC interactions for the explorer
service ๐Ÿ”’
Core logic for block synchronization, chain data access, metadata storage/retrieval, and statistics computation
store ๐Ÿ”’
Manages persistent storage for blockchain, contracts, metrics, and metadata

Structsยง

Args ๐Ÿ”’
Explorerd
Defines a daemon structure responsible for handling incoming JSON-RPC requests and delegating them to the backend layer for processing. It provides a JSON-RPC interface for managing operations related to blocks, transactions, contracts, and metrics.
SignalHandler ๐Ÿ”’
Auxiliary structure used to keep track of signals

Constantsยง

CONFIG_FILE ๐Ÿ”’
CONFIG_FILE_CONTENTS ๐Ÿ”’

Functionsยง

handle_abort ๐Ÿ”’
Auxiliary task to handle SIGINT for forceful process abort
handle_signals ๐Ÿ”’
Auxiliary task to handle SIGHUP, SIGTERM, SIGINT and SIGQUIT signals
log_started_banner ๐Ÿ”’
Logs a banner displaying the startup details of the DarkFi Explorer Node.
main ๐Ÿ”’
realmain ๐Ÿ”’
subscribe_blocks ๐Ÿ”’
Subscribes to new blocks from the darkfid daemon, returning optional stoppable tasks for the subscriber and listener.
sync_blocks ๐Ÿ”’
Synchronizes blocks from the darkfid daemon.