Modules§
Structs§
- Chunk
Distribution Network Config - Config for the Chunk Distribution Network feature. This allows nodes to push and pull chunks from a central stream. The two benefits of this approach are: (1) less request/response traffic on the peer-to-peer network and (2) lower latency for RPC nodes indexing the chain.
- Chunk
Distribution Uris - URIs for the Chunk Distribution Network feature.
- Client
Config - ClientConfig where some fields can be updated at runtime.
- Cloud
Archival Writer Config - Configuration for a cloud-based archival writer. If this config is present, the writer is enabled and writes chunk-related data based on the tracked shards. This config also controls additional archival behavior such as block data and polling interval.
- Dump
Config - Configures how to dump state to external storage.
- Epoch
Sync Config - External
Storage Config - GCConfig
- Configuration for garbage collection.
- Genesis
Genesishas an invariant thattotal_supplyis equal to the supply seen in the records. However, we can’t enforce that invariant. All fields are public, but the clients are expected to use the provided methods for instantiation, serialization and deserialization. Refer totest_loading_localnet_genesisto see an example of serialized Genesis JSON.- Genesis
Change Config - Config for changes applied to state dump.
- Genesis
Config - Genesis
Records - Records in storage at genesis (get split into shards at genesis creation).
- Interrupt
Handle - A handle that allows the main process to interrupt other.
- Mutable
Config Value - A wrapper for a config value that can be updated while the node is running.
When initializing sub-objects (e.g.
ShardsManager), please make sure to pass this wrapper instead of passing a value from a single moment in time. Seeexpected_shutdownfor an example how to use it. - Protocol
Config - Protocol
Config View - Resharding
Config - Configuration for resharding.
- Resharding
Handle - State
Sync Config - Sync
Concurrency - Updatable
Client Config - A subset of Config that can be updated while the node is running.
Enums§
- External
Storage Location - Supported external storage backends and their minimal config.
- Genesis
Contents - Genesis
Validation Mode - LogSummary
Style - Protocol
Version Check Config - Configures whether the node checks the next or the next next epoch for network version compatibility.
- Sync
Config - Configures how to fetch state parts during state sync.
- Tracked
Shards Config - Describes the expected behavior of the node regarding shard tracking. If the node is an active validator, it will also track the shards it is responsible for as a validator.
Constants§
- BLOCK_
PRODUCER_ KICKOUT_ THRESHOLD - Criterion for kicking out block producers.
- CHUNK_
PRODUCER_ KICKOUT_ THRESHOLD - Criterion for kicking out chunk producers.
- CHUNK_
VALIDATOR_ ONLY_ KICKOUT_ THRESHOLD - Criterion for kicking out chunk validators.
- DEFAULT_
GC_ NUM_ EPOCHS_ TO_ KEEP - Default number of epochs for which we keep store data
- DEFAULT_
STATE_ PARTS_ COMPRESSION_ LEVEL - We haven’t observed meaningful gains from higher compression levels. Even
-5produced a result close to levels 1–3. Therefore we keep 1 as the default. - EXPECTED_
EPOCH_ LENGTH - Expected epoch length.
- FAST_
EPOCH_ LENGTH - FISHERMEN_
THRESHOLD - Fishermen stake threshold.
- GAS_
PRICE_ ADJUSTMENT_ RATE - The rate at which the gas price can be adjusted (alpha in the formula). The formula is gas_price_t = gas_price_{t-1} * (1 + (gas_used/gas_limit - 1/2) * alpha))
- GENESIS_
CONFIG_ FILENAME - INITIAL_
GAS_ LIMIT - Initial gas limit.
- MAX_
INFLATION_ RATE - Maximum inflation rate per year
- MIN_
BLOCK_ PRODUCTION_ DELAY - Expected block production time in ms.
- MIN_
GAS_ PRICE - Initial and minimum gas price.
- MIN_
GC_ NUM_ EPOCHS_ TO_ KEEP - Minimum number of epochs for which we keep store data
- NUM_
BLOCKS_ PER_ YEAR - Expected number of blocks per year
- NUM_
BLOCK_ PRODUCER_ SEATS - Number of seats for block producers
- PROTOCOL_
REWARD_ RATE - Protocol treasury reward
- PROTOCOL_
TREASURY_ ACCOUNT - Protocol treasury account
- PROTOCOL_
UPGRADE_ STAKE_ THRESHOLD - Protocol upgrade stake threshold.
- TRANSACTION_
VALIDITY_ PERIOD - Number of blocks for which a given transaction is valid
Functions§
- default_
archival_ writer_ polling_ interval - default_
chunk_ validation_ threads - default_
chunk_ wait_ mult - default_
chunks_ cache_ height_ horizon - Returns the default value for
chunks_cache_height_horizon. A chunk is out of rear horizon if its height + chunks_cache_height_horizon < largest_seen_height. - default_
enable_ early_ prepare_ transactions - Returns the default value for
enable_early_prepare_transactions. Enabled on nightly as it remains disabled in production builds, and CI will run both with this enabled and disabled. - default_
enable_ multiline_ logging - default_
epoch_ sync - default_
header_ sync_ expected_ height_ per_ second - default_
header_ sync_ initial_ timeout - default_
header_ sync_ progress_ timeout - default_
header_ sync_ stall_ ban_ timeout - default_
log_ summary_ period - default_
orphan_ state_ witness_ max_ size - Returns the default value for maximum data-size (bytes) for a state witness to be included in the OrphanStateWitnessPool.
- default_
orphan_ state_ witness_ pool_ size - Returns the default size of the OrphanStateWitnessPool, ie. the maximum number of state-witnesses that can be accommodated in OrphanStateWitnessPool.
- default_
produce_ chunk_ add_ transactions_ time_ limit - default_
state_ request_ server_ threads - default_
state_ request_ throttle_ period - default_
state_ requests_ per_ throttle_ period - default_
state_ sync_ external_ backoff - default_
state_ sync_ external_ timeout - default_
state_ sync_ p2p_ timeout - default_
state_ sync_ retry_ backoff - default_
sync_ check_ period - default_
sync_ height_ threshold - default_
sync_ max_ block_ requests - default_
sync_ step_ period - default_
transaction_ pool_ size_ limit - default_
transaction_ pool_ strict_ nonce_ ttl_ blocks - default_
trie_ viewer_ state_ size_ limit - default_
tx_ routing_ height_ horizon - default_
view_ client_ threads - get_
initial_ supply - stream_
records_ from_ file - The file can be a JSON with comments