Commit Graph

5 Commits

Author SHA1 Message Date
Naz
d0c45cbe9e
Increased adapter manager test coverage
refs https://github.com/TryGhost/Toolbox/issues/384

- Boyscouting while having the context loaded. Getting to those 100% coverages one day!
2022-09-06 17:51:57 +08:00
Naz
37dd187fe6
Added adapter caching based on features
refs https://github.com/TryGhost/Toolbox/issues/384

- Adapter cache was not able to store multiple object instances derived from same Base class. This created a need to create boilerplate "shell" classes inheriting from the Base class, e.g.: ImageSizeCacheSyncInMemory etc.
- Having feature-based adapter instance caching in the adapter manager allows to simplify configuration and reuse the "base class" instead of creating artificial "shell" classes.
- For example with this change both image sizes and settings caches will create separate cache instances deriving from default "Memory" class. Less code, less configuration!
2022-09-06 17:51:57 +08:00
Naz
0f86a05ed4
Added ":" syntax to adapter manager
refs https://github.com/TryGhost/Toolbox/issues/384

- The syntax using a colon ":" separator has been successfully used to enable multiple adapters. The adapter manager can benefit from same convention to enable more elastic adapter cache - have multiple instances of adapters from same base class
2022-09-06 17:51:57 +08:00
Daniel Lockyer
3978858b83 Remove trailing commas from .eslintrc.js files
- the upcoming eslint update flags errors for trailing commas, so this
  commits tidies that up
2020-08-04 14:48:07 +01:00
Fabien O'Carroll
44db45b7c3 Added @tryghost/adapter-manager module (#38)
no-issue
2020-04-05 15:54:47 +02:00