Monday, 20 April 2020

Help with reminders

Hi, I'm sure this has been asked before but I cant seem to find anything that helps. In short, I am creating bot for an internal messaging system (like slack). My bot is a reminder bot, so a user can type in the keyword and say "remind me of 'x' in 10 minutes" or "remind me to do 'y' on April 30th at 9:00am" etc.In my head it made sense to just a have global time variable that is constantly updated, push all the reminders on a global queue where they are sorted by reminder time and then execute the bot to send a message when the global time equals the time of the first item in the queue.I am having a really hard time figuring out how to have a live updated global time variable. I have looked into cron jobs but I'm not sure how to have multiple cron jobs running at the same time.I have no idea if I'm thinking about it too much or not. Anyways if you can shed any light, offer any advice, or show any examples/tool that I can use I would be so thankful.

Submitted April 20, 2020 at 05:49PM by Number1NoTomatos

No comments:

Post a Comment