cockroach icon indicating copy to clipboard operation
cockroach copied to clipboard

gcjob: issue DeleteRange tombstones and then wait for GC

Open ajwerner opened this issue 3 years ago • 1 comments

Note that this does not change anything about tenant GC.

Fixes https://github.com/cockroachdb/cockroach/issues/70427

Release note (sql change): The asynchronous garbage collection process has been changed such that very soon after dropping a table, index, or database, or after refreshing a materialized view, the system will issue range deletion tombstones over the dropped data. These tombstones will result in the KV statistics properly counting these bytes as garbage. Before this change, the asynchronous "gc job" would wait out the TTL and then issue a lower-level operation to clear out the data. That meant that while the job was waiting out the TTL, the data would appear in the statistics to still be live. This was confusing.

ajwerner avatar Aug 10 '22 05:08 ajwerner

This change is Reviewable

cockroach-teamcity avatar Aug 10 '22 05:08 cockroach-teamcity

TFTR!

bors r+

ajwerner avatar Aug 14 '22 20:08 ajwerner

Build failed:

craig[bot] avatar Aug 14 '22 21:08 craig[bot]

The test failure was in //pkg/ui/workspaces/db-console. I can't see how that'd be related, so I'm going to try again.

bors r+

ajwerner avatar Aug 14 '22 21:08 ajwerner

Build succeeded:

craig[bot] avatar Aug 14 '22 23:08 craig[bot]