Browse Source

Increase request timeout for sidecar

By default sidecar timeout to authenticate to Keystone
is set to 5 seconds.

In most of the cases 5 seconds is enough but depending
the environment, the authentication complexity, etc...
it could be too short.

Change-Id: I02146bc67ec783786aa280f7759623abeb84bd21
Story: 2005769
Task: 33486
changes/22/661122/2
Gaetan Trellu 2 years ago
parent
commit
7234980037
  1. 2
      runtimes/sidecar/sidecar.py

2
runtimes/sidecar/sidecar.py

@ -56,7 +56,7 @@ def _download_package(url, zip_file, token=None, unzip=None):
headers = {'X-Auth-Token': token}
try:
r = requests.get(url, headers=headers, stream=True, timeout=5,
r = requests.get(url, headers=headers, stream=True, timeout=30,
verify=False)
if r.status_code != 200:
return make_response(DOWNLOAD_ERROR % (url, r.content), 500)

Loading…
Cancel
Save