I have an application which is starting to add up quite a lot in terms of having to add cron jobs to monitor certain things.
An example is that when a certain data is inserted into the database, a cron job looks at this data, then looks at a setting in another table to know if it should send a notice to an email address configured.
Now, we need to add another similar function where if a critical piece of data comes into the db and if there is a 1 in another table column, that again, an email should be sent. The problem is that this test needs to be done every single time data is inserted which means I would have to run this cron task every second of the day, 24/7.
That seems unbelievably stupid to me so I wanted to ask here because I think those telling me it's the only way to do this are perhaps not aware of some things.