I'm working on an existing custom eCommerce PHP application which is currently running a very resource intensive CRON every 15 minutes.
The gist of it is: Customers can set up complex filters for products they are interested in, and receive emails based on these filters. The CRON which runs every 15 minutes, checks for all new products that have been listed since it last ran, and compares them with each customers filters. If the products match a customers filters they are send an email via amazon SES.
Up until now, this method has been working ok, but as the number of active customers is rising very quickly the CRON is starting to make a noticable performance drop on the application every 15 minutes which lasts for a minute or two while it runs.
I have been toying with other ideas to help spread out the load on the server, such as performing the task each time a product is listed, so the server doesn't need to catch up on multiple products at a time.
What is usually the best practise when approaching something like this?