Skip to main content
 首页 » 编程设计

python之App Engine 的云存储客户端库默认重试逻辑是什么

2024年10月24日37xiaohuochai

我试图找出 App Engine 的 Cloud Storage Client Library 的默认重试逻辑是什么.

来自RetryParams docs并且它上面的链接“感觉”好像有一些默认的重试逻辑。

然而 source code here否则表示。

有人知道明确的答案吗?

谢谢

请您参考如下方法:

如果未指定retry_params,则使用此处的默认值: https://github.com/GoogleCloudPlatform/appengine-gcs-client/blob/master/python/src/cloudstorage/rest_api.py#L146

默认设置可以在这里看到: https://github.com/GoogleCloudPlatform/appengine-gcs-client/blob/master/python/src/cloudstorage/api_utils.py#L210-L215

为后代粘贴:

backoff_factor=2.0, 
initial_delay=0.1, 
max_delay=10.0, 
min_retries=3, 
max_retries=6, 
max_retry_period=30.0,