Skip to content

Comments

fix(cache): handle null last_accessed_at in eviction and cap batch size#9539

Merged
cschmatzler merged 1 commit intomainfrom
cschmatzler/fix-migration-again
Feb 20, 2026
Merged

fix(cache): handle null last_accessed_at in eviction and cap batch size#9539
cschmatzler merged 1 commit intomainfrom
cschmatzler/fix-migration-again

Conversation

@cschmatzler
Copy link
Member

@cschmatzler cschmatzler commented Feb 19, 2026

Summary

  • Remove the backfill UPDATE from the last_accessed_at migration, allowing the column to be nullable for existing rows because backfilling was way too slow
  • Update the eviction query in KeyValueEntries.delete_expired/1 to also delete entries where last_accessed_at IS NULL
  • Cap eviction batches to 10,000 rows per execution to bound query cost

@dosubot dosubot bot added size:S For issues that take an hour to implement type:bug Something isn't working labels Feb 19, 2026
@dosubot
Copy link

dosubot bot commented Feb 19, 2026

Related Documentation

Checked 1 published document(s) in 1 knowledge base(s). No updates required.

How did I do? Any feedback?  Join Discord

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Feb 19, 2026
@cschmatzler cschmatzler force-pushed the cschmatzler/fix-migration-again branch from b5d0dbd to 4f40615 Compare February 20, 2026 09:05
@cschmatzler cschmatzler merged commit 0ca6fc8 into main Feb 20, 2026
11 checks passed
@cschmatzler cschmatzler deleted the cschmatzler/fix-migration-again branch February 20, 2026 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer size:S For issues that take an hour to implement type:bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants