Update storage used on zoekt index after indexing tasks complete
What does this MR do and why?
Add scheduling worker to update storage used on zoekt index
This is part 2 of a 2 part process to make calculate storage watermarks more efficient.
Part 1 is here: !166398 (merged)
Query Plan
SELECT SUM("zoekt_repositories"."size_bytes") FROM "zoekt_repositories" WHERE "zoekt_repositories"."zoekt_index_id" = 12
UPDATE "zoekt_indices" SET "updated_at" = '2024-09-26 23:33:47.204699', "used_storage_bytes" = 209715200.0 WHERE "zoekt_indices"."id" = 12
https://postgres.ai/console/gitlab/gitlab-production-main/sessions/31978/commands/98974
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Before | After |
---|---|
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
Edited by John Mason