poolifier 2.3.7 → 2.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (27) hide show
  1. package/lib/index.d.ts +14 -881
  2. package/lib/index.js +1 -1
  3. package/lib/index.mjs +1 -0
  4. package/lib/pools/abstract-pool.d.ts +219 -0
  5. package/lib/pools/cluster/dynamic.d.ts +30 -0
  6. package/lib/pools/cluster/fixed.d.ts +64 -0
  7. package/lib/pools/pool-internal.d.ts +85 -0
  8. package/lib/pools/pool-worker.d.ts +35 -0
  9. package/lib/pools/pool.d.ts +73 -0
  10. package/lib/pools/selection-strategies/abstract-worker-choice-strategy.d.ts +27 -0
  11. package/lib/pools/selection-strategies/dynamic-pool-worker-choice-strategy.d.ts +27 -0
  12. package/lib/pools/selection-strategies/fair-share-worker-choice-strategy.d.ts +29 -0
  13. package/lib/pools/selection-strategies/less-recently-used-worker-choice-strategy.d.ts +15 -0
  14. package/lib/pools/selection-strategies/round-robin-worker-choice-strategy.d.ts +19 -0
  15. package/lib/pools/selection-strategies/selection-strategies-types.d.ts +55 -0
  16. package/lib/pools/selection-strategies/selection-strategies-utils.d.ts +11 -0
  17. package/lib/pools/selection-strategies/weighted-round-robin-worker-choice-strategy.d.ts +43 -0
  18. package/lib/pools/selection-strategies/worker-choice-strategy-context.d.ts +48 -0
  19. package/lib/pools/thread/dynamic.d.ts +31 -0
  20. package/lib/pools/thread/fixed.d.ts +48 -0
  21. package/lib/utility-types.d.ts +63 -0
  22. package/lib/utils.d.ts +4 -0
  23. package/lib/worker/abstract-worker.d.ts +86 -0
  24. package/lib/worker/cluster-worker.d.ts +32 -0
  25. package/lib/worker/thread-worker.d.ts +30 -0
  26. package/lib/worker/worker-options.d.ts +61 -0
  27. package/package.json +52 -35
package/package.json CHANGED
@@ -1,8 +1,12 @@
1
1
  {
2
2
  "name": "poolifier",
3
- "version": "2.3.7",
3
+ "version": "2.3.9",
4
4
  "description": "A fast, easy to use Node.js Worker Thread Pool and Cluster Pool implementation",
5
- "main": "lib/index.js",
5
+ "license": "MIT",
6
+ "exports": [
7
+ "lib/index.js",
8
+ "lib/index.mjs"
9
+ ],
6
10
  "scripts": {
7
11
  "prepare": "node prepare.js",
8
12
  "build": "rollup --config --environment BUILD:development",
@@ -15,17 +19,22 @@
15
19
  "test:debug": "npm run build && mocha --no-parallel --inspect 'tests/**/*.test.js'",
16
20
  "coverage": "c8 report --reporter=lcov",
17
21
  "coverage:html": "c8 report --reporter=html",
22
+ "format": "prettier . --cache --write; ts-standard . --fix",
18
23
  "lint": "eslint . --cache",
19
24
  "lint:fix": "eslint . --cache --fix",
20
25
  "lint:report": "eslint . --cache --format json --output-file reports/eslint.json",
21
26
  "release": "release-it",
22
27
  "typedoc": "typedoc",
23
- "sonar:properties": "./updateSonarProps.sh",
24
28
  "prepublishOnly": "npm run build:prod"
25
29
  },
26
30
  "ts-standard": {
27
- "ignore": [
28
- "tests/**/*.js"
31
+ "globals": [
32
+ "describe",
33
+ "it",
34
+ "before",
35
+ "after",
36
+ "beforeEach",
37
+ "afterEach"
29
38
  ]
30
39
  },
31
40
  "engines": {
@@ -64,7 +73,12 @@
64
73
  "url": "https://github.com/jerome-benoit"
65
74
  }
66
75
  ],
67
- "license": "MIT",
76
+ "funding": [
77
+ {
78
+ "type": "opencollective",
79
+ "url": "https://opencollective.com/poolifier"
80
+ }
81
+ ],
68
82
  "bugs": {
69
83
  "url": "https://github.com/poolifier/poolifier/issues"
70
84
  },
@@ -73,42 +87,45 @@
73
87
  "lib"
74
88
  ],
