Skip to content

Latest commit

 

History

History
918 lines (554 loc) · 27.9 KB

CHANGELOG.md

File metadata and controls

918 lines (554 loc) · 27.9 KB

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

0.4.31 (2024-10-26)

⚡ Performance

  • use micro tasks in tasks handling code paths (8abd0c2)

🧪 Tests

  • refine worker error handling expectation (dbc6f71)

0.4.30 (2024-10-24)

🐞 Bug Fixes

  • ensure error on the worker side is propagated unchanged to main (22804e0)

⚡ Performance

  • speed up isAsyncFunction() helper (8d451ae)

✨ Polish

🤖 Automation

  • ci: fix deno.json formatting (83a3f4c)
  • ci: handle various release type on npm registry (9ab41fe)

0.4.29 (2024-10-14)

⚡ Performance

  • pre-create worker if needed at the end of task execution (cd7406c)

📚 Documentation

  • README.md: revert reformatting (5561f4e)

🤖 Automation

  • deps: Bump github/combine-prs from 5.1.0 to 5.2.0 (3412820)

0.4.28 (2024-10-09)

🚀 Features

  • add deno 2.x.x support (47dfca2)
  • benchmarks: add bencher threshold checks (a0010ee)

🐞 Bug Fixes

  • benchmarks: add upper/lower values to BMF throughput (d5ccee0)
  • benchmarks: fix BMF report upper/lower values (c352783)
  • fix benchmarks report conversion to BMF format (9d39cfe)

✨ Polish

  • benchmarks: cleanup JS runtime detection code (8bd7fa6)
  • cleanup multiple JS runtime support implementation (ca64e63)
  • cleanup task function ops validation (766352d)

