Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add create_date to our index usage statistics telmetry #84458

Closed
kevin-v-ngo opened this issue Jul 14, 2022 · 3 comments · Fixed by #87448
Closed

Add create_date to our index usage statistics telmetry #84458

kevin-v-ngo opened this issue Jul 14, 2022 · 3 comments · Fixed by #87448
Assignees
Labels
C-enhancement Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)

Comments

@kevin-v-ngo
Copy link

kevin-v-ngo commented Jul 14, 2022

We added a create_date to crdb_internal.table_indexes. We should capture this piece of information in our telemetry channel as well for index usage statistics.

Related PR that added index usage statistics: #72486

Jira issue: CRDB-17669

@kevin-v-ngo kevin-v-ngo added C-enhancement Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception) T-sql-observability labels Jul 14, 2022
@pransudash
Copy link
Contributor

Could we also add the database_id if that exists? Currently we get the database_name, table_name, table_id, index_name, index_id but in many cases the database_name is redacted and we can't uniquely identify an index if two tables have the same name (since the database_name would be '<x>')

@kevin-v-ngo
Copy link
Author

kevin-v-ngo commented Aug 2, 2022

Unfortunately we ran into a few complications adding the database_id potentially impacting the customer workload. But we should have already unredacted the database_name.

@pransudash
Copy link
Contributor

pransudash commented Aug 2, 2022

yeah I see database_names in the latest data. Just wanted to make sure you were aware of potential issues with historical data

@ericharmeling ericharmeling self-assigned this Sep 6, 2022
ericharmeling added a commit to ericharmeling/cockroach that referenced this issue Sep 7, 2022
This commit adds a creation timestamp to the index usage
statistics telemetry.

Fixes cockroachdb#84458.

Release justification: low-risk updates to new functionality
Release note(sql change): Added a creation timestamp to index usage statistics
telemetry.
craig bot pushed a commit that referenced this issue Sep 7, 2022
87448: sql: add created_at to index usage stat telemetry r=ericharmeling a=ericharmeling

This commit adds a creation timestamp to the index usage
statistics telemetry.

Fixes #84458.

Release justification: low-risk updates to new functionality
Release note(sql change): Added a creation timestamp to index usage statistics
telemetry.

Co-authored-by: Eric Harmeling <[email protected]>
@craig craig bot closed this as completed in 2f1db38 Sep 7, 2022
ericharmeling added a commit to ericharmeling/cockroach that referenced this issue Sep 8, 2022
This commit adds a creation timestamp to the index usage
statistics telemetry.

Fixes cockroachdb#84458.

Release justification: low-risk updates to new functionality
Release note(sql change): Added a creation timestamp to index usage statistics
telemetry.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Solution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants