Lower the timeout for each DNS resolution attempt

This commit is contained in:
Florent Le Coz 2014-11-14 01:13:52 +01:00
parent 3c06568ed5
commit 5fcf08a415

View file

@ -39,7 +39,9 @@ def default_resolver():
is available. Otherwise, ``None``. is available. Otherwise, ``None``.
""" """
if AIODNS_AVAILABLE: if AIODNS_AVAILABLE:
return aiodns.DNSResolver(loop=asyncio.get_event_loop()) return aiodns.DNSResolver(loop=asyncio.get_event_loop(),
tries=1,
timeout=1.0)
return None return None