Skip to content

Commit

Permalink
Merge bitcoin#28569: log: Don't log cache rebalancing in absense of a…
Browse files Browse the repository at this point in the history
… snapshot chainstate

ec84f99 log: Don't log cache rebalancing in absense of a snapshot chainstate (Fabian Jahr)

Pull request description:

  I have noticed that this log now is always printed, even if there is no snapshot chainstate present or even was present. I think this is confusing to users that have never even thought about using assumeutxo since in that case the rebalancing is just ensuring the normal environment with one chainstate. So I suggest we don't log in absence of a snapshot chainstate. We could also think about rewording the message instead but I think this is simpler.

ACKs for top commit:
  stickies-v:
    utACK ec84f99
  glozow:
    concept ACK ec84f99, don't have opinions other than removing confusing log
  theStack:
    utACK ec84f99

Tree-SHA512: 30bbfc648e7c788106f78d52e47a3aa1e1874f65d13743643dc50bcf7f450d8330711ff9fdeac361722542da6051533153829c6d49033227ed315e111afc899f
  • Loading branch information
fanquake committed Oct 20, 2023
2 parents fc1073b + ec84f99 commit 3c856e2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/validation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5711,8 +5711,8 @@ void ChainstateManager::MaybeRebalanceCaches()
assert(ibd_usable || snapshot_usable);

if (ibd_usable && !snapshot_usable) {
LogPrintf("[snapshot] allocating all cache to the IBD chainstate\n");
// Allocate everything to the IBD chainstate.
// Allocate everything to the IBD chainstate. This will always happen
// when we are not using a snapshot.
m_ibd_chainstate->ResizeCoinsCaches(m_total_coinstip_cache, m_total_coinsdb_cache);
}
else if (snapshot_usable && !ibd_usable) {
Expand Down

0 comments on commit 3c856e2

Please sign in to comment.