Skip to content

Compression for cached values #205

Description

@mkhorton

Is it possible to compress values before storing them in the cache (and decompressing them on retrieval)? If not, would there be an appropriate place to add a hook for this?

I'm trying Flask-Caching with a redis deployment, and it looks like a significant amount of memory could be saved by compressing the cached values, and uncompressing them when retrieved from the cache.

Performing the compression in the body of the function is not appropriate, since other parts of the web app would require un-compressed values to be returned by the relevant functions.

Thanks for a great library!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions