Skip to content

Commit

Permalink
local-network stabilization
Browse files Browse the repository at this point in the history
  • Loading branch information
vsuharnikov committed Nov 28, 2024
1 parent 6f265f0 commit 83ef4cc
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class NodeHttpApi(apiUri: Uri, backend: SttpBackend[Identity, ?], apiKeyValue: S
if (currHeight >= atLeast) currHeight
else {
Thread.sleep(patienceConfig.interval.toMillis)
val waitBlocks = (atLeast - currHeight).min(1)
val waitBlocks = (atLeast - currHeight).max(1)
eventually(timeout(MaxBlockDelay * waitBlocks)) {
val h = height()(subsequentLoggingOptions)
h should be >= atLeast
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ class WavesNodeContainer(
"NODE_NUMBER" -> s"$number",
"WAVES_WALLET_SEED" -> Base58.encode(baseSeed.getBytes(StandardCharsets.UTF_8)),
"JAVA_OPTS" -> List(
"-Dwaves.miner.quorum=0",
s"-Dunits.defaults.chain-contract=$chainContractAddress",
s"-Dunits.defaults.execution-client-address=$ecEngineApiUrl",
"-Dlogback.file.level=TRACE",
Expand Down
4 changes: 2 additions & 2 deletions local-network/configs/wavesnode/genesis-template.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ genesis-generator {
# Private key: 5r7KpS3MNXxRcz9jMbpjZKhaZVxDxF74H4VLW6ydi4aT
# Public key: 2JYMTjUK7tC8NQi6TD6oWgy41YbrnXuoLzZydrFKTKt6
# Address: 3FSgXpgbT6m1speWgVx3cVxAZKmdr4barHU
{ seed-text = "devnet-1", nonce = 1, amount = 998036000000000 }
{ seed-text = "devnet-1", nonce = 1, amount = 900000000000000 }

# Miner on wavesnode-2
# Seed text: devnet-2
Expand All @@ -33,7 +33,7 @@ genesis-generator {
# Private key: F17jrRWmrR7en6eY6ptvnUTNqc9W8RSP34hpX7bNhbht
# Public key: FuibB1rJ1uHVvvY6FNmhLqnbvQBNtziWbh7zh5c1CQCG
# Address: 3FSrRN8X7cDsLyYTScS8Yf8KSwZgJBwf1jU
{ seed-text = "devnet-2", nonce = 0, amount = 998036000000000 }
{ seed-text = "devnet-2", nonce = 0, amount = 800900102030000 }

# Additional addresses

Expand Down
4 changes: 3 additions & 1 deletion local-network/configs/wavesnode/waves.conf
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ waves {
micro-block-interval = 200ms
max-transactions-in-micro-block = 500
min-micro-block-age = 0ms
quorum = 0
quorum = 1 # Solves a simultaneous mining on start
interval-after-last-block-then-generation-is-allowed = 120d
}

Expand Down Expand Up @@ -115,6 +115,8 @@ waves {
minimum-peers = 0
}

ntp-server = "47.91.111.180" # TODO: set to null after https://github.com/wavesplatform/Waves/pull/3978

# Nodes synchronization settings
synchronization {
# Timeout to receive all requested blocks
Expand Down

0 comments on commit 83ef4cc

Please sign in to comment.