🤖 Automation

  • ci: add deno 2.x.x RC (a4c218d)
  • ci: revert deno 2.x.x integration (d0bf8a9)
  • ci: switch to deno v2.x.x (17e3705)
  • deps: Bump sonarsource/sonarcloud-github-action (#68) (29df0a7)

0.4.27 (2024-09-08)

⚡ Performance

  • track dynamic pool empty event lifecycle (1c82a75)

✨ Polish

  • add dynamic worker nodes count to pool info (27f1bca)

🧪 Tests

  • refine dynamic pool shutdown test expectations (4562a61)

🤖 Automation

  • sonar: refine sonar-project.properties (e43d3d8)
  • sonar: refine sonar-project.properties (893e2a0)

0.4.26 (2024-09-06)

⚡ Performance

  • optimize backpressure task(s) stealing conditions (75ddbb8)

✨ Polish

  • add isWorkerNodeStealing() helper (508b201)
  • factor out stealing ratio conditions check into an helper (17369b6)

🧪 Tests

  • cleanup error handling expectations (ecf101e)

0.4.25 (2024-08-30)

🐞 Bug Fixes

  • handle properly small or zero tasksStealingRatio (ab6e570)

✨ Polish

  • move dynamic pool only getters to its own class (74970f2)

🧪 Tests

  • fix variable casing (a2727d7)
  • refine pool event tests expectation (5bdf99a)

📚 Documentation

  • cleanup code examples (28b119c)
  • refine pool ready event emission condition (e7d0673)
  • switch examples to top level await usage (ESM) (30781c3)

0.4.24 (2024-08-28)

⚡ Performance

  • reduce useless branching at pool info building (1184246)
  • track dynamic pool full lifecycle via events (5415178)

✨ Polish

  • cleanup pool information ordering (91eb092)
  • merge dynamic pool events emission code (2babd9d)

0.4.23 (2024-08-27)

🐞 Bug Fixes

  • fix pool back pressure semantic on dynamic pool (00e2a3f)

⚡ Performance

  • track pool busy and back pressure lifecycle via events (a58ab3b)

📚 Documentation

0.4.22 (2024-08-26)

🐞 Bug Fixes

  • ensure no deleted dynamic worker can be used to steal task(s) (5c504d4)

✨ Polish

  • cleanup worker node back pressure detection implementation (1e0e4b5)
  • cleanup worker node state conditions check (5d8036c)

0.4.21 (2024-08-24)

🐞 Bug Fixes

  • fix pool ready status with zero min size dynamic pool (cebb8d8)

🧪 Tests

  • add pool empty event test (e353778)
  • optimize pool empty event test (e49f64a)

📚 Documentation

🤖 Automation

  • deps: Bump sonarsource/sonarcloud-github-action (#59) (d35a85f)

0.4.20 (2024-08-19)

🐞 Bug Fixes

  • account for all stealing worker nodes (039ec77)

✨ Polish

  • define a variable only when needed (145c656)
  • display back pressured worker nodes in pool info (51a3b96)
  • format properly || condition (da6bafa)

0.4.19 (2024-08-14)

🐞 Bug Fixes

  • reduce race condition at task response handling during pool destroy (7227fec)

0.4.18 (2024-08-14)

🐞 Bug Fixes

  • ensure task stealing can't start twice on the same worker node (6d81a8e)
  • fix dynamic worker node killing condition (6b3780e)
  • trigger continuous tasks stealing under proper conditions (ed3da2d)

🧪 Tests

  • silence leaks detection false positive on windows (96a0e78)

📚 Documentation

  • refine code comment about task stealing conditions (2459840)

0.4.17 (2024-08-13)

🚀 Features

  • reenable tasks stealing under back pressure by default (a944273)

🐞 Bug Fixes

  • protect worker node tasks queue from concurrent tasks stealing (dd85b2d)

⚡ Performance

  • do mapExecute() args sanity checks once (633afa3)

🧪 Tests

📚 Documentation

  • add documentation on enablePrority priority queue getter/setter (3ed4555)
  • api: add missing tasksStealingRatio default value (4814bef)

0.4.16 (2024-07-18)

🚀 Features

  • add ratio of worker nodes in a pool allowed to perform concurrent tasks stealing (7b7defe)

🧪 Tests

  • fix error type expectation (218cb7e)

📚 Documentation

  • api.md: add missing ToC entry (96badd7)
  • api.md: document tasksStealingRatio tasks queue option (9ed8a69)

🤖 Automation

  • deps: Bump github/combine-prs from 5.0.0 to 5.1.0 (#51) (81a44af)

0.4.15 (2024-07-11)

🐞 Bug Fixes

  • null exception when a task errored (328023f), closes #49

✨ Polish

  • priority-queue: cleanup intermediate variables namespace (a550353)

🧪 Tests

  • improve WorkerNode init coverage (7210f30)
  • revert incorrect change (53fb53d)

📚 Documentation

  • cleanup bun runtime usage (f802707)
  • fix PR template formatting (1d79921)
  • flag WorkerChoiceStrategiesContext class as internal (ba6948a)

0.4.14 (2024-07-07)

⚡ Performance

  • optimize tasks queuing implementation (4c4cdc0)

✨ Polish

  • factor out fixed queue common code in an abstract class (55070de)
  • move queueing code into its own directory (f8f1e26)

0.4.13 (2024-07-05)

🚀 Features

  • release with release-please (bc35b50)

🐞 Fixes

  • ensure checks are run on release PR (71c26f3)

📚 Documentation

  • ensure version is bumped on release in examples (a9b9dce)
  • refine contribution documentation (c0c1ac7)
  • refine PR template (369d51c)
  • refine README.md (a25a2d1)
  • refine README.md badges (4d91cd9)

✨ Polish

🤖 Automation

  • ci: add autofix GH action (9fde7c1)
  • ci: do not cancel workflow of autofix.ci fails (d1fe8c4)
  • deps-dev: apply updates (2b2a96a)
  • deps-dev: apply updates (7394780)
  • deps: Bump oven-sh/setup-bun from 1 to 2 (d5c4430)

[0.4.12] - 2024-06-21

Fixed

  • Fix priority queue dequeue() from the last prioritized bucket.

[0.4.11] - 2024-06-12

Changed

  • Add mapExecute() helper to execute a task function on an iterable data's input.

[0.4.10] - 2024-05-29

Changed

  • Optimize tasks queue implementation.
  • Enable prioritized tasks queueing only when necessary.

[0.4.9] - 2024-05-25

Changed

  • Optimize circular buffer implementation to store task execution measurements.

[0.4.8] - 2024-05-22

Changed

  • Switch to optimized circular buffer implementation to store task execution measurements.

[0.4.7] - 2024-05-20

Changed

  • Bump version to deal with npm package publication issue.

[0.4.6] - 2024-05-20

Fixed

  • Ensure tasks stealing dynamic worker node is not destroyed on inactivity.

[0.4.5] - 2024-05-15

Fixed

  • Fix default task function worker choice strategy and priority handling.

[0.4.4] - 2024-05-10

Fixed

  • Avoid queued tasks redistribution on the errored worker node.
  • Fix pools' addTaskFunction() type definition.

[0.4.3] - 2024-05-09

Fixed

  • Disable tasksStealingOnBackPressure by default until performance issues under heavy load are sorted out.

[0.4.2] - 2024-05-08

Changed

  • Optimize task(s) stealing by dequeuing task(s) from the last prioritized bucket.

[0.4.1] - 2024-05-08

Fixed

  • Fix worker nodes priority queue k-buckets initialization.

[0.4.0] - 2024-05-07

Changed

  • Support per task function(s) priority and worker choice strategy definition via a task function object: { taskFunction: (data?: Data) => Response | Promise<Response>, priority?: number, strategy?: WorkerChoiceStrategy }.
  • Add priority queue based tasks queueing. One priority queue is divided into prioritized buckets to avoid queued tasks starvation under load.
  • BREAKING CHANGE: listTaskFunctionNames() to listTaskFunctionsProperties() in pool and worker API returning registered task functions properties.
  • BREAKING CHANGE: strategy field in pool information renamed to defaultStrategy.

Fixed

  • Ensure dynamic worker node are initialized with sensible worker node usage default values to avoid worker choice strategies biased decisions.

[0.3.17] - 2024-04-30

Fixed

  • Ensure worker choice strategy options changes at runtime are propagated to poolifier workers.
  • Do not reset worker node usage statistics at worker choice strategy runtime change.

[0.3.16] - 2024-04-04

Fixed

  • Fix bundling.

[0.3.15] - 2024-04-04

Fixed

  • Fix possible race condition at worker node recreation on worker node error and exit events.

Changed

[0.3.14] - 2024-04-01

Changed

  • Add errorEventHandler handler support to pool options listening for error event on each worker.

[0.3.13] - 2024-04-01

Fixed

  • Ensure the minimum number of workers on a started pool is guaranteed.

[0.3.12] - 2024-03-30

Changed

  • Add tatami-ng and Bun support to internal benchmark.

[0.3.11] - 2024-03-27

Fixed

  • Fix conditional imports promise resolution.

[0.3.10] - 2024-03-27

Fixed

  • Fix browser compatibility: ensure node:... imports are conditionals.

[0.3.9] - 2024-03-27

Fixed

  • Fix worker initialization with Bun.

[0.3.8] - 2024-03-26

Fixed

  • Fix publishing on JSR.

[0.3.7] - 2024-03-26

Fixed

  • Publish only the needed files on JSR.

[0.3.6] - 2024-03-26

Changed

  • Refine package usage documentation.

[0.3.5] - 2024-03-26

Changed

  • Publish on JSR.

[0.3.4] - 2024-03-20

Fixed

  • Fix browser web worker default type.

[0.3.3] - 2024-03-20

Fixed

  • Fix browser bundle format.

[0.3.2] - 2024-03-18

Changed

  • Add TypeScript type declarations to npm package.

[0.3.1] - 2024-03-16

Fixed

  • Fix performance regression: compute estimated cpu speed only if strictly needed.

[0.3.0] - 2024-03-16

Changed:

  • Breaking change: remove node APIs usage in favor of Javascript web APIs. Pool event emitter emitter property is renamed to eventTarget and is using the EventTarget web API.

[0.2.3] - 2024-02-25

Fixed

  • Fix examples in documentation.

[0.2.2] - 2024-02-24

Fixed

  • Fix npm package publication GitHub action.

Changed

  • Add GitHub action to publish poolifier-web-worker package to npm packages registry.

[0.2.2-beta3] - 2024-02-24

Fixed

  • Fix npm package publication GitHub action, take 2.

Changed

  • Add GitHub action to publish poolifier-web-worker package to npm packages registry.

[0.2.2-beta2] - 2024-02-24

Fixed

  • Fix npm package publication GitHub action.

Changed

  • Add GitHub action to publish poolifier-web-worker package to npm packages registry.

[0.2.2-beta1] - 2024-02-24

Changed

  • Add GitHub action to publish poolifier-web-worker package to npm packages registry.

[0.2.1] - 2024-02-23

Fixed

  • Fix null exception regression: #1496.

[0.2.0] - 2024-01-28

Changed

  • Drop support for Deno version < 1.40.0: make IWorker interface compatible with Deno 1.40.x web worker type definition.

[0.1.17] - 2024-01-16

Fixed

  • Fix possible null exception at task finishing handling.

Changed

  • Optimize Deque implementation to improve tasks queueing performance.

[0.1.16] - 2024-01-06

Fixed

  • Fix dynamic pool with minimum number of workers set to zero: #1748.

[0.1.15] - 2024-01-05

Changed

  • Improve performance by clean up unneeded condition checks on hot code paths.

[0.1.14] - 2024-01-03

Changed

  • Removed wrongly exposed pool public method.

[0.1.13] - 2024-01-01

Fixed

  • Properly handle dynamic pool with zero minimum size.

[0.1.12] - 2023-12-30

Changed

  • Reduce branching in several hot code paths.
  • Use faster object cloning implementation.

[0.1.11] - 2023-12-25

Fixed

  • Fix tasks redistribution triggers at pool destroying.
  • Fix code coverage related deno tasks.

[0.1.10] - 2023-12-24

Fixed

  • Avoid worker node cross tasks stealing.
  • Ensure only half the pool worker nodes can steal tasks.

[0.1.9] - 2023-12-22

Changed

  • Readd ThreadPoolOptions TS type alias to PoolOptions.
  • Avoid useless branching on pool type.

[0.1.8] - 2023-12-21

Fixed

  • Fix default worker weight computation.

[0.1.7] - 2023-12-21

Fixed

  • Ensure worker choice strategies implementation wait for worker node readiness.

[0.1.6] - 2023-12-18

Fixed

  • Fix pool destroying with tasks queuing enabled.

[0.1.5] - 2023-12-18

Added

  • Add queued tasks end timeout support to worker node termination.

[0.1.4] - 2023-12-18

Fixed

  • Make more robust the fix for possible null exception at handling task execution response.

[0.1.3] - 2023-12-17

Fixed

  • Fix possible null exception at handling task execution response.

[0.1.2] - 2023-12-17

Fixed

  • Wait for queued tasks to end at worker node termination.

[0.1.1] - 2023-12-16

Changed

  • Cleanup default module exports.

[0.1.0] - 2023-12-16

Fixed

  • Ensure worker node is removed on worker error.

Changed

  • TypeScript breaking change: merge ThreadPoolOptions type into PoolOptions type.

[0.0.15] - 2023-12-13

Fixed

  • Ensure worker choice strategy wait for worker nodes readiness.

[0.0.14] - 2023-12-08

Changed

  • Add a fastpath when tasks stealing or redistribution is impossible.

[0.0.13] - 2023-11-27

Fixed

  • Remove all pool events listener at pool destroying.

[0.0.12] - 2023-11-25

Fixed

  • Fix task function usage statistics handling for sequentially stolen tasks.

[0.0.11] - 2023-11-25

Changed

  • Make continuous tasks stealing start at worker node idling.

[0.0.10] - 2023-11-24

Fixed

  • Ensure pool statuses are checked at initialization, start() or destroy().
  • Ensure pool ready event can be emitted after several start()/destroy() cycles.

[0.0.9] - 2023-10-29

Changed

  • Export via mod.ts instead of index.ts.

[0.0.8] - 2023-10-27

Changed

  • Improve documentation.

[0.0.7] - 2023-10-25

Fixed

  • Ensure pool cannot be initialized from a worker.
  • Ensure worker initialization is done once.

[0.0.6] - 2023-10-20

Added

[0.0.5] - 2023-10-20

Changed

  • Use builtin retry mechanism in worker choice strategies instead of custom one.

[0.0.4] - 2023-10-19

Fixed

  • Avoid null exception at sending message to worker.
  • Avoid null exception at checking worker node readiness.

[0.0.3] - 2023-10-17

Fixed

  • Fix race condition at dynamic worker node task assignment and scheduled removal. See issue #1468 and #1496.