@pronto-tools-and-more/network-process 6.10.0 → 6.11.0

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pronto-tools-and-more/network-process",
3
- "version": "6.10.0",
3
+ "version": "6.11.0",
4
4
  "description": "",
5
5
  "main": "src/networkProcessMain.js",
6
6
  "type": "module",
@@ -14,7 +14,7 @@ export const handleZipUploadError = async ({
14
14
  console.info();
15
15
  return {
16
16
  retry: true,
17
- message: `[pronto-network-process] Cloudfront 504 error, retrying ${maxRetries} more times in ${waitBetweenRetries}ms`,
17
+ retryMessage: `[pronto-network-process] Cloudfront 504 error, retrying ${maxRetries} more times in ${waitBetweenRetries}ms`,
18
18
  };
19
19
  } else {
20
20
  throw new Error(`Failed to upload zip: Cloudfront 504 error`);
@@ -33,7 +33,7 @@ export const handleZipUploadError = async ({
33
33
  if (maxRetries > 0) {
34
34
  return {
35
35
  retry: true,
36
- message: `[pronto-network-process] processing resources error, retrying ${maxRetries} more times in ${waitBetweenRetries}ms`,
36
+ retryMessage: `[pronto-network-process] processing resources error, retrying ${maxRetries} more times in ${waitBetweenRetries}ms`,
37
37
  };
38
38
  } else {
39
39
  throw new Error(`Failed to upload zip: Processing resources error`);
@@ -58,13 +58,14 @@ export const uploadZip = async ({
58
58
  }
59
59
  return text;
60
60
  } catch (error) {
61
- const { retry, message } = await HandleZipUploadError.handleZipUploadError({
62
- error,
63
- maxRetries,
64
- waitBetweenRetries,
65
- });
61
+ const { retry, retryMessage } =
62
+ await HandleZipUploadError.handleZipUploadError({
63
+ error,
64
+ maxRetries,
65
+ waitBetweenRetries,
66
+ });
66
67
  if (retry) {
67
- console.info(message);
68
+ console.info(retryMessage);
68
69
  await Timeout.wait(waitBetweenRetries);
69
70
  return uploadZip({
70
71
  file,