python - flask cache: list keys based on a pattern? -


i'm using flask cache plugin redis backend cache api response. have apis users , create user this:

/api/users?page=1  /api/users         post 

the result cached full url key. when new user created, i'd delete keys start /api/users - i'm doing cache.clear() hardly seems necessary.

however, can't seem find api list of keys. redis-py, there keys(*pattern) api purpose. there similar api flask cache?

flask cache plugin not provide access point raw redis commands. can use redis-py connect same redis instance , database delete keys pattern.


Comments

Popular posts from this blog

Ansible - ERROR! the field 'hosts' is required but was not set -

customize file_field button ruby on rails -

SoapUI on windows 10 - high DPI/4K scaling issue -