2 const threadPool
= require('./pool-threadwork')
3 // FINISH IMPORT LIBRARIES
4 const iterations
= parseInt(process
.env
.NUM_ITERATIONS
)
7 taskType
: process
.env
.TASK_TYPE
,
8 taskSize
: parseInt(process
.env
.TASK_SIZE
)
11 async
function run () {
13 for (let i
= 0; i
< iterations
; i
++) {
14 promises
.push(threadPool
.run(data
))
16 await Promise
.all(promises
)
17 // eslint-disable-next-line n/no-process-exit