Skip to content

Releases: Hawk-API/hawkapi-cache

v0.2.0 — security hardening

16 May 14:11

Choose a tag to compare

Full OWASP review fixes. See CHANGELOG.md for details.

v0.1.0

16 May 08:14

Choose a tag to compare

Initial release.

  • init_cache(app, *, backend=...) — registers CachePlugin, mounts on app.state.cache.
  • @cache(ttl=..., tags=..., vary=..., key_func=..., condition=...) decorator.
  • MemoryCacheBackend(max_size=10_000) — LRU + TTL, default.
  • RedisCacheBackend.from_url(...) — multi-process via hawkapi-cache[redis] extra.
  • Tag-based invalidation: app.state.cache.invalidate_tags([...]).
  • X-Cache: HIT / MISS response header.
  • Only GET / HEAD + 2xx responses are cached.
  • 35 tests, ruff + pyright strict clean.
  • Python 3.12 / 3.13, hawkapi>=0.1.7.