Add CacheSQLite (#13131)

Persist is intended for larger objects, which works best for things like cached tiles with some metadata.

For many small to medium entries that you nevertheless don't necessarily want to keep around in memory, that seems a bit inefficient.

SQLite then, is effectively a way of minimizing the amount of writes in this scenario.

Relates to #13061. Depends on #13122.
This commit is contained in:
Frans de Jonge
2025-01-29 21:33:44 +01:00
committed by GitHub
parent c1f6a02fa0
commit 63bf9d5bdf
3 changed files with 314 additions and 3 deletions

View File

@@ -1,6 +1,8 @@
--[[
A LRU cache, based on https://github.com/starius/lua-lru
]]--
--[[--
An LRU cache, based on https://github.com/starius/lua-lru
@module cache
--]]
local lfs = require("libs/libkoreader-lfs")
local logger = require("logger")