Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion node/src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ build_config! {
(log_contract_address, (String), "".to_string())
(log_sync_start_block_number, (u64), 0)
(force_log_sync_from_start_block_number, (bool), false)
(confirmation_block_count, (u64), 3)
(confirmation_block_count, (u64), 1)
(log_page_size, (u64), 999)
(max_cache_data_size, (usize), 100 * 1024 * 1024) // 100 MB
(cache_tx_seq_ttl, (usize), 500)
Expand Down
72 changes: 70 additions & 2 deletions run/config_example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,12 @@ stream_ids = ["000000000000000000000000000000000000000000000000000000000000f2bd"

# Directory to store data.
db_dir = "db"

# Directory to store KV Metadata.
kv_db_dir = "kv.DB"
kv_db_file = "kv.DB"

# Cache capacity for merkle tree nodes in bytes (default 32 MB).
# merkle_node_cache_capacity = 33554432

#######################################################################
### Log Sync Config Options ###
Expand All @@ -24,6 +28,45 @@ blockchain_rpc_endpoint = ""
log_contract_address = ""
log_sync_start_block_number = 0

# Force resync from start block number, ignoring any previously synced progress.
# force_log_sync_from_start_block_number = false

# Number of confirmations required before a block is considered final.
# confirmation_block_count = 1

# Number of logs to fetch per RPC query page.
# log_page_size = 999

# Maximum size of cached data in bytes (default 100 MB).
# max_cache_data_size = 104857600

# TTL for cached transaction sequences.
# cache_tx_seq_ttl = 500

# Number of retries on RPC rate limit errors.
# rate_limit_retries = 100

# Number of retries on RPC timeout errors.
# timeout_retries = 100

# Initial backoff in milliseconds for RPC retries.
# initial_backoff = 500

# Delay in milliseconds between recovery queries.
# recover_query_delay = 50

# Number of blocks from the latest to consider as finalized.
# default_finalized_block_count = 100

# Interval in minutes to remove finalized block data.
# remove_finalized_block_interval_minutes = 30

# Wait time in milliseconds for the watch loop.
# watch_loop_wait_time_ms = 500

# Timeout in seconds for blockchain RPC calls.
# blockchain_rpc_timeout_secs = 120

#######################################################################
### RPC Config Options ###
#######################################################################
Expand All @@ -35,19 +78,44 @@ rpc_enabled = true
rpc_listen_address = "0.0.0.0:6789"

# Indexer endpoint to fetch storage node locations. Leave empty to use zgs_node_urls instead.
indexer_url = "https://indexer-storage-turbo-testnet.0g.ai"
indexer_url = ""

# Static ZGS node list (used when indexer_url is empty).
zgs_node_urls = ""

# Number of chunks per segment for RPC responses.
# rpc_chunks_per_segment = 1024

# Maximum query length in bytes (default 256 KB).
# max_query_len_in_bytes = 262144

# Maximum response body size in bytes (default 30 MB).
# max_response_body_in_bytes = 31457280

# Timeout in seconds for ZGS node RPC calls.
# zgs_rpc_timeout = 5

#######################################################################
### Encryption Options ###
#######################################################################

# Encryption key for data decryption during download and replay.
# Must be a 64-character hex string (32 bytes). Optional 0x prefix is allowed.
# encryption_key = ""

#######################################################################
### Stream Data Sync Options ###
#######################################################################

# Max retries before skipping a failed download. 0 means retry forever.
# max_download_retries = 0

# Timeout for waiting for file locations from indexer/nodes in milliseconds.
# download_timeout_ms = 300000

# Interval between download retry attempts in milliseconds.
# download_retry_interval_ms = 5000

# Wait time between polling iterations in the data fetcher and replayer in milliseconds.
# retry_wait_ms = 1000

Expand Down
69 changes: 68 additions & 1 deletion run/config_testnet_turbo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,12 @@ stream_ids = ["000000000000000000000000000000000000000000000000000000000000f2bd"

# Directory to store data.
db_dir = "db"

# Directory to store KV Metadata.
kv_db_dir = "kv.DB"
kv_db_file = "kv.DB"

# Cache capacity for merkle tree nodes in bytes (default 32 MB).
# merkle_node_cache_capacity = 33554432

#######################################################################
### Log Sync Config Options ###
Expand All @@ -24,6 +28,45 @@ blockchain_rpc_endpoint = "https://evmrpc-testnet.0g.ai"
log_contract_address = "0x22E03a6A89B950F1c82ec5e74F8eCa321a105296"
log_sync_start_block_number = 1

# Force resync from start block number, ignoring any previously synced progress.
# force_log_sync_from_start_block_number = false

# Number of confirmations required before a block is considered final.
# confirmation_block_count = 1

# Number of logs to fetch per RPC query page.
# log_page_size = 999

# Maximum size of cached data in bytes (default 100 MB).
# max_cache_data_size = 104857600

# TTL for cached transaction sequences.
# cache_tx_seq_ttl = 500

# Number of retries on RPC rate limit errors.
# rate_limit_retries = 100

# Number of retries on RPC timeout errors.
# timeout_retries = 100

# Initial backoff in milliseconds for RPC retries.
# initial_backoff = 500

# Delay in milliseconds between recovery queries.
# recover_query_delay = 50

# Number of blocks from the latest to consider as finalized.
# default_finalized_block_count = 100

# Interval in minutes to remove finalized block data.
# remove_finalized_block_interval_minutes = 30

# Wait time in milliseconds for the watch loop.
# watch_loop_wait_time_ms = 500

# Timeout in seconds for blockchain RPC calls.
# blockchain_rpc_timeout_secs = 120

#######################################################################
### RPC Config Options ###
#######################################################################
Expand All @@ -36,19 +79,43 @@ rpc_listen_address = "0.0.0.0:6789"

# Indexer endpoint to fetch storage node locations. Leave empty to use zgs_node_urls instead.
indexer_url = "https://indexer-storage-turbo-testnet.0g.ai"

# Static ZGS node list (used when indexer_url is empty).
zgs_node_urls = ""

# Number of chunks per segment for RPC responses.
# rpc_chunks_per_segment = 1024

# Maximum query length in bytes (default 256 KB).
# max_query_len_in_bytes = 262144

# Maximum response body size in bytes (default 30 MB).
# max_response_body_in_bytes = 31457280

# Timeout in seconds for ZGS node RPC calls.
# zgs_rpc_timeout = 5

#######################################################################
### Encryption Options ###
#######################################################################

# Encryption key for data decryption during download and replay.
# Must be a 64-character hex string (32 bytes). Optional 0x prefix is allowed.
# encryption_key = ""

#######################################################################
### Stream Data Sync Options ###
#######################################################################

# Max retries before skipping a failed download. 0 means retry forever.
# max_download_retries = 3

# Timeout for waiting for file locations from indexer/nodes in milliseconds.
# download_timeout_ms = 10000

# Interval between download retry attempts in milliseconds.
# download_retry_interval_ms = 1000

# Wait time between polling iterations in the data fetcher and replayer in milliseconds.
# retry_wait_ms = 1000

Expand Down
Loading