Skip to content

Commit 4325f8c

Browse files
authored
increase wait and retries (#129)
* increase wait and retries * add server wait retries * bump version
1 parent bce4e28 commit 4325f8c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "truss"
3-
version = "0.1.6"
3+
version = "0.1.7"
44
description = "A seamless bridge from model development to model delivery"
55
license = "MIT"
66
readme = "README.md"

truss/truss_handle.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -201,8 +201,8 @@ def docker_predict(
201201
)
202202
model_base_url = _get_url_from_container(container)
203203
for attempt in Retrying(
204-
stop=stop_after_attempt(6),
205-
wait=wait_exponential(multiplier=2, min=1, max=32),
204+
stop=stop_after_attempt(15),
205+
wait=wait_exponential(multiplier=2, min=5, max=32),
206206
retry=retry_if_exception_type(ConnectionError),
207207
):
208208
resp = requests.post(
@@ -792,7 +792,7 @@ def _wait_for_docker_build(container):
792792

793793

794794
def _wait_for_model_server(url: str):
795-
for attempt in Retrying(stop=stop_after_attempt(5), wait=wait_fixed(2)):
795+
for attempt in Retrying(stop=stop_after_attempt(10), wait=wait_fixed(2)):
796796
with attempt:
797797
resp = requests.get(url)
798798
resp.raise_for_status()

0 commit comments

Comments
 (0)