python - RetryParams 的 min_retries 的目的是什么?

标签 python google-cloud-storage

在 RetryParams 文档中,有 min_retries 和 max_retries 参数。我可以理解有 max_retries 参数,但不确定有 min_retries 的意义是什么。文档 ( https://cloud.google.com/appengine/docs/python/googlecloudstorageclient/retryparams_class ) 显示以下内容:

min_retries
The minimum number of times to retry.
max_retries
The maximum number of times to retry. Set this value to 0 if you don't want any retries.

如果我将 max_retries 设置为 10,我希望如果连接反复失败,它最多会尝试 10 次。为什么需要 min_retries 参数?什么时候会发挥作用?

最佳答案

从该文档页面:

max_retry_period
The maximum number of seconds that can be spent on all retries of a given request. Retry stops when this period passed AND min_retries has been attempted.

关于python - RetryParams 的 min_retries 的目的是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27785855/

相关文章:

python - 无法使用 python 脚本切换 gcloud 平台帐户

python - 如果外键不存在,SQLAlchemy 会自动创建条目

google-cloud-platform - 使用 Terraform 为 GCS 启用 "Interoperable"访问权限?

python - 如何使用 Zeep 准备 SOAP 请求?

python - librosa 不会规范化 [-1, 1] 之间的 wave 文件

ruby-on-rails - 使用 Paperclip 和 Rails 时谷歌云存储请求很慢

google-cloud-platform - 是否可以将云功能触发器配置为 GCS 存储桶的文件夹级别?

google-app-engine - 演示项目中的appengine云存储编译错误

python - Tensorflow 2.0 Autograph 间接修改(隐藏状态)可以工作,但它不应该工作

python - 返回具有相同值节点的最长路径