mirror of
https://github.com/paricafe/misskey.git
synced 2024-11-25 15:26:43 -06:00
Fix bug
This commit is contained in:
parent
79ffbf95db
commit
7c259185bc
1 changed files with 1 additions and 1 deletions
|
@ -224,7 +224,7 @@ async function getMongoDBVersion(db: Db): Promise<string> {
|
||||||
return (await db.admin().serverInfo()).version;
|
return (await db.admin().serverInfo()).version;
|
||||||
}
|
}
|
||||||
|
|
||||||
async function spawnWorkers(limit: number) {
|
async function spawnWorkers(limit: number = Infinity) {
|
||||||
const workers = Math.min(limit, os.cpus().length);
|
const workers = Math.min(limit, os.cpus().length);
|
||||||
Logger.info(`Starting ${workers} worker${workers === 1 ? '' : 's'}...`);
|
Logger.info(`Starting ${workers} worker${workers === 1 ? '' : 's'}...`);
|
||||||
await Promise.all([...Array(workers)].map(spawnWorker));
|
await Promise.all([...Array(workers)].map(spawnWorker));
|
||||||
|
|
Loading…
Reference in a new issue