This repository was archived by the owner on Apr 15, 2024. It is now read-only.

Description
Original Issue: apache#2786
QUESTION
There is no way to use my own dns resolver in BookKeeperClient, but I can use it in other places.
Should this in conflict?
// BookKeeperClient.commonInitialization
private synchronized void commonInitialization(
DistributedLogConfiguration conf,
String ledgersPath,
EventLoopGroup eventLoopGroup,
StatsLogger statsLogger, HashedWheelTimer requestTimer)
throws IOException, InterruptedException {
// other code ...
Class<? extends DNSToSwitchMapping> dnsResolverCls;
try {
dnsResolverCls = conf.getEnsemblePlacementDnsResolverClass();
} catch (ConfigurationException e) {
LOG.error("Failed to load bk dns resolver : ", e);
throw new IOException("Failed to load bk dns resolver : ", e);
}
final DNSToSwitchMapping dnsResolver =
NetUtils.getDNSResolver(dnsResolverCls, conf.getBkDNSResolverOverrides());
// other code ...
}
who can give me a answer of :
- only DNSResolverForRows or DNSResolverForRacks will returned.
- if config
reppDnsResolverClass is set, my onw dns resolver will be loaded in other places.
dose this in conflict...