Sets defaults in swift connection related to retries

This patch sets the following defaults in the swfit connection to
manage retries.

retries – Number of times to retry the request before failing
starting_backoff – initial delay between retries (seconds)
max_backoff – maximum delay between retries (seconds)

Change-Id: I26fcb994f91309eedb9d8ccc17939bc9f4c6a116
Closes-Bug: #1634195
This commit is contained in:
Ryan Brady 2016-10-20 07:14:27 -04:00
parent 2af623f79f
commit 5c575970cf
1 changed files with 4 additions and 1 deletions

View File

@ -35,7 +35,10 @@ class TripleOAction(base.Action):
kwargs = {
'preauthurl': obj_ep.url % {'tenant_id': ctx.project_id},
'preauthtoken': ctx.auth_token
'preauthtoken': ctx.auth_token,
'retries': 10,
'starting_backoff': 3,
'max_backoff': 120
}
return swift_client.Connection(**kwargs)