const pool = new DynamicPool(size)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(
+ promises.add(
pool.exec({
task: functionToBench,
param: data,
})
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(piscina.run(data))
+ promises.add(piscina.run(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(dynamicPool.execute(data))
+ promises.add(dynamicPool.execute(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
})
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(tinypool.run(data))
+ promises.add(tinypool.run(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(workerNodes.call.functionToBench(data))
+ promises.add(workerNodes.call.functionToBench(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(workerPool.exec('functionToBench', dataArray))
+ promises.add(workerPool.exec('functionToBench', dataArray))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
})
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(piscina.run(data))
+ promises.add(piscina.run(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(fixedPool.execute(data))
+ promises.add(fixedPool.execute(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
})
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(tinypool.run(data))
+ promises.add(tinypool.run(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(workerNodes.call.functionToBench(data))
+ promises.add(workerNodes.call.functionToBench(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
)
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(workerPool.exec('functionToBench', dataArray))
+ promises.add(workerPool.exec('functionToBench', dataArray))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
})
async function run () {
- const promises = []
+ const promises = new Set()
for (let i = 0; i < iterations; i++) {
- promises.push(pool.exec(data))
+ promises.add(pool.exec(data))
}
await Promise.all(promises)
// eslint-disable-next-line n/no-process-exit
"mochawesome": "^7.1.3",
"prettier": "^2.8.8",
"release-it": "^15.11.0",
- "rollup": "^3.26.0",
+ "rollup": "^3.26.1",
"rollup-plugin-analyzer": "^4.0.0",
"rollup-plugin-command": "^1.1.3",
"rollup-plugin-delete": "^2.0.0",
version: 3.1.0(release-it@15.11.0)
'@rollup/plugin-terser':
specifier: ^0.4.3
- version: 0.4.3(rollup@3.26.0)
+ version: 0.4.3(rollup@3.26.1)
'@rollup/plugin-typescript':
specifier: ^11.1.2
- version: 11.1.2(rollup@3.26.0)(typescript@5.1.6)
+ version: 11.1.2(rollup@3.26.1)(typescript@5.1.6)
'@types/node':
specifier: ^20.3.3
version: 20.3.3
specifier: ^15.11.0
version: 15.11.0
rollup:
- specifier: ^3.26.0
- version: 3.26.0
+ specifier: ^3.26.1
+ version: 3.26.1
rollup-plugin-analyzer:
specifier: ^4.0.0
version: 4.0.0
string-template: 1.0.0
dev: true
- /@rollup/plugin-terser@0.4.3(rollup@3.26.0):
+ /@rollup/plugin-terser@0.4.3(rollup@3.26.1):
resolution: {integrity: sha512-EF0oejTMtkyhrkwCdg0HJ0IpkcaVg1MMSf2olHb2Jp+1mnLM04OhjpJWGma4HobiDTF0WCyViWuvadyE9ch2XA==}
engines: {node: '>=14.0.0'}
peerDependencies:
rollup:
optional: true
dependencies:
- rollup: 3.26.0
+ rollup: 3.26.1
serialize-javascript: 6.0.1
smob: 1.4.0
terser: 5.18.2
dev: true
- /@rollup/plugin-typescript@11.1.2(rollup@3.26.0)(typescript@5.1.6):
+ /@rollup/plugin-typescript@11.1.2(rollup@3.26.1)(typescript@5.1.6):
resolution: {integrity: sha512-0ghSOCMcA7fl1JM+0gYRf+Q/HWyg+zg7/gDSc+fRLmlJWcW5K1I+CLRzaRhXf4Y3DRyPnnDo4M2ktw+a6JcDEg==}
engines: {node: '>=14.0.0'}
peerDependencies:
tslib:
optional: true
dependencies:
- '@rollup/pluginutils': 5.0.2(rollup@3.26.0)
+ '@rollup/pluginutils': 5.0.2(rollup@3.26.1)
resolve: 1.22.2
- rollup: 3.26.0
+ rollup: 3.26.1
typescript: 5.1.6
dev: true
- /@rollup/pluginutils@5.0.2(rollup@3.26.0):
+ /@rollup/pluginutils@5.0.2(rollup@3.26.1):
resolution: {integrity: sha512-pTd9rIsP92h+B6wWwFbW8RkZv4hiR/xKsqre4SIuAOaOEQRxi0lqLke9k2/7WegC85GgUs9pjmOjCUi3In4vwA==}
engines: {node: '>=14.0.0'}
peerDependencies:
'@types/estree': 1.0.1
estree-walker: 2.0.2
picomatch: 2.3.1
- rollup: 3.26.0
+ rollup: 3.26.1
dev: true
/@sinclair/typebox@0.27.8:
through: 2.3.8
dev: true
- /acorn-jsx@5.3.2(acorn@8.9.0):
+ /acorn-jsx@5.3.2(acorn@8.10.0):
resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}
peerDependencies:
acorn: ^6.0.0 || ^7.0.0 || ^8.0.0
dependencies:
- acorn: 8.9.0
+ acorn: 8.10.0
dev: true
/acorn-walk@8.2.0:
engines: {node: '>=0.4.0'}
dev: true
- /acorn@8.9.0:
- resolution: {integrity: sha512-jaVNAFBHNLXspO543WnNNPZFRtavh3skAkITqD0/2aeMkKZTN+254PyhwxFYrk3vQ1xfY+2wbesJMs/JC8/PwQ==}
+ /acorn@8.10.0:
+ resolution: {integrity: sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==}
engines: {node: '>=0.4.0'}
hasBin: true
dev: true
resolution: {integrity: sha512-1FH/IiruXZ84tpUlm0aCUEwMl2Ho5ilqVh0VvQXw+byAz/4SAciyHLlfmL5WYqsvD38oymdUwBss0LtK8m4s/A==}
engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}
dependencies:
- acorn: 8.9.0
- acorn-jsx: 5.3.2(acorn@8.9.0)
+ acorn: 8.10.0
+ acorn-jsx: 5.3.2(acorn@8.10.0)
eslint-visitor-keys: 3.4.1
dev: true
del: 5.1.0
dev: true
- /rollup@3.26.0:
- resolution: {integrity: sha512-YzJH0eunH2hr3knvF3i6IkLO/jTjAEwU4HoMUbQl4//Tnl3ou0e7P5SjxdDr8HQJdeUJShlbEHXrrnEHy1l7Yg==}
+ /rollup@3.26.1:
+ resolution: {integrity: sha512-I5gJCSpSMr3U9wv4D5YA8g7w7cj3eaSDeo7t+JcaFQOmoOUBgu4K9iMp8k3EZnwbJrjQxUMSKxMyB8qEQzzaSg==}
engines: {node: '>=14.18.0', npm: '>=8.0.0'}
hasBin: true
optionalDependencies:
hasBin: true
dependencies:
'@jridgewell/source-map': 0.3.5
- acorn: 8.9.0
+ acorn: 8.10.0
commander: 2.20.3
source-map-support: 0.5.21
dev: true
'@tsconfig/node14': 1.0.3
'@tsconfig/node16': 1.0.4
'@types/node': 20.3.3
- acorn: 8.9.0
+ acorn: 8.10.0
acorn-walk: 8.2.0
arg: 4.1.3
create-require: 1.1.1
engines: {node: '>=6.0'}
hasBin: true
dependencies:
- acorn: 8.9.0
+ acorn: 8.10.0
acorn-walk: 8.2.0
dev: true