Top Description Fields Constructors Methods
io.netty.resolver.dns

public final Class DnsNameResolverBuilder

extends Object
Class Inheritance
Imports
io.netty.channel.ChannelFactory, .EventLoop, .ReflectiveChannelFactory, io.netty.channel.socket.DatagramChannel, .InternetProtocolFamily, .SocketChannel, io.netty.resolver.HostsFileEntriesResolver, .ResolvedAddressTypes, io.netty.util.concurrent.Future, io.netty.util.internal.EmptyArrays, .ObjectUtil, io.netty.util.internal.logging.InternalLogger, .InternalLoggerFactory, java.net.SocketAddress, java.util.ArrayList, .Arrays, .List

A DnsNameResolver builder.

Field Summary

Modifier and TypeField and Description
private AuthoritativeDnsServerCache
private ChannelFactory<? extends DatagramChannel>
channelFactory

Deprecated as a consequence of ChannelFactory being deprecated.
private DnsCnameCache
private boolean
private boolean
private DnsQueryLifecycleObserverFactory
private DnsServerAddressStreamProvider
pack-priv volatile EventLoop
private HostsFileEntriesResolver
private SocketAddress
private static final InternalLogger
private int
private int
private int
private Integer
private Integer
private int
private Integer
private boolean
private long
private boolean
private DnsCache
private ResolvedAddressTypes
private boolean
private String[]
private ChannelFactory<? extends SocketChannel>
socketChannelFactory

Deprecated as a consequence of ChannelFactory being deprecated.
private boolean

Constructor Summary

AccessConstructor and Description
public
DnsNameResolverBuilder()

Creates a new builder.

public
DnsNameResolverBuilder(EventLoop
the EventLoop which will perform the communication with the DNS servers.
eventLoop
)

Creates a new builder.

Method Summary

Modifier and TypeMethod and Description
public DnsNameResolverBuilder

Returns:

this
authoritativeDnsServerCache
(DnsCache
the authoritative NS servers cache
authoritativeDnsServerCache
)

Sets the cache for authoritative NS servers
public DnsNameResolverBuilder

Returns:

this
authoritativeDnsServerCache
(AuthoritativeDnsServerCache
the authoritative NS servers cache
authoritativeDnsServerCache
)

Sets the cache for authoritative NS servers

public DnsNameResolver

Returns:

a DnsNameResolver
build
()

Returns a new DnsNameResolver instance.

protected ChannelFactory<? extends DatagramChannel>
channelFactory()

Deprecated as a consequence of ChannelFactory being deprecated.
public DnsNameResolverBuilder

Returns:

this
channelFactory
(ChannelFactory<? extends DatagramChannel> channelFactory)

Deprecated as a consequence of ChannelFactory being deprecated.
Sets the ChannelFactory that will create a DatagramChannel.
public DnsNameResolverBuilder

Returns:

this
channelType
(Class<? extends DatagramChannel>
the type
channelType
)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type.

public DnsNameResolverBuilder

Returns:

this
cnameCache
(DnsCnameCache
the cache used to cache CNAME mappings for a domain.
cnameCache
)

Sets the cache for CNAME mappings.

public DnsNameResolverBuilder

Returns:

this
completeOncePreferredResolved
(boolean
true to enable, false to disable.
completeOncePreferredResolved
)

If true DnsNameResolver#resolveAll(String) will notify the returned Future as soon as all queries for the preferred address-type are complete.

public static ResolvedAddressTypes
public DnsNameResolverBuilder

Returns:

this
consolidateCacheSize
(int
the maximum lookups to consolidate (different hostnames), or 0 if no consolidation should be performed.
maxNumConsolidation
)

Set the maximum size of the cache that is used to consolidate lookups for different hostnames when in-flight.

public DnsNameResolverBuilder
copy()

Creates a copy of this DnsNameResolverBuilder

public DnsNameResolverBuilder

Returns:

this
decodeIdn
(boolean
if should get decoded
decodeIdn
)

Set if domain / host names should be decoded to unicode when received.

public DnsNameResolverBuilder

Returns:

