Skip to content
Snippets Groups Projects
Commit 77bbafca authored by Antoine Lambert's avatar Antoine Lambert
Browse files

api: Add an optional requests retry feature to the RPC client

Add a new enable_requests_retry flag to the swh.core.api.RPCClient
class, default to False, allowing to retry requests sent by the
client when encountering specific errors. Default policy is to retry
when connection errors and transient remote exceptions are raised.
Subclasses can change that policy by overriding the retry_policy
method. Such failed requests will be retry at most five times with a
delay of 10 seconds between each.
parent 0570b278
No related branches found
No related tags found
No related merge requests found
Pipeline #11904 passed
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment