Class: Mutant::Parallel::Worker
- Inherits:
-
Object
- Object
- Mutant::Parallel::Worker
- Includes:
- Adamantium::Flat
- Defined in:
- lib/mutant/parallel/worker.rb
Overview
Parallel execution worker
Class Method Summary collapse
-
.run(attributes) ⇒ self
private
Run worker.
Instance Method Summary collapse
-
#run ⇒ self
private
Worker loop.
Class Method Details
.run(attributes) ⇒ self
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Run worker
14 15 16 17 |
# File 'lib/mutant/parallel/worker.rb', line 14 def self.run(attributes) new(attributes).run self end |
Instance Method Details
#run ⇒ self
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Worker loop
rubocop:disable Lint/Loop
28 29 30 31 32 |
# File 'lib/mutant/parallel/worker.rb', line 28 def run begin parent.call(Actor::Message.new(:ready, mailbox.sender)) end until handle(mailbox.receiver.call) end |