Open Xiang-Gu opened 1 year ago
This is bad, but doesn't seem super urgent. Generally we'd expect these temp indexes to not be very big.
We added a builtin to force GC of table data, but we didn't add an equivalent for indexes or an easy way to find such index spans. We could do something parallel to crdb_internal.force_delete_table_data
and the virtual table crdb_internal.lost_table_descriptors
.
Also, for context, this is new in 22.1, when we started using these temp indexes as part of the new index backfill protocol
When we create an unique secondary index that fails at validation step, we rollback. One of the last things rolling back does is to create GC jobs are this unique secondary index and its temp index. This is the case for legacy schema changer but not declarative schema changer, as shown below:
Jira issue: CRDB-25201