bind9/lib/isc
Ondřej Surý 1d066e4bc5 Distribute queries among threads even on platforms without lb sockets
On platforms without load-balancing socket all the queries would be
handle by a single thread.  Currently, the support for load-balanced
sockets is present in Linux with SO_REUSEPORT and FreeBSD 12 with
SO_REUSEPORT_LB.

This commit adds workaround for such platforms that:

1. setups single shared listening socket for all listening nmthreads for
   UDP, TCP and TCPDNS netmgr transports

2. Calls uv_udp_bind/uv_tcp_bind on the underlying socket just once and
   for rest of the nmthreads only copy the internal libuv flags (should
   be just UV_HANDLE_BOUND and optionally UV_HANDLE_IPV6).

3. start reading on UDP socket or listening on TCP socket

The load distribution among the nmthreads is uneven, but it's still
better than utilizing just one thread for processing all the incoming
queries
2020-12-03 09:20:33 +01:00
..
include Refactor netmgr and add more unit tests 2020-12-01 16:47:07 +01:00
netmgr Distribute queries among threads even on platforms without lb sockets 2020-12-03 09:20:33 +01:00
pthreads update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
tests Add uv_wrap.h to libisctest_la_SOURCES 2020-12-02 16:08:18 +01:00
unix Clean the last remnant of ISC_PLATFORM_HAVEIPV6 macro 2020-10-08 08:28:33 +02:00
win32 Refactor netmgr and add more unit tests 2020-12-01 16:47:07 +01:00
.gitignore [master] update gitignore files; use rev-parse to get srcid 2014-06-17 13:49:30 -07:00
aes.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
api Update library API versions 2020-11-26 12:12:17 +01:00
app.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
assertions.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
astack.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
backtrace.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
base32.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
base64.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
bind9.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
buffer.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
commandline.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
counter.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
crc64.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
entropy.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
entropy_private.h update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
error.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
event.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
fsaccess_common.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
fsaccess_common_p.h update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
glob.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
hash.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
heap.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
hex.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
hmac.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
hp.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
ht.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
httpd.c Fix the isc_nm_closedown() to actually close the pending connections 2020-10-22 11:37:16 -07:00
iterated_hash.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
lex.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
lib.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
log.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
Makefile.am Refactor netmgr and add more unit tests 2020-12-01 16:47:07 +01:00
md.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
mem.c Exclude isc_mem_isovermem from ThreadSanitizer 2020-09-17 13:51:50 +00:00
mem_p.h update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
mutexblock.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
netaddr.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
netscope.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
nonce.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
openssl_shim.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
openssl_shim.h update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
parseint.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
pk11.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
pk11_result.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
pool.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
portset.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
queue.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
quota.c Refactor netmgr and add more unit tests 2020-12-01 16:47:07 +01:00
radix.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
random.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
ratelimiter.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
regex.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
region.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
result.c netmgr: server-side TLS support 2020-11-10 14:16:27 +01:00
rwlock.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
safe.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
serial.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
siphash.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
sockaddr.c netmgr: server-side TLS support 2020-11-10 14:16:27 +01:00
stats.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
string.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
symtab.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
task.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
task_p.h update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
taskpool.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
timer.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
tm.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
utf8.c update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00