instance method
wait
Ruby on Rails edge
Since edge Private — implementation detail, not part of the public APISignature
wait(worker_id)
Waits for work, rechecking exhausted? inside the mutex to handle the race where close() broadcasts before we start waiting.
Parameters
-
worker_idreq
Source
# File activesupport/lib/active_support/testing/parallelization/test_distributor.rb, line 148
def wait(worker_id)
@mutex.synchronize do
@cv.wait(@mutex, WORK_WAIT_TIMEOUT) unless exhausted?(worker_id)
end
end
Defined in activesupport/lib/active_support/testing/parallelization/test_distributor.rb line 148
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveSupport::Testing::Parallelization::RoundRobinDistributor