Caching library with support for multiple cache backends
Project description
Cachetory
Documentation
Sneak peak
from cachetory import serializers
from cachetory.backends import async_ as async_backends
from cachetory.caches.async_ import Cache
cache = Cache[int, bytes](
serializer=serializers.from_url("pickle://?pickle-protocol=4"),
backend=async_backends.from_url("redis://localhost:6379"),
)
async def main() -> None:
await cache.set("foo", 42)
assert await cache.get("foo") == 42
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cachetory-3.1.1.tar.gz
(19.6 kB
view hashes)
Built Distribution
cachetory-3.1.1-py3-none-any.whl
(36.9 kB
view hashes)
Close
Hashes for cachetory-3.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | af0cc546f32560e4eb5bcddc8faae1d701a6349c12113c9d2d810dde78f97bcb |
|
MD5 | 32d9a728c59845498591d0ff6822dd8c |
|
BLAKE2b-256 | f00762c5b2a0b649fa4b88161c56e31c376fb7d8f040c47d202ce63772bbccc2 |