@applitools/eyes-cypress 3.23.6 → 3.23.7

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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,10 @@
3
3
  ## Unreleased
4
4
 
5
5
 
6
+ ## 3.23.7 - 2022/1/28
7
+
8
+ - add concurrency limitation on local server
9
+
6
10
  ## 3.23.6 - 2022/1/20
7
11
 
8
12
  - fix global hook overrides
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applitools/eyes-cypress",
3
- "version": "3.23.6",
3
+ "version": "3.23.7",
4
4
  "main": "index.js",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "bin": {
@@ -48,7 +48,8 @@
48
48
  "chalk": "3.0.0",
49
49
  "cors": "2.8.5",
50
50
  "express": "4.17.1",
51
- "lodash.flatten": "4.4.0"
51
+ "lodash.flatten": "4.4.0",
52
+ "throat": "6.0.1"
52
53
  },
53
54
  "devDependencies": {
54
55
  "@applitools/scripts": "^1.1.0",
@@ -68,7 +69,7 @@
68
69
  "mocha": "^8.0.1",
69
70
  "morgan": "^1.9.1",
70
71
  "ncp": "^2.0.0",
71
- "node-fetch": "^2.6.0",
72
+ "node-fetch": "^2.6.7",
72
73
  "prettier": "^1.19.1",
73
74
  "typescript": "^3.9.2"
74
75
  },
@@ -1,7 +1,9 @@
1
1
  'use strict';
2
+ const throat = require('throat');
3
+ const CONCURRENCY_LIMITATION = 100;
2
4
 
3
5
  function makeSend(port, fetch) {
4
- return function send({
6
+ const send = function send({
5
7
  command,
6
8
  data,
7
9
  method = 'POST',
@@ -13,6 +15,8 @@ function makeSend(port, fetch) {
13
15
  headers,
14
16
  });
15
17
  };
18
+
19
+ return throat(CONCURRENCY_LIMITATION, send);
16
20
  }
17
21
 
18
22
  module.exports = makeSend;