-
Notifications
You must be signed in to change notification settings - Fork 4.1k
sql: persistent SQL Stats main tracking issue #64743
Copy link
Copy link
Closed
Labels
A-sql-cli-observabilityIssues related to surfacing SQL observability in SHOW, CRDB_INTERNAL, SYSTEM, etc.Issues related to surfacing SQL observability in SHOW, CRDB_INTERNAL, SYSTEM, etc.C-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
Description
This is the main tracking issue for all persisted SQL Stats related work:
Infrastructure:
- system table schema:
- JSON encoding for stats objects:
- flush mechanism:
- a feature flag + version gate :
- Clean up old stats using job
- Runs the clean up job on a schedule
- Running benchmark with new persisted SQL stats turned on to measure the performance impact.
Minimum Requirement to enable it by default by 21.2
- Serve both cluster-wide in-memory stats with persisted SQL stats through a virtual table
- sql: support decode ExplainTreePlanNode from JSON format #68555
- sql: reimplement sqlstats API using iterator #68620
- sql: implement IterateStatementStats() for PersistedSQLStats #68675
- sql: introduce crdb_internal.statement_statistics virtual table #68715
- sql: implement combined iterator for transaction statistics #69022
- sql: implement crdb_internal.transaction_statistics #69049
- sql: fix in-memory stmt stats not properly updating #69441
- Update status RPC/HTTP endpoint to be able to be queried by aggregation interval.
- Update the DB Console Statement/Transaction Page to include a time picker to select aggregation interval.
- Extend Reset SQL Stats to support resetting on-disk stats.
Further Enhancement
- sql: implement sql stats compaction for clean up job #69302
- sql: better eviction policy for sql stats in-memory store #69303
- sql: batch SQL stats flush #67867
- server: add memory accouting for Statements gRPC endpoint #69032
- sql: implement virtual index on
crdb_internal.{statement, transaction}_statistics#69321 - sql: surface sql stats compaction job details in SQL CLI #69429
- Query plan changes can be easily detected through our internal tables and the SQL CLI #67500
Clean Up
- server: Consolidate serverpb.CollectedStatementStatistics #69326
- ui: Transaction page inconsistent grouping of statement stats #59205
- sql: use persisted sql stats for telemetry reporting #66047
RFC PR: #63752
Epic: CRDB-9866
Jira issue: CRDB-7226
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
A-sql-cli-observabilityIssues related to surfacing SQL observability in SHOW, CRDB_INTERNAL, SYSTEM, etc.Issues related to surfacing SQL observability in SHOW, CRDB_INTERNAL, SYSTEM, etc.C-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)