forked from TrueCloudLab/frostfs-sdk-go
[#342] client: Disable service config query
By default, gRPC fetches TXT report while resolving a domain.
0914bba6c5/internal/resolver/dns/dns_resolver.go (L336)
This leads to a hanging dial if DNS is unavailable, even though the host
may be specified in `/etc/hosts` (hello, localhost!).
Use `grpc.WithDisableServiceConfig()` to override the default.
This option seems impossible to override with `WithGRPCDialOpts()`,
but we do not use service config anyway.
Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
7a37613988
commit
69b0711d12
1 changed files with 1 additions and 0 deletions
|
@ -38,6 +38,7 @@ func (c *cfg) initDefault() {
|
||||||
c.rwTimeout = defaultRWTimeout
|
c.rwTimeout = defaultRWTimeout
|
||||||
c.grpcDialOpts = []grpc.DialOption{
|
c.grpcDialOpts = []grpc.DialOption{
|
||||||
grpc.WithTransportCredentials(insecure.NewCredentials()),
|
grpc.WithTransportCredentials(insecure.NewCredentials()),
|
||||||
|
grpc.WithDisableServiceConfig(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue