[MDEV-6371] QUERY CACHE - Reaping Thread Created: 2014-06-21  Updated: 2014-09-22

Status: Open
Project: MariaDB Server
Component/s: None
Fix Version/s: None

Type: Task Priority: Minor
Reporter: BELUGABEHR Assignee: Unassigned
Resolution: Unresolved Votes: 1
Labels: querycache

Issue Links:
Relates
relates to MDEV-4454 Query Cache Partitioning Open
relates to MDEV-4676 QUERY CACHE - partition lock prune an... Open

 Description   

Created a thread that monitors and cleans up the Query Cache. When an update/insert is made to a table, all queries from that table could be simply marked as invalid and later, the reaper thread could come in to actually return the invalid blocks to the memory system. Same thing with inserting into a full query cache, instead of immediately removing the oldest row, track the N number of oldest rows, just mark the rows as invalid, and have the query not be cached at that point At some point in the future, the oldest ones will be removed by the reaper along with any additional invalid queries and caching will work as normal from there.



 Comments   
Comment by roberto spadim [ 2014-09-22 ]

i think it's something that could be better implemented with table counters
if a table change increase the table counter, and if the query have a counter different from the table counter it's invalid, ok a background process to clean (garbage collect) is wellcome but must check how to allow a good lock (mdev-4454)
other think is table 'partition' using query cache, if some part of table is changed only that part is invalidate not full table (MDEV-4676)

check if this mdev isn't duplicated, if it is please request to close as duplicate

Generated at Thu Feb 08 07:11:23 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.