dox_cache 3.0.0-alpha.3
dox_cache: ^3.0.0-alpha.3 copied to clipboard
Cache for Dart and the Dox framework. Memory, file and Redis drivers, TTL, locks, tags and remember helpers.
3.0.0-alpha.3 #
- New:
getRaw(key)gives the stored value as JSON text, with no decode. Use it to send a cached value as a JSON response. Memory and Redis return the stored text as is. A stored String comes back with its quotes ("bar"). The stored format did not change, so old values still read the same. - Faster
get: a plain store builds the key with no async step.itemKeynow returnsFutureOr<String>. Memorygetcosts about 0.6 µs instead of 0.86 µs. MemorygetRawcosts about 0.3 µs. - New Redis option
pool_size: the most connections one store opens (ioredismaxConnection). Default is 10, the same as before. - Uses
ioredis2.0.0-alpha.2. It sends all commands on one shared connection and writes them together (auto-pipelining). A Redis read costs much less CPU. The cache now uses one connection per store, sopool_sizerarely matters.
3.0.0-alpha.2 #
- Needs Dart 3.13 or newer.
- All dependencies updated to their latest versions.
3.0.0-alpha.1 #
- Uses
ioredis2. Redis error replies throwRedisError. - Redis: no value size limit by default (was 60 KB).
maxValueBytesis still there if you want one. - Redis:
manyuses oneMGET,putManyuses one pipeline,flushusesSCAN+DEL(no Lua). - First release.
CacheManagerwith named stores and custom drivers.- Drivers: memory (with LRU), file, Redis, null.
remember,pull,add,increment,many, tags and atomic locks.