Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
108054: kvserver: always log store rebalancer transfers and relocates r=andrewbaptist a=kvoli

Previously, the store rebalancer would not default log range lease transfers or replica relocations, nor their estimated load impact. This made debugging imbalance related issues difficult.

Bump the range relocation and range lease transfer log lines from `v(1)` to `Info`, so that they are always logged.

Resolves: cockroachdb#107702

Release note: None

Co-authored-by: Austen McClernon <[email protected]>
  • Loading branch information
craig[bot] and kvoli committed Aug 7, 2023
2 parents d057bda + 7f5ffa5 commit cdf6d15
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions pkg/kv/kvserver/store_rebalancer.go
Original file line number Diff line number Diff line change
Expand Up @@ -655,9 +655,8 @@ func (sr *StoreRebalancer) applyRangeRebalance(
voterTargets, nonVoterTargets []roachpb.ReplicationTarget,
) bool {
descBeforeRebalance, _ := candidateReplica.DescAndSpanConfig()
log.KvDistribution.VEventf(
log.KvDistribution.Infof(
ctx,
1,
"rebalancing r%d (%s load) to better balance load: voters from %v to %v; non-voters from %v to %v",
candidateReplica.GetRangeID(),
candidateReplica.RangeUsageInfo().Load(),
Expand Down Expand Up @@ -800,9 +799,8 @@ func (sr *StoreRebalancer) chooseLeaseToTransfer(
continue
}
if targetStore, ok := rctx.allStoresList.FindStoreByID(candidate.StoreID); ok {
log.KvDistribution.VEventf(
log.KvDistribution.Infof(
ctx,
1,
"transferring lease for r%d load=%s to store s%d load=%s from local store s%d load=%s",
desc.RangeID,
candidateReplica.RangeUsageInfo().TransferImpact(),
Expand Down

0 comments on commit cdf6d15

Please sign in to comment.