Use generic HTTP retry policy by default and rename dedicated decorator
Instead of retrying HTTP requests only for 429 status code by default, prefer to use the generic retry policy enabling to also retry for status codes >= 500 but also on ConnectionError exceptions. Rename throttling_retry decorator to http_retry to reflect this change.
This commit is contained in:
parent
9b3e565cf7
commit
9c55acd286
23 changed files with 71 additions and 62 deletions
|
@ -138,7 +138,7 @@ def test_gitea_auth_instance(swh_scheduler, requests_mock, trygitea_p1):
|
|||
assert stats.pages == 1
|
||||
|
||||
|
||||
@pytest.mark.parametrize("http_code", [400, 500, 502])
|
||||
@pytest.mark.parametrize("http_code", [400, 500])
|
||||
def test_gitea_list_http_error(
|
||||
swh_scheduler, requests_mock, http_code, trygitea_p1, trygitea_p2
|
||||
):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue