package
25.1.0+incompatible
Repository: https://github.com/cockroachdb/cockroach.git
Documentation: pkg.go.dev

# Functions

NewController returns a new instance of idxusage.Controller.
NewLocalIndexUsageStats returns a new instance of LocalIndexUsageStats.
NewLocalIndexUsageStatsFromExistingStats returns a new instance of LocalIndexUsageStats that is populated using given []roachpb.CollectedIndexUsageStatistics.

# Constants

DefaultChannelSize is the default size of the statsChan.

# Variables

DropUnusedIndexDuration registers the index unuse duration at which we begin to recommend dropping the index.
Enable determines whether to collect per-index usage statistics.

# Structs

Config is the configuration struct used to instantiate the LocalIndexUsageStats.
Controller implements the index usage stats subsystem control plane.
IndexStatsRow is a wrapper type around serverpb.TableIndexStatsResponse_ExtendedCollectedIndexUsageStatistics that implements additional methods to support unused index recommendations and hold testing knobs.
IteratorOptions provides knobs to change the iterating behavior when calling ForEach.
LocalIndexUsageStats is a node-local provider of index usage statistics.
UnusedIndexRecommendationTestingKnobs provides hooks and knobs for unit tests.

# Type aliases

StatsVisitor is the callback invoked when calling ForEach.