Posted By: John Mettraux
Date: 2008-07-18 00:23
Summary: rufus-scheduler 1.0.8 released
Project: rufus

just released the "rufus-scheduler" 1.0.8 [gem].

It fixes a few bugs, mainly making jobs visible via get_job(job_id) even when they are right in the middle of execution.

It also introduces 4 new shorter aliases : "at", "in", "every" and "cron" (to "schedule_at", "schedule_in", "schedule_every" and "schedule" respectively) :

---8<---
require 'rubygems'
require 'rufus/scheduler'

scheduler = Rufus::Scheduler.start_new

scheduler.in("3d") do
regenerate_monthly_report()
end
#
# will call the regenerate_monthly_report method
# in 3 days from now

scheduler.every "10m10s" do
check_score(favourite_team) # every 10 minutes and 10 seconds
end

scheduler.cron "0 22 * * 1-5" do
log.info "activating security system..."
activate_security_system()
end

job_id = scheduler.at "Sun Oct 07 14:24:01 +0900 2009" do
init_self_destruction_sequence()
end
--->8---


Changelog :

- todo #21251 : added 'at', 'cron', 'in' and 'every' shortcut methods
- todo #21203 : keeping track of At and EveryJob until last trigger is over
- todo #20823 : now raising exception in case of bad 'at' parameter
- todo #21194 : added trigger_thread to Job class
- todo #21193 : spinned CronLine out to rufus/cronline.rb
- bug #20893 : sometimes unschedule(every_job) not working when job was
active (performing). Fixed.


Links :

http://github.com/jmettraux/rufus-scheduler
http://rubyforge.org/projects/rufus/
http://rufus.rubyforge.org/rufus-scheduler/files/README_txt.html
http://groups.google.com/group/rufus-ruby


Thanks to Sean Liu for his help.

Latest News
TZInfo v1.0.0 and TZInfo::Data v1.2013.3 Released
    Philip Ross - 2013-06-02 17:12
icalendar 1.4.0 Released
    Ryan Ahearn - 2013-05-21 23:17
BinData 1.5.0 - source moved to github
    Dion Mendel - 2013-05-21 11:10
v13.5.0 Released !!
    id 774 - 2013-05-18 12:28
Runt v0.9.0 Released
    Matthew Lipper - 2013-05-17 00:11

 

Forums | Admin

Discussion Forums: rufus-scheduler-1.0.8-released-

Start New Thread Start New Thread

 

Topic Topic Starter Replies Last Post