Provide cache functions from unified namespace
- Dominant language
- Clojure
- Stars
- 66
- Forks
- 28
- Avg merge
- 7d 4h
- Merged PRs (30d)
- 2
Description
Currently we have a few in-memory cache implementations in different parts of back-end code. It might make sense to move the different implementations behind a new namespace, such as `rems.cache` and provide a documented API for them. Tests that utilize caches should also be checked that caches are cleared properly. See `rems.db.testing/caches-fixture` for more information.
DB caches using `rems.cache` (implemented in #3320):
- [ ] `rems.db.api-key/api-key-memo`
- [x] `rems.db.attachments` #3320
- [x] `rems.db.blacklist` #3320
- [x] `rems.db.catalogue` #3320
- [ ] `rems.db.category` (previous cache: #2764)
- [ ] `rems.db.entitlements`
- [x] `rems.db.form` #3320
- [ ] `rems.db.invitation`
- [x] `rems.db.licenses` #3320
- [x] `rems.db.organization` #3320
- [x] `rems.db.resource` #3320
- [x] `rems.db.roles` #3320
- [x] `rems.db.user-mappings` #3320
- [x] `rems.db.user-settings` #3320
- [x] `rems.db.users` #3320
- [x] `rems.db.workflow` #3320
Other caches:
- [ ] `rems.application.events-cache` (maybe not so easy to change)
- [ ] `rems.db.applications/all-applications-cache` (implements events cache)
- [ ] `rems.ext.mondo/code-by-id`
- [ ] `rems.ext.duo/code-by-id`
~`rems.api.services.dependencies/dependencies-cache`~ (removed cache)
Contributor guide
Assessment
This issue has not been assessed yet.