mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-14 18:53:35 +00:00
rebase: bump google.golang.org/grpc from 1.69.4 to 1.70.0
Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.69.4 to 1.70.0. - [Release notes](https://github.com/grpc/grpc-go/releases) - [Commits](https://github.com/grpc/grpc-go/compare/v1.69.4...v1.70.0) --- updated-dependencies: - dependency-name: google.golang.org/grpc dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
15ffa48082
commit
72cfaaf3fc
17
vendor/google.golang.org/grpc/service_config.go
generated
vendored
17
vendor/google.golang.org/grpc/service_config.go
generated
vendored
@ -268,18 +268,21 @@ func parseServiceConfig(js string, maxAttempts int) *serviceconfig.ParseResult {
|
||||
return &serviceconfig.ParseResult{Config: &sc}
|
||||
}
|
||||
|
||||
func isValidRetryPolicy(jrp *jsonRetryPolicy) bool {
|
||||
return jrp.MaxAttempts > 1 &&
|
||||
jrp.InitialBackoff > 0 &&
|
||||
jrp.MaxBackoff > 0 &&
|
||||
jrp.BackoffMultiplier > 0 &&
|
||||
len(jrp.RetryableStatusCodes) > 0
|
||||
}
|
||||
|
||||
func convertRetryPolicy(jrp *jsonRetryPolicy, maxAttempts int) (p *internalserviceconfig.RetryPolicy, err error) {
|
||||
if jrp == nil {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
if jrp.MaxAttempts <= 1 ||
|
||||
jrp.InitialBackoff <= 0 ||
|
||||
jrp.MaxBackoff <= 0 ||
|
||||
jrp.BackoffMultiplier <= 0 ||
|
||||
len(jrp.RetryableStatusCodes) == 0 {
|
||||
logger.Warningf("grpc: ignoring retry policy %v due to illegal configuration", jrp)
|
||||
return nil, nil
|
||||
if !isValidRetryPolicy(jrp) {
|
||||
return nil, fmt.Errorf("invalid retry policy (%+v): ", jrp)
|
||||
}
|
||||
|
||||
if jrp.MaxAttempts < maxAttempts {
|
||||
|
Reference in New Issue
Block a user