Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

Commit

Permalink
Merge pull request #23 from inket/patch-1
Browse files Browse the repository at this point in the history
Default WORKER_COUNT to 1 when cpu count is 1
  • Loading branch information
goatslacker authored Jun 30, 2016
2 parents edf1d2f + 08036e9 commit e23fb41
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/coordinator.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import os from 'os';
import logger from './utils/logger';
import { raceTo } from './utils/lifecycle';

const WORKER_COUNT = os.cpus().length - 1;
const WORKER_COUNT = os.cpus().length - 1 || 1;

function close() {
return Promise.all(Object.values(cluster.workers).map((worker) => {
Expand Down

0 comments on commit e23fb41

Please sign in to comment.