Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Avoid checking if all workers reached timeout unless idle timeout is …
…configured (puma#3341) Puma::Cluster#run constantly checks if all workers have reached their idle timeout even when the feature isn't being used. This change ensures that this check only runs when idle_timeout is configured. Also includes a micro-optimisation which ensures the idle workers state hash isn't unnecessarily initialised until actually required (either a worker indicates timeout reached via pipe or Puma::Cluster#run checks if all_workers_idle_timed_out?). All of these changes are covered by existing tests.
- Loading branch information