I wrote a basic quartz adapter for calling clojure functions by
submitting a job to call a clojure function by namespace/name or
submitting a closure.  My write-up is here:

  http://asymmetrical-view.com/2009/05/19/quartz-and-clojure.html

The example quartz code is in my github sandbox:

http://github.com/kyleburton/sandbox/tree/master

For me the advantage of using quartz and clojure is that it's in the
same JVM as other parts of the application - I don't need to create a
separate command line runner which can be invoked by cron.  I'm also
exploring creating a scheduling service using Quartz listening on an
AMQP message queue - where you can send it a message with the
scheduling details (one off or recurring) a return queue and an
embedded message body.  At the triggering time it sends the embedded
message back.  This is also more flexible than Cron - it's all handled
within the application and I can register and unregister the triggers.
 Cron would be more difficult to use for cases where I want to defer
some activity by sending it to the scheduler to be returned in say 10
minutes.

The scheduler service isn't in my sandbox yet, but I do plan on
publishing it when its complete and I have the time.

HTH,

Kyle

On Sat, Jun 27, 2009 at 2:55 AM, ataggart<alex.tagg...@gmail.com> wrote:
>
> What do you need that a cron job wouldn't provide?
>
> On Jun 26, 8:43 am, Stuart Halloway <stuart.hallo...@gmail.com> wrote:
>> I am working on a Clojure project that is becoming more and more
>> schedule-oriented. So far I have been using Clojure's native
>> concurrency constructs, but I am becoming tempted to use Java's
>> concurrency primitives to get interruptability, etc. -- or maybe even
>> wrap a Java library like Quartz.
>>
>> Has anyone else been down this road?
>>
>> Stu
> >
>



-- 
------------------------------------------------------------------------------
kyle.bur...@gmail.com                            http://asymmetrical-view.com/
------------------------------------------------------------------------------

--~--~---------~--~----~------------~-------~--~----~
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