Skip to content

Commit

Permalink
server: make SpanStats authoritative
Browse files Browse the repository at this point in the history
This commit guarantees that SpanStats uses up-to-date range
descriptors on all nodes. The dependency on DistSender is removed
and is replaced with a dependency on rangedesc.Scanner.

rangedesc.Scanner is used to:
1) Locate nodes that house replicas of a span to avoid cluster-wide fan-outs.
2) Find Range Descriptors that touch a span, to build a SpanStatsResponse.

This commit also fixes cockroachdb#103809, where a SpanStatsResponse incorrectly returned
the replica_count for a span, instead of the range_count.

Epic: https://cockroachlabs.atlassian.net/browse/CRDB-24928
Issue: cockroachdb#103957
Release note (bug fix): SpanStats is no longer subject to stale
information, and should be considered authoritative.
  • Loading branch information
Zach Lite committed Jun 20, 2023
1 parent ba92ad9 commit 5ce4638
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit 5ce4638

Please sign in to comment.