Skip to content

Add a runtime prefix to default cache key #163

Description

@jojurajan

I am using ring.redis==0.7.3 for caching function returns and I need to prefix the cache key based on the environment that code is being deployed.

Currently it is not possible to set the key_refactor method during runtime because of the way compose_key method has been implemented. https://github.com/youknowone/ring/blob/0.7.3/ring/func/base.py#L648

Is there a way to specify the key_refactor method during runtime without re-implementing create_key_builder locally?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions