Added scheduler job to cleanup expired sessions issue#98.
This commit is contained in:
parent
ce60f5b71d
commit
cf76971666
1 changed files with 15 additions and 0 deletions
15
db/migrate/20131208000001_update_scheduler3.rb
Normal file
15
db/migrate/20131208000001_update_scheduler3.rb
Normal file
|
@ -0,0 +1,15 @@
|
|||
class UpdateScheduler3 < ActiveRecord::Migration
|
||||
def up
|
||||
Scheduler.create_or_update(
|
||||
:name => 'Cleanup expired sessions',
|
||||
:method => 'SessionHelper.cleanup_expired',
|
||||
:period => 60 * 60 * 24,
|
||||
:prio => 2,
|
||||
:active => true,
|
||||
:updated_by_id => 1,
|
||||
:created_by_id => 1,
|
||||
)
|
||||
end
|
||||
def down
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue