Open EdNutting opened 3 years ago
Can probably use a select-upsert to make sure we only setTimeout exactly once per event start/end. Maybe we should pick up the next two minutes worth of events every minute to give some leeway?
Possibly this has been implement as part of the playout service changes? @rossng
We still rely on scheduled triggers, and I've concluded that we need a proper system for precise/reliable event scheduling. Hasura isn't appropriate for this.
At the moment we insert scheduled triggers for the start/end time of an event whenever the event times are edited. This can lead to lots of weird duplication scenarios that can cause bugs in livestreams. Instead, we should just run a cron job every minute that looks for upcoming events starting and ending. Need to come up with a clever way of making sure that events get picked up exactly once.