Staging
v0.8.1
https://github.com/python/cpython
Revision d5c2a6210026834eb3cb7165e470d2cbc3065db8 authored by Yury Selivanov on 17 December 2015, 00:31:17 UTC, committed by Yury Selivanov on 17 December 2015, 00:31:17 UTC
getaddrinfo takes an exclusive lock on some platforms, causing clients to queue
up waiting for the lock if many names are being resolved concurrently. Users
may want to handle name resolution in their own code, for the sake of caching,
using an alternate resolver, or to measure DNS duration separately from
connection duration. Skip getaddrinfo if the "host" passed into
create_connection is already resolved.

See https://github.com/python/asyncio/pull/302 for details.

Patch by A. Jesse Jiryu Davis.
1 parent 8c084eb
Raw File
Tip revision: d5c2a6210026834eb3cb7165e470d2cbc3065db8 authored by Yury Selivanov on 17 December 2015, 00:31:17 UTC
asyncio: Skip getaddrinfo if host is already resolved.
Tip revision: d5c2a62
.gitignore
# Two-trick pony for OSX and other case insensitive file systems:
# Ignore ./python binary on Unix but still look into ./Python/ directory.
/python
!/Python/**
*.cover
*.o
*.orig
*.pyc
*.pyd
*.pyo
*.rej
*.swp
*~
.gdb_history
Doc/build/
Doc/tools/docutils/
Doc/tools/jinja/
Doc/tools/jinja2/
Doc/tools/pygments/
Doc/tools/sphinx/
Lib/lib2to3/*.pickle
Lib/test/data/*
Lib/_sysconfigdata.py
Lib/plat-mac/errors.rsrc.df.rsrc
Makefile
Makefile.pre
Misc/python.pc
Misc/python-config.sh
Modules/Setup
Modules/Setup.config
Modules/Setup.local
Modules/config.c
Modules/ld_so_aix
Modules/_freeze_importlib
Modules/_testembed
PCbuild/*.bsc
PCbuild/*.dll
PCbuild/*.exe
PCbuild/*.exp
PCbuild/*.lib
PCbuild/*.ncb
PCbuild/*.o
PCbuild/*.pdb
PCbuild/Win32-temp-*
PCbuild/amd64/
.purify
Parser/pgen
__pycache__
autom4te.cache
build/
buildno
config.cache
config.log
config.status
config.status.lineno
core
db_home
config.log
config.status
libpython*.a
libpython*.so*
platform
pybuilddir.txt
pyconfig.h
python-config
python-config.py
python.exe
python-gdb.py
python.exe-gdb.py
reflog.txt
.svn/
tags
TAGS
.coverage
coverage/
externals/
htmlcov/
back to top