Skip to content

Commit

Permalink
more fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ywangd committed Nov 18, 2024
1 parent 0b03f4e commit a432406
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -294,15 +294,15 @@ private void setCurrentDesiredBalance(DesiredBalance newDesiredBalance) {
});

if (updatedDesiredBalance == newDesiredBalance) {
assert oldDesiredBalance.get() != null;
if (logger.isTraceEnabled()) {
var diff = DesiredBalance.hasChanges(updatedDesiredBalance, newDesiredBalance)
? "Diff: " + DesiredBalance.humanReadableDiff(updatedDesiredBalance, newDesiredBalance)
var diff = DesiredBalance.hasChanges(oldDesiredBalance.get(), newDesiredBalance)
? "Diff: " + DesiredBalance.humanReadableDiff(oldDesiredBalance.get(), newDesiredBalance)
: "No changes";
logger.trace("Desired balance updated: {}. {}", newDesiredBalance, diff);
} else {
logger.debug("Desired balance updated for [{}]", newDesiredBalance.lastConvergedIndex());
}
assert oldDesiredBalance.get() != null;
computedShardMovements.inc(DesiredBalance.shardMovements(oldDesiredBalance.get(), newDesiredBalance));
} else {
logger.debug("discard desired balance for [{}]", newDesiredBalance.lastConvergedIndex());
Expand Down

0 comments on commit a432406

Please sign in to comment.