- `onlineHandler` (optional) - A function that will listen for online event on each worker
- `exitHandler` (optional) - A function that will listen for exit event on each worker
- `workerChoiceStrategy` (optional) - The work choice strategy to use in this pool:
+
- `WorkerChoiceStrategies.ROUND_ROBIN`: Submit tasks to worker in this pool in a round robbin fashion
- - `WorkerChoiceStrategies.LESS_RECENTLY_USED`: Submit tasks to the less recently used worker in the pool
-
+ - `WorkerChoiceStrategies.LESS_RECENTLY_USED`: Submit tasks to the less recently used worker in the pool
+
Default: `WorkerChoiceStrategies.ROUND_ROBIN`
+
- `enableEvents` (optional) - Events emission enablement in this pool. Default: true
### `pool = new DynamicThreadPool/DynamicClusterPool(min, max, filePath, opts)`
"del": "^5.1.0"
}
},
+ "rollup-plugin-istanbul": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/rollup-plugin-istanbul/-/rollup-plugin-istanbul-3.0.0.tgz",
+ "integrity": "sha512-z8kD2A57qTcxgqjbJ8cZBBE/IGYk+iJtE42sCaZjrSe/uBEUq5jJYvQwquJ+Acfko1LMYww4EJfeMJmc0GttpQ==",
+ "dev": true,
+ "requires": {
+ "@rollup/pluginutils": "^4.1.0",
+ "istanbul-lib-instrument": "^4.0.3"
+ }
+ },
"rollup-plugin-terser": {
"version": "7.0.2",
"resolved": "https://registry.npmjs.org/rollup-plugin-terser/-/rollup-plugin-terser-7.0.2.tgz",
"rollup-plugin-analyzer": "^4.0.0",
"rollup-plugin-command": "^1.1.3",
"rollup-plugin-delete": "^2.0.0",
+ "rollup-plugin-istanbul": "^3.0.0",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.30.0",
"sonar-scanner": "^3.1.0",
import { terser } from 'rollup-plugin-terser'
import del from 'rollup-plugin-delete'
import command from 'rollup-plugin-command'
+import istanbul from 'rollup-plugin-istanbul'
const isDevelopmentBuild = process.env.BUILD === 'development'
const isAnalyze = process.env.ANALYZE
? 'tsconfig.development.json'
: 'tsconfig.json'
}),
+ isDevelopmentBuild && istanbul(),
del({
targets: ['lib/*']
}),