From 14437fce99617142871c87d224bd7ee09461706e Mon Sep 17 00:00:00 2001 From: garyschulte Date: Thu, 5 Dec 2024 10:11:55 -0800 Subject: [PATCH] add more logging, drop forced commit interval to 5k Signed-off-by: garyschulte --- .../subcommands/storage/RebuildBonsaiStateTrieSubCommand.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/besu/src/main/java/org/hyperledger/besu/cli/subcommands/storage/RebuildBonsaiStateTrieSubCommand.java b/besu/src/main/java/org/hyperledger/besu/cli/subcommands/storage/RebuildBonsaiStateTrieSubCommand.java index 3fb0b2a9f27..261fc5b2c74 100644 --- a/besu/src/main/java/org/hyperledger/besu/cli/subcommands/storage/RebuildBonsaiStateTrieSubCommand.java +++ b/besu/src/main/java/org/hyperledger/besu/cli/subcommands/storage/RebuildBonsaiStateTrieSubCommand.java @@ -60,7 +60,7 @@ public class RebuildBonsaiStateTrieSubCommand implements Runnable { private static final Logger LOG = LoggerFactory.getLogger(RebuildBonsaiStateTrieSubCommand.class); private static final Hash HASH_LAST = Hash.wrap(Bytes32.leftPad(Bytes.fromHexString("FF"), (byte) 0xFF)); - static final long FORCED_COMMIT_INTERVAL = 50_000L; + static final long FORCED_COMMIT_INTERVAL = 5_000L; @SuppressWarnings("unused") @ParentCommand @@ -256,6 +256,7 @@ Hash rebuildAccountTrie( // commit the account storage trie if (accountStorageCount++ % FORCED_COMMIT_INTERVAL == 0) { + LOG.info("interim commit for account hash {}, at {}", accountHash, storagePair.getFirst()) accountStorageCommit.accept(accountStorageTrie); accountStorageTx.commitAndReopen(); // new trie with new root, GC trie nodes