75
89
  "devDependencies": {
90
+ "@commitlint/cli": "^17.4.4",
91
+ "@commitlint/config-conventional": "^17.4.4",
92
+ "@release-it/bumper": "^4.0.2",
76
93
  "@release-it/keep-a-changelog": "^3.1.0",
77
- "@types/node": "^18.11.3",
78
- "@typescript-eslint/eslint-plugin": "^5.40.1",
79
- "@typescript-eslint/parser": "^5.40.1",
80
- "benchmark": "^2.1.4",
81
- "c8": "^7.12.0",
82
- "eslint": "^8.26.0",
94
+ "@rollup/plugin-terser": "^0.4.0",
95
+ "@rollup/plugin-typescript": "^11.0.0",
96
+ "@types/node": "^18.15.3",
97
+ "@typescript-eslint/eslint-plugin": "^5.55.0",
98
+ "@typescript-eslint/parser": "^5.55.0",
99
+ "benny": "^3.7.1",
100
+ "c8": "^7.13.0",
101
+ "eslint": "^8.36.0",
83
102
  "eslint-config-standard": "^17.0.0",
84
- "eslint-config-standard-with-typescript": "^23.0.0",
85
- "eslint-define-config": "^1.7.0",
86
- "eslint-import-resolver-typescript": "^3.5.2",
87
- "eslint-plugin-import": "^2.26.0",
88
- "eslint-plugin-jsdoc": "^39.3.19",
89
- "eslint-plugin-n": "^15.3.0",
103
+ "eslint-config-standard-with-typescript": "^34.0.1",
104
+ "eslint-define-config": "^1.17.0",
105
+ "eslint-import-resolver-typescript": "^3.5.3",
106
+ "eslint-plugin-import": "^2.27.5",
107
+ "eslint-plugin-jsdoc": "^40.0.3",
108
+ "eslint-plugin-n": "^15.6.1",
90
109
  "eslint-plugin-promise": "^6.1.1",
91
- "eslint-plugin-spellcheck": "^0.0.19",
92
- "expect": "^29.2.1",
93
- "husky": "^8.0.1",
94
- "lint-staged": "^13.0.3",
110
+ "eslint-plugin-spellcheck": "^0.0.20",
111
+ "eslint-plugin-tsdoc": "^0.2.17",
112
+ "expect": "^29.5.0",
113
+ "husky": "^8.0.3",
114
+ "lint-staged": "^13.2.0",
95
115
  "microtime": "^3.1.1",
96
- "mocha": "^10.1.0",
116
+ "mocha": "^10.2.0",
97
117
  "mochawesome": "^7.1.3",
98
- "prettier": "^2.7.1",
99
- "prettier-plugin-organize-imports": "^3.1.1",
100
- "release-it": "^15.5.0",
101
- "rollup": "^3.2.3",
118
+ "prettier": "^2.8.4",
119
+ "prettier-plugin-organize-imports": "^3.2.2",
120
+ "release-it": "^15.9.0",
121
+ "rollup": "^3.19.1",
102
122
  "rollup-plugin-analyzer": "^4.0.0",
103
123
  "rollup-plugin-command": "^1.1.3",
104
124
  "rollup-plugin-delete": "^2.0.0",
105
- "rollup-plugin-istanbul": "^3.0.0",
106
- "rollup-plugin-terser": "^7.0.2",
107
- "rollup-plugin-ts": "^3.0.2",
108
- "sinon": "^14.0.1",
125
+ "sinon": "^15.0.2",
109
126
  "source-map-support": "^0.5.21",
110
- "ts-standard": "^12.0.1",
111
- "typedoc": "^0.23.17",
112
- "typescript": "^4.8.4"
127
+ "ts-standard": "^12.0.2",
128
+ "typedoc": "^0.23.27",
129
+ "typescript": "^5.0.2"
113
130
  }
114
- }
131
+ }