this
dnsQueryLifecycleObserverFactory
(DnsQueryLifecycleObserverFactory
the factory used to generate objects which can observe individual DNS queries.
lifecycleObserverFactory
)

Set the factory used to generate objects which can observe individual DNS queries.

public DnsNameResolverBuilder

Returns:

this
eventLoop
(EventLoop eventLoop)

Sets the EventLoop which will perform the communication with the DNS servers.

public DnsNameResolverBuilder

Returns:

this
hostsFileEntriesResolver
(HostsFileEntriesResolver
the HostsFileEntriesResolver used to first check if the hostname is locally aliased.
hostsFileEntriesResolver
)

public DnsNameResolverBuilder

Returns:

this
localAddress
(SocketAddress
the bind address
localAddress
)

Configure the address that will be used to bind too.

public DnsNameResolverBuilder

Returns:

this
maxPayloadSize
(int
the capacity of the datagram packet buffer
maxPayloadSize
)

Sets the capacity of the datagram packet buffer (in bytes).

public DnsNameResolverBuilder

Returns:

this
maxQueriesPerResolve
(int
the max number of queries
maxQueriesPerResolve
)

Sets the maximum allowed number of DNS queries to send when resolving a host name.

protected DnsServerAddressStreamProvider
public DnsNameResolverBuilder

Returns:

this.
nameServerProvider
(DnsServerAddressStreamProvider dnsServerAddressStreamProvider)

Set the DnsServerAddressStreamProvider which is used to determine which DNS server is used to resolve each hostname.

public DnsNameResolverBuilder

Returns:

this
ndots
(int
the ndots value
ndots
)

Set the number of dots which must appear in a name before an initial absolute query is made.

public DnsNameResolverBuilder

Returns:

this
negativeTtl
(int
the TTL for failed cached queries
negativeTtl
)

Sets the TTL of the cache for the failed DNS queries (in seconds).

private AuthoritativeDnsServerCache
private DnsCache
private DnsCnameCache
public DnsNameResolverBuilder

Returns:

this
optResourceEnabled
(boolean
if optional records inclusion is enabled
optResourceEnabled
)

Enable the automatic inclusion of a optional records that tries to give the remote DNS server a hint about how much data the resolver can read per response.

public DnsNameResolverBuilder

Returns:

this
queryTimeoutMillis
(long
the query timeout
queryTimeoutMillis
)

Sets the timeout of each DNS query performed by this resolver (in milliseconds).

public DnsNameResolverBuilder

Returns:

this
recursionDesired
(boolean
true if recursion is desired
recursionDesired
)

Sets if this resolver has to send a DNS query with the RD (recursion desired) flag set.

public DnsNameResolverBuilder

Returns:

this
resolveCache
(DnsCache
the DNS resolution results cache
resolveCache
)

Sets the cache for resolution results.

public DnsNameResolverBuilder

Returns:

this
resolvedAddressTypes
(ResolvedAddressTypes
the address types
resolvedAddressTypes
)

Sets the list of the protocol families of the address resolved.

public DnsNameResolverBuilder

Returns:

this
searchDomains
(Iterable<String>
the search domains
searchDomains
)

Set the list of search domains of the resolver.

public DnsNameResolverBuilder

Returns:

this
socketChannelFactory
(ChannelFactory<? extends SocketChannel>
the ChannelFactory or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.
channelFactory
)

Deprecated as a consequence of ChannelFactory being deprecated.
Sets the ChannelFactory that will create a SocketChannel for TCP fallback if needed.
public DnsNameResolverBuilder

Returns:

this
socketChannelFactory
(ChannelFactory<? extends SocketChannel>
the ChannelFactory or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.
channelFactory
,
boolean
if true the DnsNameResolver will also fallback to TCP if a timeout was detected, if false it will only try to use TCP if the response was marked as truncated.
retryOnTimeout
)

Deprecated as a consequence of ChannelFactory being deprecated.
Sets the ChannelFactory that will create a SocketChannel for TCP fallback if needed.
public DnsNameResolverBuilder

Returns:

this
socketChannelType
(Class<? extends SocketChannel>
the type or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.
channelType
)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type for TCP fallback if needed.

