> Hello, > > i need to handle cron jobs dynamically which means adding cron jobs but > also removing them. Since the uwsgi python plugin api does not expose a > way to remove them the suggested solution would be to just add a timer > every minute or so and check the cron jobs from within the app?
Yes, this is the right approach (and it is effectively how cron works). Basically you choose a base frequency (like 60 seconds in the cron world) and every time the frequency elapses you need to check what you need to run. Reliability between timers and crons is the same (they are based on uwsgi signals), so a 60 seconds timers will give nothing more than a cron with '1' resolution Another > option is calling uwsgi.reload() everytime a job change and add all the > cron jobs i need but i don't like that much. > this is really ugly :) -- Roberto De Ioris http://unbit.it _______________________________________________ uWSGI mailing list [email protected] http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
