mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
minor
This commit is contained in:
parent
659133fb68
commit
4e493d596c
|
@ -30,6 +30,10 @@ func NewCircuitBreaker(option *S3ApiServerOption) *CircuitBreaker {
|
||||||
|
|
||||||
err := pb.WithFilerClient(false, 0, option.Filer, option.GrpcDialOption, func(client filer_pb.SeaweedFilerClient) error {
|
err := pb.WithFilerClient(false, 0, option.Filer, option.GrpcDialOption, func(client filer_pb.SeaweedFilerClient) error {
|
||||||
content, err := filer.ReadInsideFiler(client, s3_constants.CircuitBreakerConfigDir, s3_constants.CircuitBreakerConfigFile)
|
content, err := filer.ReadInsideFiler(client, s3_constants.CircuitBreakerConfigDir, s3_constants.CircuitBreakerConfigFile)
|
||||||
|
if err == filer_pb.ErrNotFound {
|
||||||
|
glog.Infof("s3 circuit breaker not configured")
|
||||||
|
return nil
|
||||||
|
}
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("read S3 circuit breaker config: %v", err)
|
return fmt.Errorf("read S3 circuit breaker config: %v", err)
|
||||||
}
|
}
|
||||||
|
@ -37,7 +41,7 @@ func NewCircuitBreaker(option *S3ApiServerOption) *CircuitBreaker {
|
||||||
})
|
})
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
glog.Infof("s3 circuit breaker not configured: %v", err)
|
glog.Infof("s3 circuit breaker not configured correctly: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
return cb
|
return cb
|
||||||
|
|
Loading…
Reference in a new issue