3 All notable changes to this project will be documented in this file.
5 The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6 and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
8 ## [2.0.1] - 2021-16-03
12 - Check if pool options are properly set.
13 - `busy` event is emitted on all pool types.
15 ## [2.0.0] - 2021-01-03
19 - Now a thread/process by default is not deleted when the task submitted take more time than maxInactiveTime configured (issue #70).
23 - `FullPool` event is now renamed to `busy`.
24 - `maxInactiveTime` on `ThreadWorker` default behavior is now changed, if you want to keep the old behavior set `killBehavior` to `KillBehaviors.HARD`.
25 _Find more details on our JSDoc._
27 - `maxTasks` option on `FixedThreadPool` and `DynamicThreadPool` is now removed since is no more needed.
29 - We changed some internal structures, but you shouldn't be too affected by them as these are internal changes.
31 ### Pool options types declaration merge
33 `FixedThreadPoolOptions` and `DynamicThreadPoolOptions` type declarations have been merged to `PoolOptions<Worker>`.
35 #### New `export` strategy
39 const DynamicThreadPool = require('poolifier/lib/dynamic')
41 const { DynamicThreadPool } = require('poolifier/lib/dynamic')
44 But you should always prefer just using
47 const { DynamicThreadPool } = require('poolifier')
50 #### New type definitions for input data and response
52 For cluster worker and worker-thread pools, you can now only send and receive serializable data.
53 _This is not a limitation by poolifier but NodeJS._
55 #### Public property replacements
57 `numWorkers` property is now `numberOfWorkers`
59 #### Internal (protected) properties and methods renaming
61 These properties are not intended for end users
63 - `id` => `nextMessageId`
65 These methods are not intended for end users
67 - `_chooseWorker` => `chooseWorker`
68 - `_newWorker` => `createWorker`
69 - `_execute` => `internalExecute`
70 - `_chooseWorker` => `chooseWorker`
71 - `_checkAlive` => `checkAlive`
73 - `_runAsync` => `runAsync`
75 ## [1.1.0] - 2020-21-05
79 - ThreadWorker support async functions as option
80 - Various external library patches
82 ## [1.0.0] - 2020-24-01
86 - FixedThreadPool implementation
87 - DynamicThreadPool implementation
88 - WorkerThread implementation to improve developer experience