public DnsNameResolverBuilder

Returns:

this
socketChannelType
(Class<? extends SocketChannel>
the type or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.
channelType
,
boolean
if true the DnsNameResolver will also fallback to TCP if a timeout was detected, if false it will only try to use TCP if the response was marked as truncated.
retryOnTimeout
)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type for TCP fallback if needed.

public DnsNameResolverBuilder

Returns:

this
traceEnabled
(boolean
true if trace is enabled
traceEnabled
)

Deprecated Prefer to configure a LoggingDnsQueryLifeCycleObserverFactory instead.
Sets if this resolver should generate the detailed trace information in an exception message so that it is easier to understand the cause of resolution failure.
public DnsNameResolverBuilder

Returns:

this
ttl
(int
the minimum TTL
minTtl
,
int
the maximum TTL
maxTtl
)

Sets the minimum and maximum TTL of the cached DNS resource records (in seconds).

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

authoritativeDnsServerCacheback to summary
private AuthoritativeDnsServerCache authoritativeDnsServerCache
channelFactoryback to summary
private ChannelFactory<? extends DatagramChannel> channelFactory

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

cnameCacheback to summary
private DnsCnameCache cnameCache
completeOncePreferredResolvedback to summary
private boolean completeOncePreferredResolved
decodeIdnback to summary
private boolean decodeIdn
dnsQueryLifecycleObserverFactoryback to summary
private DnsQueryLifecycleObserverFactory dnsQueryLifecycleObserverFactory
dnsServerAddressStreamProviderback to summary
private DnsServerAddressStreamProvider dnsServerAddressStreamProvider
eventLoopback to summary
pack-priv volatile EventLoop eventLoop
hostsFileEntriesResolverback to summary
private HostsFileEntriesResolver hostsFileEntriesResolver
localAddressback to summary
private SocketAddress localAddress
loggerback to summary
private static final InternalLogger logger
maxNumConsolidationback to summary
private int maxNumConsolidation
maxPayloadSizeback to summary
private int maxPayloadSize
maxQueriesPerResolveback to summary
private int maxQueriesPerResolve
maxTtlback to summary
private Integer maxTtl
minTtlback to summary
private Integer minTtl
ndotsback to summary
private int ndots
negativeTtlback to summary
private Integer negativeTtl
optResourceEnabledback to summary
private boolean optResourceEnabled
queryTimeoutMillisback to summary
private long queryTimeoutMillis
recursionDesiredback to summary
private boolean recursionDesired
resolveCacheback to summary
private DnsCache resolveCache
resolvedAddressTypesback to summary
private ResolvedAddressTypes resolvedAddressTypes
retryOnTimeoutback to summary
private boolean retryOnTimeout
searchDomainsback to summary
private String[] searchDomains
socketChannelFactoryback to summary
private ChannelFactory<? extends SocketChannel> socketChannelFactory

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

traceEnabledback to summary
private boolean traceEnabled

Constructor Detail

DnsNameResolverBuilderback to summary
public DnsNameResolverBuilder()

Creates a new builder.

DnsNameResolverBuilderback to summary
public DnsNameResolverBuilder(EventLoop eventLoop)

Creates a new builder.

Parameters
eventLoop:EventLoop

the EventLoop which will perform the communication with the DNS servers.

Method Detail

authoritativeDnsServerCacheback to summary
public DnsNameResolverBuilder authoritativeDnsServerCache(DnsCache authoritativeDnsServerCache)

Sets the cache for authoritative NS servers

Parameters
authoritativeDnsServerCache:DnsCache

the authoritative NS servers cache

Returns:DnsNameResolverBuilder

this

Annotations
@Deprecated
authoritativeDnsServerCacheback to summary
public DnsNameResolverBuilder authoritativeDnsServerCache(AuthoritativeDnsServerCache authoritativeDnsServerCache)

Sets the cache for authoritative NS servers

Parameters
authoritativeDnsServerCache:AuthoritativeDnsServerCache

the authoritative NS servers cache

Returns:DnsNameResolverBuilder

