I'm trying to build a NodeJS web service to send out emails at specific times, but in the most efficient way possible.
Google Keep reminder feature is similar to what I want to do. You can schedule a time to be reminded about something. But how does it work?
The only solution I can come up with about how this work is a cron job that runs every min and sends out the notification to all users for reminders scheduled at that time.
But Google must have a database of all of these tasks, and millions of them. Isn't it inefficient to run a task querying through millions of data every min?
So, I'm not convinced that this is how Google Keep reminders work, but cron is the only method I know of.