FastAPI-Caching
Cache library for FastAPI with tag based invalidation. Asynchronous only for the time being.
Features
- Automatic response cache fetching using FastAPI dependencies
- Fine-grained control over when to return and set the cache
- Ability to invalidate cached objects based on a concept of associated tags. See examples/redis_app for an example.
Installation
With in-memory support only:
pip install fastapi-caching
NOTE: In-memory backend is only recommended when your app is only run as a single instance.
With redis support (through the aioredis library):
pip install fastapi-caching[redis]
Usage examples
Examples on how to use can be found here.
Limitations
- Only supported within async contexts.
Changelog
v0.1.2, 2020-08-16
- Feature: Support lazy setup of cache manager
v0.2.0, 2020-08-16
- Breaking change: Revert to requiring
backendto be passed to CacheManager - Feature: Support lazy configuration of the caching backend
v0.3.0, 2020-08-16
- Feature: Add functionality to disable (and re-enable) caching.
Metadata
Release files for fastapi-caching 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| fastapi-caching-0.3.0.tar.gz | 7.6 kB | Without provenance | Details for fastapi-caching-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| fastapi_caching-0.3.0-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for fastapi_caching-0.3.0-py2.py3-none-any.whl |
Total release size: 16.8 kB
Release files / fastapi-caching-0.3.0.tar.gz
| Download URL | fastapi-caching-0.3.0.tar.gz |
|---|---|
| Size | 7.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a7f2616e723826837081b5129d96e7d5f669070e8669f266729b840f05998523
|
|
BLAKE2b-256 checksum How to use checksums |
9406e4fe934d8f4c16b1821223390bbdb43b06533f71415ad3b72fce186a303e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6
|
Release files / fastapi_caching-0.3.0-py2.py3-none-any.whl
| Download URL | fastapi_caching-0.3.0-py2.py3-none-any.whl |
|---|---|
| Size | 9.3 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
023e0eb313c31f3e3242b2b262df635dfb6d90ecc49f30614207ff42b1be40fe
|
|
BLAKE2b-256 checksum How to use checksums |
b9ffa21410e334389135103b9f30be86cbb1eb5e5c80adfe85ef3ddadb128792
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6
|
Security for fastapi-caching 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.