Python scheduler

R

Rita

Hello,


Here is what I am trying to do. (Currently, I am doing this in cron but i
need much more granularity). I am trying to run program every 20 secs and
loop forever. I have several of these types of processes, some should run
every 5 mins, 10 secs, 20 secs, 1 min and so forth. I was wondering what is
the best way to do this?


Also, would Greenlet do something I am asking for?
 
R

rusi

Hello,

Here is what I am trying to do. (Currently, I am doing this in cron but i
need much more granularity). I am trying to run program every 20 secs and
loop forever. I have several of these types of processes, some should run
every 5 mins, 10 secs, 20 secs, 1 min and so forth. I was wondering what is
the best way to do this?

Erlang, which is geared for such stuff, has its own internal cron
https://github.com/erlware/erlcron with 2 sec granularity.
Not an ideal solution I guess. Anyway since you are using cron (ie
not within the python ecosystem) I am pointing this out. Then you
could use the erlang equivalent of python's os.system. In erlang its
os:cmd http://www.erlang.org/doc/man/os.html
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,567
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top