Changes:
authorJos Boumans <kane@cpan.org>
Wed, 22 Nov 2006 15:40:50 +0000 (15:40 +0000)
committerJos Boumans <kane@cpan.org>
Wed, 22 Nov 2006 15:40:50 +0000 (15:40 +0000)
commitba2735b6164f953e9d590a8671aec8799e615327
tree8af2053228b86332283f12fcb5dcfdb24f2831ff
parent4aa6d1df60ed0badf3b74ec4ffc3ce45074c92be
Changes:
split out C::P::Scheduler to ::Base and ::Event
Implement all core functionality in ::Base
C::P::Scheduler provides convenience functions to ::Base
and the hooks into catalyst to do the scheduling
Pollute $c less
Introduce event objects
No longer hash based
->next_run and ->last_run are now accessors
running events goes via $event->run, called from the dispatch hook
Use $self->_config to retrieve config, rather than accessing $c directly
Add tests for schedule_state();
Add '@always' as a cron shorcut
made _event_state class data rather than instance data, so it is
accessible from the ::Event objects
made 'once every 60 seconds' check configurable using 'check_every'
XXX add to docs
made tests no longer need to hack the state file, but provide
$BASE->_last_check_time( 0 ) to reset the last checked time
Moved _event_state toe ::Event from ::Base, as it's the _event_ state
All tested & documented

TODO:
fix t/09long.t to use time::warp or somesuch
lib/Catalyst/Plugin/Scheduler.pm
lib/Catalyst/Plugin/Scheduler/Base.pm [new file with mode: 0755]
lib/Catalyst/Plugin/Scheduler/Event.pm [new file with mode: 0755]
t/04schedule.t
t/05auto_run.t
t/06trigger.t
t/07plugin.t
t/08yaml.t
t/10events.t [new file with mode: 0755]