Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CacheBackend: Use a configurable setting to specify cache key #336

Merged
merged 1 commit into from
Feb 26, 2023

Conversation

Flauschbaellchen
Copy link
Contributor

Using a static class variable allows applications using django-health-check as a 3rd-party package to read the key's identifier used to read/write the cache entry.

This is in particular useful, if the application needs to know which keys are written from other packages and are not part of the application logic itself.

The internal cache key used to write to and read from the cache backend could
conflict with the main application.
By introducing a Django setting it allows the developer to specify one
different from the default value.
@Flauschbaellchen Flauschbaellchen changed the title CacheBackend: Use static class variable to define cache key CacheBackend: Make key's name configurable Dec 8, 2022
@Flauschbaellchen Flauschbaellchen changed the title CacheBackend: Make key's name configurable CacheBackend: Use a configurable setting to specify cache key Dec 8, 2022
Copy link
Contributor

@skarzi skarzi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice work 👍

README.md Show resolved Hide resolved
docs/settings.rst Show resolved Hide resolved
@Flauschbaellchen
Copy link
Contributor Author

@skarzi Any news on this? I've resolved the threads as no more work needs to be done.

@skarzi
Copy link
Contributor

skarzi commented Feb 14, 2023

@Flauschbaellchen I am not a maintainer of this package, just a contributor. I think this PR could be merged (and thank you - I am running your changes from this PR on prod in some of my projects for ~1 month 👍).

@frankwiles can you take a look at this PR?

Copy link
Member

@frankwiles frankwiles left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great. Thanks!

@frankwiles frankwiles merged commit 58f7a6a into revsys:master Feb 26, 2023
@Flauschbaellchen Flauschbaellchen deleted the cache-backend-health-key branch February 27, 2023 14:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants