lib/temporal/worker.rb
# activity_thread_pool_size: number of threads that the poller can use to run activities.
#   can be set to 1 if you want no paralellism in your activities, at the cost of throughput.
number of threads that the poller can use to run activities.
can be set to 1 if you want no paralellism in your activities, at the cost of throughput.
number of threads that the poller can use to run activities . can be set to 1 if you want no paralellism in your activities at the cost of throughput .
def stop
      @shutting_down = true
      Thread.new do
        pollers.each(&:stop_polling)
        sleep 1
        pollers.each(&:cancel_pending_requests)
        pollers.each(&:wait)
      end.join
    end
def stop @shutting_down = true Thread . new do pollers . each ( & :stop_polling ) sleep 1 pollers . each ( & :cancel_pending_requests ) pollers . each ( & :wait ) end . join end
activity_thread_pool_size: number of threads that the poller can use to run activities.
activity_thread_pool_size : number of threads that the poller can use to run activities .
# allow workers to drain in-transit tasks. # https://github.com/temporalio/temporal/issues/1058