Python API

Python API#

Add-ons call collective.redismemoize.api and, in their tests, collective.redismemoize.testing. The other modules are documented for readers of the code; their names may change between releases.

collective.redismemoize.api

Public API: invalidation, status, and a decorator with its own TTL.

collective.redismemoize.testing

Test layers, and helpers to test an add-on against a fake Redis.

collective.redismemoize.config

Settings, read from the environment once per process.

collective.redismemoize.serializer

Strict serialization of plain data.

collective.redismemoize.client

The Redis connection: created lazily, per process, behind a circuit breaker.

collective.redismemoize.routing

Where each cached function's values live, and what happened to them.

collective.redismemoize.adapter

The cache adapter plone.memoize reads and writes through.

collective.redismemoize.chooser

The ICacheChooser utility this package registers.