On Fri, Jan 7, 2011 at 9:35 PM, Michael Gardner <gardne...@gmail.com> wrote:
> On Jan 7, 2011, at 11:13 AM, Trevor wrote:
>
>> 3. I could set a job-schedule using the OS to run a clojure script.
>> I'd rather not, I would like to do things like send emails / check
>> status via web app (making option 1 more appealing).
>
> Could you elaborate on why a scheduled job to run a Clojure script would be 
> inappropriate for those kinds of tasks? Anything you can do from a daemon, 
> you should be able to do from a cron job.

Let's see. On the one hand, running a job scheduler from inside
Clojure results in cranking up a big, slow to start up, expensive JVM
process once a session, on startup, which then runs some tasks
periodically, and the scheduling itself can be done in a nice language
like, say, Clojure, with nice error reporting.

On the other hand, running a job scheduler from outside Clojure
results in cranking up a big, slow to start up, expensive JVM process
every single time a task needs to run, each of which runs one task
once, and the scheduling itself must be done in an icky language like
shell or cron's idiosyncratic "crontab" files with icky error
reporting (e.g., need to run a local mail *server* to receive error
notifications).

I think I can see why someone might prefer to have the scheduling done
inside the JVM. :)

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to