1
0
mirror of https://github.com/verdaccio/verdaccio.git synced 2024-11-13 03:35:52 +01:00
verdaccio/test/functional
Will Smythe eb7a8e3528 fix(api): return 503 to npm/yarn on uplink connection timeout (#1331)
fix  #1328 and #720

Type: bug

The following has been addressed in the PR:

Instead of returning a 404 (Not Found) when npm, yarn, etc requests a package and the package cannot be acquired from an uplink due to a connection timeout, socket timeout, or connection reset problem, a 503 (service unavailable) is returned by Verdaccio instead. In limited testing of a few versions of npm and yarn, both of these clients correctly attempt to retry the request when a 503 is returned.

Added functional tests to verify the behavior (this adds a dev dependency on nock, which provides HTTP request mocking

Description:

This resolves issue #1328 and #720, and ensures npm/yarn install commands don't fail immediately when there is an intermittent network timeout problem with an uplink. Instead Verdaccio will appropriately respond to the client with a 503. A 404 response (current behavior) incorrectly tells the client that the package does not exist (which may or may not be true) and to not try again.
2019-06-13 21:42:01 +02:00
..
adduser refactor: usage of constants on sanity test 2018-06-23 20:59:30 +02:00
basic refactor: typo fixes (#1030) 2018-10-02 07:47:46 +02:00
fixtures fix(api): return 503 to npm/yarn on uplink connection timeout (#1331) 2019-06-13 21:42:01 +02:00
lib feat: replace chalk with kleur (#1289) @DanielRuf 2019-04-29 08:44:29 +02:00
notifications refactor: improve code with es6 style 2018-06-24 10:11:52 +02:00
package chore: remove long timeout 2019-02-03 12:10:13 +01:00
performance refactor: race condition test 2018-06-23 20:59:21 +02:00
plugins refactor: use of constants for testing 2018-06-23 20:59:29 +02:00
readme feat: update readme v4 (#1312) 2019-05-17 08:03:58 -07:00
sanity chore: testing local-storage 2019-02-03 12:06:33 +01:00
scenarios refactor: improve code with es6 style 2018-06-24 10:11:52 +02:00
search chore: remove long timeout 2019-02-03 12:10:13 +01:00
store fix(api): return 503 to npm/yarn on uplink connection timeout (#1331) 2019-06-13 21:42:01 +02:00
tags chore: update toStrictEqual to toEqual 2019-02-25 07:16:49 +01:00
uplinks fix(api): return 503 to npm/yarn on uplink connection timeout (#1331) 2019-06-13 21:42:01 +02:00
config.functional.js refactor: unit test goes offline 2018-06-26 06:15:06 +02:00
index.spec.js fix(api): return 503 to npm/yarn on uplink connection timeout (#1331) 2019-06-13 21:42:01 +02:00
pre-setup.js refactor babel7 (#1164) 2018-12-22 16:11:09 +01:00
teardown.js feat: replace chalk with kleur (#1289) @DanielRuf 2019-04-29 08:44:29 +02:00
test-environment.js refactor babel7 (#1164) 2018-12-22 16:11:09 +01:00