this

buildback to summary
public DnsNameResolver build()

Returns a new DnsNameResolver instance.

Returns:DnsNameResolver

a DnsNameResolver

channelFactoryback to summary
protected ChannelFactory<? extends DatagramChannel> channelFactory()

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

channelFactoryback to summary
public DnsNameResolverBuilder channelFactory(ChannelFactory<? extends DatagramChannel> channelFactory)

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

Sets the ChannelFactory that will create a DatagramChannel. If TCP fallback should be supported as well it is required to call the or socketChannelType(Class) method.

Parameters
channelFactory:ChannelFactory<? extends DatagramChannel>

the ChannelFactory

Returns:DnsNameResolverBuilder

this

channelTypeback to summary
public DnsNameResolverBuilder channelType(Class<? extends DatagramChannel> channelType)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type. Use as an alternative to channelFactory(ChannelFactory). If TCP fallback should be supported as well it is required to call the or socketChannelType(Class) method.

Parameters
channelType:Class<? extends DatagramChannel>

the type

Returns:DnsNameResolverBuilder

this

cnameCacheback to summary
public DnsNameResolverBuilder cnameCache(DnsCnameCache cnameCache)

Sets the cache for CNAME mappings.

Parameters
cnameCache:DnsCnameCache

the cache used to cache CNAME mappings for a domain.

Returns:DnsNameResolverBuilder

this

completeOncePreferredResolvedback to summary
public DnsNameResolverBuilder completeOncePreferredResolved(boolean completeOncePreferredResolved)

If true DnsNameResolver#resolveAll(String) will notify the returned Future as soon as all queries for the preferred address-type are complete.

Parameters
completeOncePreferredResolved:boolean

true to enable, false to disable.

Returns:DnsNameResolverBuilder

this

computeResolvedAddressTypesback to summary
public static ResolvedAddressTypes computeResolvedAddressTypes(InternetProtocolFamily... internetProtocolFamilies)

Compute a ResolvedAddressTypes from some InternetProtocolFamilys. An empty input will return the default value, based on "java.net" System properties. Valid inputs are (), (IPv4), (IPv6), (Ipv4, IPv6) and (IPv6, IPv4).

Parameters
internetProtocolFamilies:InternetProtocolFamily[]

a valid sequence of InternetProtocolFamilys

Returns:ResolvedAddressTypes

a ResolvedAddressTypes

consolidateCacheSizeback to summary
public DnsNameResolverBuilder consolidateCacheSize(int maxNumConsolidation)

Set the maximum size of the cache that is used to consolidate lookups for different hostnames when in-flight. This means if multiple lookups are done for the same hostname and still in-flight only one actual query will be made and the result will be cascaded to the others.

Parameters
maxNumConsolidation:int

the maximum lookups to consolidate (different hostnames), or 0 if no consolidation should be performed.

Returns:DnsNameResolverBuilder

this

copyback to summary
public DnsNameResolverBuilder copy()

Creates a copy of this DnsNameResolverBuilder

Returns:DnsNameResolverBuilder

DnsNameResolverBuilder

decodeIdnback to summary
public DnsNameResolverBuilder decodeIdn(boolean decodeIdn)

Set if domain / host names should be decoded to unicode when received. See rfc3492.

Parameters
decodeIdn:boolean

if should get decoded

Returns:DnsNameResolverBuilder

this

dnsQueryLifecycleObserverFactoryback to summary
public DnsNameResolverBuilder dnsQueryLifecycleObserverFactory(DnsQueryLifecycleObserverFactory lifecycleObserverFactory)

Set the factory used to generate objects which can observe individual DNS queries.

Parameters
lifecycleObserverFactory:DnsQueryLifecycleObserverFactory

the factory used to generate objects which can observe individual DNS queries.

Returns:DnsNameResolverBuilder

this

eventLoopback to summary
public DnsNameResolverBuilder eventLoop(EventLoop eventLoop)

Sets the EventLoop which will perform the communication with the DNS servers.

Parameters
eventLoop:EventLoop

the EventLoop

Returns:DnsNameResolverBuilder

this

