What if I want to use different repos for different models? Some of my models can be persisted in postgres, while some retrieved via api, some stored in redis, yet others stored in dynamodb. As the app grows, I want to be able to change between persistance strategies on model basis in order to optimise performance, or extract some portions of it as external services.
Repo solution, as you have put it, is designed as a service which uses single shared implementation (strategy) for all the models. Am I missing a way to make this per-model based?
What if I want to use different repos for different models? Some of my models can be persisted in postgres, while some retrieved via api, some stored in redis, yet others stored in dynamodb. As the app grows, I want to be able to change between persistance strategies on model basis in order to optimise performance, or extract some portions of it as external services.
Repo solution, as you have put it, is designed as a service which uses single shared implementation (strategy) for all the models. Am I missing a way to make this per-model based?