I have an app with direct customers are business owners. I want to design a system that allows admin to be able to turn on/off features for a business owner. Business owner can also turn on/off by paying for the feature. My questions are: 1. Which storage system should I use to store the feature flags? 2. It’s a low write, high read traffic, so how do I optimize for read? Data should look as below. Currently I’m using aws services for my app. I’m thinking to use AWS AppConfig as storage as it allows caching on the consumer side (aws lambda). Using database + caches seems like an overkill to me. I’m sure this issue already has the best solution for it such as Yelp, or any app that you can pay more for more features. How should I go about it? Where can I find help on such system design issue? Any help would be appreciated. #yelp #tech #systemdesign
strong overlap with rate limiter system design but simpler.
Something like ZooKeeper along with in process cache? If you have only 1000 business owners, even without any partitioning, you need a 1000 bit in process storage, so its cheap and fast.
Most DBs are optimized for read traffic, writes are expensive. If you’re going aws then just use Dynamo tbh. Otherwise would need more context, like how consistent does your system need to be? What latency is acceptable? What scale do you mean by “high read”? Are you eventually gonna add features/columns? If so Dynamo if not just a relational DB should be fine. Like if you’re just reading configs, can you cache client side and refresh every day/hour? Cuz then you can maybe fit into the free tier. Sounds like a super simple use case tbh…
Currently, I have around 1000 business owners and around 40k daily users. I have ~20 lambdas, and each lambda would need to know if the given feature is on for the given business owner feature before processing the request. Latency to get the feature flags should be <10ms for good ux.
More features will be added