a-luna / fastapi-redis-cache

A simple and robust caching solution for FastAPI that interprets request header values and creates proper response header values (powered by Redis)
MIT License
154 stars 24 forks source link

Feature request - async Redis client #69

Open zoltan-fedor opened 2 years ago

zoltan-fedor commented 2 years ago

Hi, Thanks for the great library.

I was looking at the code and I saw that it supports caching async endpoints, but not yet support the use of a Redis async client.

redis-py (https://github.com/redis/redis-py/) now since v4.2.x supports async connection to Redis, so it should be possible to take advantage of that and add it as an option next to the current sync Redis client. I believe this would be a great addition and would make this library perfect.

Ps.: If you want, I could make a PR for it once I have the time.