External:
Users Table (SQL)
Activity Table (NoSQL)
Goal Table (NoSQL)
First the user would send a request to our serverside
This request will go through a load balancer to prevent overwhelming any single server
/info endpoint will grab the users progress for all activities
/setGoals endpoint will update the user's goals, either add new goal or update the progress of an existing goal
We'd probably want a cache to keep track of the activities the user has done, the user may go to check the recent activities they've multiple times
The reason for the app is because the user doesnt remember every activity so it's likely the user is using the app to see what they did
Let's say for every write theres 2 reads -> Read heavy
Because we're it may be a good idea to -> Async replicas
Shard database to handle concurrent writes to database
-> shard by region -> shard the shard if we need to
Client -> Load Balancer -> server
Explain any trade offs you have made and why you made certain tech choices...
Bottle necks may be if too many users try to update at the same time, but that is why we chose to shard the DB
Possibly new feature requests depending on what the client is looking for when using the app