bind9/lib
Ondřej Surý dacf586e18 Make the netmgr queue processing quantized
There was a theoretical possibility of clogging up the queue processing
with an endless loop where currently processing netievent would schedule
new netievent that would get processed immediately.  This wasn't such a
problem when only netmgr netievents were processed, but with the
addition of the tasks, there are at least two situation where this could
happen:

 1. In lib/dns/zone.c:setnsec3param() the task would get re-enqueued
    when the zone was not yet fully loaded.

 2. Tasks have internal quantum for maximum number of isc_events to be
    processed, when the task quantum is reached, the task would get
    rescheduled and then immediately processed by the netmgr queue
    processing.

As the isc_queue doesn't have a mechanism to atomically move the queue,
this commit adds a mechanism to quantize the queue, so enqueueing new
netievents will never stop processing other uv_loop_t events.
The default quantum size is 128.

Since the queue used in the network manager allows items to be enqueued
more than once, tasks are now reference-counted around task_ready()
and task_run(). task_ready() now has a public API wrapper,
isc_task_ready(), that the netmgr can use to reschedule processing
of a task if the quantum has been reached.

Incidental changes: Cleaned up some unused fields left in isc_task_t
and isc_taskmgr_t after the last refactoring, and changed atomic
flags to atomic_bools for easier manipulation.
2021-05-07 14:28:30 -07:00
..
bind9 Use isdigit instead of checking character range 2021-05-05 19:15:33 +02:00
dns Destroy netmgr before destroying taskmgr 2021-05-07 14:28:30 -07:00
irs Record skipped unit test as skipped in Automake framework 2021-02-15 11:18:03 +01:00
isc Make the netmgr queue processing quantized 2021-05-07 14:28:30 -07:00
isccc Record skipped unit test as skipped in Automake framework 2021-02-15 11:18:03 +01:00
isccfg inline-signing should have been in zone_only_clauses 2021-05-04 23:35:59 +00:00
ns Destroy netmgr before destroying taskmgr 2021-05-07 14:28:30 -07:00
win32/bindevt update all copyright headers to eliminate the typo 2020-09-14 16:20:40 -07:00
.gitignore Provide unit test driver 2020-05-21 12:13:01 +02:00
Makefile.am move samples/resolve.c to bin/tests/system 2021-04-16 14:29:43 +02:00
unit-test-driver.sh.in Enforce a run time limit on unit test binaries 2021-04-07 11:41:45 +02:00