From 680cfc977a77c832193f008d6ce5d81fb9e678ab Mon Sep 17 00:00:00 2001 From: Gabe Kangas Date: Fri, 27 May 2022 18:44:26 -0700 Subject: [PATCH] Removing fetch retries for now until I write it from scratch --- web/package-lock.json | 29 --------------------------- web/package.json | 1 - web/services/client-config-service.ts | 7 +------ 3 files changed, 1 insertion(+), 36 deletions(-) diff --git a/web/package-lock.json b/web/package-lock.json index 41f31f6be..4ee1f32a0 100644 --- a/web/package-lock.json +++ b/web/package-lock.json @@ -18,7 +18,6 @@ "chartkick": "4.1.1", "classnames": "2.3.1", "date-fns": "2.28.0", - "isomorphic-fetch": "^3.0.0", "lodash": "4.17.21", "markdown-it": "12.3.2", "next": "^12.1.5", @@ -20495,15 +20494,6 @@ "node": ">=0.10.0" } }, - "node_modules/isomorphic-fetch": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-3.0.0.tgz", - "integrity": "sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA==", - "dependencies": { - "node-fetch": "^2.6.1", - "whatwg-fetch": "^3.4.1" - } - }, "node_modules/istanbul-lib-coverage": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", @@ -32447,11 +32437,6 @@ "iconv-lite": "0.4.24" } }, - "node_modules/whatwg-fetch": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.6.2.tgz", - "integrity": "sha512-bJlen0FcuU/0EMLrdbJ7zOnW6ITZLrZMIarMUVmdKtsGvZna8vxKYaexICWPfZ8qwf9fzNq+UEIZrnSaApt6RA==" - }, "node_modules/whatwg-mimetype": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-2.3.0.tgz", @@ -48154,15 +48139,6 @@ "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" }, - "isomorphic-fetch": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-3.0.0.tgz", - "integrity": "sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA==", - "requires": { - "node-fetch": "^2.6.1", - "whatwg-fetch": "^3.4.1" - } - }, "istanbul-lib-coverage": { "version": "3.2.0", "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz", @@ -57390,11 +57366,6 @@ "iconv-lite": "0.4.24" } }, - "whatwg-fetch": { - "version": "3.6.2", - "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.6.2.tgz", - "integrity": "sha512-bJlen0FcuU/0EMLrdbJ7zOnW6ITZLrZMIarMUVmdKtsGvZna8vxKYaexICWPfZ8qwf9fzNq+UEIZrnSaApt6RA==" - }, "whatwg-mimetype": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-2.3.0.tgz", diff --git a/web/package.json b/web/package.json index ad79be67c..fe48813f4 100644 --- a/web/package.json +++ b/web/package.json @@ -22,7 +22,6 @@ "chartkick": "4.1.1", "classnames": "2.3.1", "date-fns": "2.28.0", - "isomorphic-fetch": "^3.0.0", "lodash": "4.17.21", "markdown-it": "12.3.2", "next": "^12.1.5", diff --git a/web/services/client-config-service.ts b/web/services/client-config-service.ts index 665773ff4..633678b0f 100644 --- a/web/services/client-config-service.ts +++ b/web/services/client-config-service.ts @@ -1,15 +1,10 @@ import { ClientConfig } from '../interfaces/client-config.model'; -const originalFetch = require('isomorphic-fetch'); -const fetch = require('fetch-retry')(originalFetch); const ENDPOINT = `http://localhost:8080/api/config`; class ClientConfigService { public static async getConfig(): Promise { - const response = await fetch(ENDPOINT, { - retries: 20, - retryDelay: (attempt, error, response) => 3 ** attempt * 1000, - }); + const response = await fetch(ENDPOINT); const status = await response.json(); return status; }