repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
chore: v2.4.0
[poolifier.git]
/
benchmarks
/
versus-external-pools
/
fixed-piscina.js
diff --git
a/benchmarks/versus-external-pools/fixed-piscina.js
b/benchmarks/versus-external-pools/fixed-piscina.js
index 861fe4f6b99662ca93d2a944d898f58c64f41b7a..8a92dbea5b6a7709f8b2df90b77f7a8ce170d394 100644
(file)
--- a/
benchmarks/versus-external-pools/fixed-piscina.js
+++ b/
benchmarks/versus-external-pools/fixed-piscina.js
@@
-1,11
+1,12
@@
// IMPORT LIBRARIES
const Piscina = require('piscina')
// FINISH IMPORT LIBRARIES
// IMPORT LIBRARIES
const Piscina = require('piscina')
// FINISH IMPORT LIBRARIES
-const size =
Number
(process.env.POOL_SIZE)
-const iterations =
Number
(process.env.NUM_ITERATIONS)
+const size =
parseInt
(process.env.POOL_SIZE)
+const iterations =
parseInt
(process.env.NUM_ITERATIONS)
const data = {
test: 'MYBENCH',
const data = {
test: 'MYBENCH',
- taskType: process.env['TASK_TYPE']
+ taskType: process.env.TASK_TYPE,
+ taskSize: parseInt(process.env.TASK_SIZE)
}
const piscina = new Piscina({
}
const piscina = new Piscina({
@@
-20,6
+21,7
@@
async function run () {
promises.push(piscina.run(data))
}
await Promise.all(promises)
promises.push(piscina.run(data))
}
await Promise.all(promises)
+ // eslint-disable-next-line n/no-process-exit
process.exit()
}
process.exit()
}