hostsFileEntriesResolverback to summary
public DnsNameResolverBuilder hostsFileEntriesResolver(HostsFileEntriesResolver hostsFileEntriesResolver)
Parameters
hostsFileEntriesResolver:HostsFileEntriesResolver

the HostsFileEntriesResolver used to first check if the hostname is locally aliased.

Returns:DnsNameResolverBuilder

this

localAddressback to summary
public DnsNameResolverBuilder localAddress(SocketAddress localAddress)

Configure the address that will be used to bind too. If null the default will be used.

Parameters
localAddress:SocketAddress

the bind address

Returns:DnsNameResolverBuilder

this

maxPayloadSizeback to summary
public DnsNameResolverBuilder maxPayloadSize(int maxPayloadSize)

Sets the capacity of the datagram packet buffer (in bytes). The default value is 4096 bytes.

Parameters
maxPayloadSize:int

the capacity of the datagram packet buffer

Returns:DnsNameResolverBuilder

this

maxQueriesPerResolveback to summary
public DnsNameResolverBuilder maxQueriesPerResolve(int maxQueriesPerResolve)

Sets the maximum allowed number of DNS queries to send when resolving a host name.

Parameters
maxQueriesPerResolve:int

the max number of queries

Returns:DnsNameResolverBuilder

this

nameServerProviderback to summary
protected DnsServerAddressStreamProvider nameServerProvider()
nameServerProviderback to summary
public DnsNameResolverBuilder nameServerProvider(DnsServerAddressStreamProvider dnsServerAddressStreamProvider)

Set the DnsServerAddressStreamProvider which is used to determine which DNS server is used to resolve each hostname.

Returns:DnsNameResolverBuilder

this.

ndotsback to summary
public DnsNameResolverBuilder ndots(int ndots)

Set the number of dots which must appear in a name before an initial absolute query is made. The default value is 1.

Parameters
ndots:int

the ndots value

Returns:DnsNameResolverBuilder

this

negativeTtlback to summary
public DnsNameResolverBuilder negativeTtl(int negativeTtl)

Sets the TTL of the cache for the failed DNS queries (in seconds).

Parameters
negativeTtl:int

the TTL for failed cached queries

Returns:DnsNameResolverBuilder

this

newAuthoritativeDnsServerCacheback to summary
private AuthoritativeDnsServerCache newAuthoritativeDnsServerCache()
newCacheback to summary
private DnsCache newCache()
newCnameCacheback to summary
private DnsCnameCache newCnameCache()
optResourceEnabledback to summary
public DnsNameResolverBuilder optResourceEnabled(boolean optResourceEnabled)

Enable the automatic inclusion of a optional records that tries to give the remote DNS server a hint about how much data the resolver can read per response. Some DNSServer may not support this and so fail to answer queries. If you find problems you may want to disable this.

Parameters
optResourceEnabled:boolean

if optional records inclusion is enabled

Returns:DnsNameResolverBuilder

this

queryTimeoutMillisback to summary
public DnsNameResolverBuilder queryTimeoutMillis(long queryTimeoutMillis)

Sets the timeout of each DNS query performed by this resolver (in milliseconds). 0 disables the timeout. If not set or a negative number is set, the default timeout is used.

Parameters
queryTimeoutMillis:long

the query timeout

Returns:DnsNameResolverBuilder

this

recursionDesiredback to summary
public DnsNameResolverBuilder recursionDesired(boolean recursionDesired)

Sets if this resolver has to send a DNS query with the RD (recursion desired) flag set.

Parameters
recursionDesired:boolean

true if recursion is desired

Returns:DnsNameResolverBuilder

this

resolveCacheback to summary
public DnsNameResolverBuilder resolveCache(DnsCache resolveCache)

Sets the cache for resolution results.

Parameters
resolveCache:DnsCache

the DNS resolution results cache

Returns:DnsNameResolverBuilder

this

resolvedAddressTypesback to summary
public DnsNameResolverBuilder resolvedAddressTypes(ResolvedAddressTypes resolvedAddressTypes)

