So let's say I am building an node.js/angularjs/mongodb app for managing invoices; as you know each invoice has a maturity date, once it reaches to maturity the status of invoice needs to changed to 'matured'. Note that there will be a lot of invoices in the mongo db, in the thousands.Currently I am doing this by using a Cron package called ontime: https://ift.tt/2KEUGhB ; which I set it to 12 AM midnight to run once and checks the maturity dates of all non-matured invoices if they match with today's date; but I am not much comfortable with it because 1) something wrong may happen and invoice won't change status in the right time. 2) it relies on this dependencyIs there a better (as more performant) and secure way to do this? Any ideas?
Submitted July 03, 2018 at 08:54AM by muffinman82
No comments:
Post a Comment