Module light

Source

Structs§

BLOCK_TX_REQUEST_TIMEOUT
BLOOM_REQUEST_TIMEOUT
CACHE_TIMEOUT
Items not accessed for this amount of time are removed from the cache.
CLEANUP_PERIOD
Frequency of checking request timeouts.
EPOCH_REQUEST_TIMEOUT
Request timeouts.
HEADER_REQUEST_TIMEOUT
HEARTBEAT_PERIOD
Frequency of sending StatusPing message to peers.
MAX_POLL_TIME
Maximum time period we wait for a response for an on-demand query. After this timeout has been reached, we try another peer or give up.
RECEIPT_REQUEST_TIMEOUT
STATE_ENTRY_REQUEST_TIMEOUT
STATE_ROOT_REQUEST_TIMEOUT
STORAGE_ROOT_REQUEST_TIMEOUT
SYNC_PERIOD
Frequency of re-triggering sync.
TX_INFO_REQUEST_TIMEOUT
TX_REQUEST_TIMEOUT
WITNESS_REQUEST_TIMEOUT

Constants§

BLAME_CHECK_OFFSET
During syncing, we might transiently have enough malicious blaming blocks to consider a correct header incorrect. For this reason, we first wait for enough header to accumulate before checking blaming. TODO(thegaram): review value and expose this as a parameter
BLOCK_TX_REQUEST_BATCH_SIZE
BLOOM_REQUEST_BATCH_SIZE
CATCH_UP_EPOCH_LAG_THRESHOLD
The threshold controlling whether a node is in catch-up mode. A node is in catch-up mode if its local best epoch number is CATCH_UP_EPOCH_LAG_THRESHOLD behind the median of the epoch numbers of peers.
EPOCH_REQUEST_BATCH_SIZE
(Maximum) number of items requested in a single request.
GAS_PRICE_BATCH_SIZE
GAS_PRICE_BLOCK_SAMPLE_SIZE
GAS_PRICE_TRANSACTION_SAMPLE_SIZE
HEADER_REQUEST_BATCH_SIZE
LOG_FILTERING_LOOKAHEAD
During log filtering, we stream a set of items (blooms, receipts, txs) to match against. To make the process faster, we need to make sure that there’s always plenty of items in flight. This way, we can reduce idle time when we’re waiting to receive an item.
MAX_BLOCK_TXS_IN_FLIGHT
MAX_BLOOMS_IN_FLIGHT
MAX_EPOCHS_TO_SEND
Max number of epochs/headers/txs to send to a light peer in a response.
MAX_HEADERS_IN_FLIGHT
Maximum number of in-flight items at any given time. If we reach this limit, we will not request any more.
MAX_HEADERS_TO_SEND
MAX_ITEMS_TO_SEND
MAX_PARALLEL_EPOCH_REQUESTS
Maximum number of in-flight epoch requests at any given time. Similar to MAX_HEADERS_IN_FLIGHT. However, it is hard to match hash responses to epoch requests, so we count the requests instead.
MAX_RECEIPTS_IN_FLIGHT
MAX_STATE_ENTRIES_IN_FLIGHT
MAX_STATE_ROOTS_IN_FLIGHT
MAX_STORAGE_ROOTS_IN_FLIGHT
MAX_TXS_IN_FLIGHT
MAX_TXS_TO_SEND
MAX_TX_INFOS_IN_FLIGHT
MAX_WITNESSES_IN_FLIGHT
MAX_WITNESSES_TO_SEND
NUM_EPOCHS_TO_REQUEST
Number of epochs to request in one round (in possibly multiple batches).
NUM_WAITING_HEADERS_THRESHOLD
Minimum number of missing items in the sync pipeline. If we have fewer, we will try to request some more.
RECEIPT_REQUEST_BATCH_SIZE
STATE_ENTRY_REQUEST_BATCH_SIZE
STATE_ROOT_REQUEST_BATCH_SIZE
STORAGE_ROOT_REQUEST_BATCH_SIZE
TRANSACTION_COUNT_PER_BLOCK_WATER_LINE_LOW
TRANSACTION_COUNT_PER_BLOCK_WATER_LINE_MEDIUM
TX_INFO_REQUEST_BATCH_SIZE
TX_REQUEST_BATCH_SIZE
WITNESS_REQUEST_BATCH_SIZE