Sets the list of the protocol families of the address resolved. You can use DnsNameResolverBuilder#computeResolvedAddressTypes(InternetProtocolFamily...) to get a ResolvedAddressTypes out of some InternetProtocolFamilys.

Parameters
resolvedAddressTypes:ResolvedAddressTypes

the address types

Returns:DnsNameResolverBuilder

this

searchDomainsback to summary
public DnsNameResolverBuilder searchDomains(Iterable<String> searchDomains)

Set the list of search domains of the resolver.

Parameters
searchDomains:Iterable<String>

the search domains

Returns:DnsNameResolverBuilder

this

socketChannelFactoryback to summary
public DnsNameResolverBuilder socketChannelFactory(ChannelFactory<? extends SocketChannel> channelFactory)

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

Sets the ChannelFactory that will create a SocketChannel for TCP fallback if needed. TCP fallback is not enabled by default and must be enabled by providing a non-null ChannelFactory for this method.

Parameters
channelFactory:ChannelFactory<? extends SocketChannel>

the ChannelFactory or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.

Returns:DnsNameResolverBuilder

this

socketChannelFactoryback to summary
public DnsNameResolverBuilder socketChannelFactory(ChannelFactory<? extends SocketChannel> channelFactory, boolean retryOnTimeout)

Deprecated

as a consequence of ChannelFactory being deprecated. See corresponding docs for further information.

Sets the ChannelFactory that will create a SocketChannel for TCP fallback if needed. TCP fallback is not enabled by default and must be enabled by providing a non-null ChannelFactory for this method.

Parameters
channelFactory:ChannelFactory<? extends SocketChannel>

the ChannelFactory or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.

retryOnTimeout:boolean

if true the DnsNameResolver will also fallback to TCP if a timeout was detected, if false it will only try to use TCP if the response was marked as truncated.

Returns:DnsNameResolverBuilder

this

socketChannelTypeback to summary
public DnsNameResolverBuilder socketChannelType(Class<? extends SocketChannel> channelType)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type for TCP fallback if needed. Use as an alternative to socketChannelFactory(ChannelFactory). TCP fallback is not enabled by default and must be enabled by providing a non-null channelType for this method.

Parameters
channelType:Class<? extends SocketChannel>

the type or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.

Returns:DnsNameResolverBuilder

this

socketChannelTypeback to summary
public DnsNameResolverBuilder socketChannelType(Class<? extends SocketChannel> channelType, boolean retryOnTimeout)

Sets the ChannelFactory as a ReflectiveChannelFactory of this type for TCP fallback if needed. Use as an alternative to socketChannelFactory(ChannelFactory). TCP fallback is not enabled by default and must be enabled by providing a non-null channelType for this method.

Parameters
channelType:Class<? extends SocketChannel>

the type or null if TCP fallback should not be supported. By default, TCP fallback is not enabled.

retryOnTimeout:boolean

if true the DnsNameResolver will also fallback to TCP if a timeout was detected, if false it will only try to use TCP if the response was marked as truncated.

Returns:DnsNameResolverBuilder

this

traceEnabledback to summary
public DnsNameResolverBuilder traceEnabled(boolean traceEnabled)

Deprecated

Prefer to configure a LoggingDnsQueryLifeCycleObserverFactory instead.

Sets if this resolver should generate the detailed trace information in an exception message so that it is easier to understand the cause of resolution failure.

Parameters
traceEnabled:boolean

true if trace is enabled

Returns:DnsNameResolverBuilder

this

Annotations
@Deprecated
ttlback to summary
public DnsNameResolverBuilder ttl(int minTtl, int maxTtl)

Sets the minimum and maximum TTL of the cached DNS resource records (in seconds). If the TTL of the DNS resource record returned by the DNS server is less than the minimum TTL or greater than the maximum TTL, this resolver will ignore the TTL from the DNS server and use the minimum TTL or the maximum TTL instead respectively. The default value is 0 and Integer#MAX_VALUE, which practically tells this resolver to respect the TTL from the DNS server.

Parameters
minTtl:int

the minimum TTL

maxTtl:int

the maximum TTL

Returns:DnsNameResolverBuilder

this