mirror of
https://github.com/plashchynski/crono.git
synced 2026-07-05 20:41:38 +02:00
Refactoring
This commit is contained in:
+1
-5
@@ -4,11 +4,7 @@ module Crono
|
|||||||
LOGFILE = "log/crono.log"
|
LOGFILE = "log/crono.log"
|
||||||
PIDFILE = "tmp/pids/crono.pid"
|
PIDFILE = "tmp/pids/crono.pid"
|
||||||
|
|
||||||
attr_accessor :cronotab
|
attr_accessor :cronotab, :logfile, :pidfile, :daemonize, :environment
|
||||||
attr_accessor :logfile
|
|
||||||
attr_accessor :pidfile
|
|
||||||
attr_accessor :daemonize
|
|
||||||
attr_accessor :environment
|
|
||||||
|
|
||||||
def initialize
|
def initialize
|
||||||
self.cronotab = CRONOTAB
|
self.cronotab = CRONOTAB
|
||||||
|
|||||||
+1
-6
@@ -5,12 +5,7 @@ module Crono
|
|||||||
class Job
|
class Job
|
||||||
include Logging
|
include Logging
|
||||||
|
|
||||||
attr_accessor :performer
|
attr_accessor :performer, :period, :last_performed_at, :job_log, :job_logger, :healthy
|
||||||
attr_accessor :period
|
|
||||||
attr_accessor :last_performed_at
|
|
||||||
attr_accessor :job_log
|
|
||||||
attr_accessor :job_logger
|
|
||||||
attr_accessor :healthy
|
|
||||||
|
|
||||||
def initialize(performer, period)
|
def initialize(performer, period)
|
||||||
self.performer, self.period = performer, period
|
self.performer, self.period = performer, period
|
||||||
|
|||||||
Reference in New Issue
Block a user