X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=benchmarks%2Fversus-external-pools%2Fdynamic-piscina.js;h=d78dd568c2c28ae9a9f0fd04d79e4e9c1ecd774e;hb=85ff0ff051cf39e2a7ce2de2e644330364ed6065;hp=0881d1d051c9f69914c8ff300e69c30e843166a2;hpb=9f7e7a99ea7dfa6f2fb3c2e0e025b85cfdd4e22e;p=poolifier.git diff --git a/benchmarks/versus-external-pools/dynamic-piscina.js b/benchmarks/versus-external-pools/dynamic-piscina.js index 0881d1d0..d78dd568 100644 --- a/benchmarks/versus-external-pools/dynamic-piscina.js +++ b/benchmarks/versus-external-pools/dynamic-piscina.js @@ -1,8 +1,8 @@ // IMPORT LIBRARIES const Piscina = require('piscina') // FINISH IMPORT LIBRARIES -const size = process.env.POOL_SIZE -const iterations = process.env.NUM_ITERATIONS +const size = Number(process.env.POOL_SIZE) +const iterations = Number(process.env.NUM_ITERATIONS) const data = { test: 'MYBENCH', taskType: process.env['TASK_TYPE'] @@ -10,7 +10,7 @@ const data = { const piscina = new Piscina({ filename: './workers/piscina/function-to-bench-worker.js', - minThreads: Number(size), + minThreads: size, maxThreads: size * 3, idleTimeout: 1000 * 60 // this is the same as poolifier default })