Class: Fairy::Scheduler
- Inherits:
-
Object
- Object
- Fairy::Scheduler
- Defined in:
- lib/fairy/master/scheduler.rb
Instance Method Summary collapse
-
#initialize(controller) ⇒ Scheduler
constructor
A new instance of Scheduler.
- #schedule(atom) ⇒ Object
Constructor Details
#initialize(controller) ⇒ Scheduler
Returns a new instance of Scheduler.
9 10 11 12 13 |
# File 'lib/fairy/master/scheduler.rb', line 9 def initialize(controller) # 取りあえず @controller = controller #@processors = [Processor.new] end |
Instance Method Details
#schedule(atom) ⇒ Object
16 17 18 19 20 21 |
# File 'lib/fairy/master/scheduler.rb', line 16 def schedule(atom) # 取りあえず. # ここで, atomにはノード指定がすでにあるとしている. # 指定されたノードにスケジュールする. @processors[0].exec atom end |