bind9/tests
Ondřej Surý fffd444440
Cleanup the asychronous code in the stream implementations
After the loopmgr work has been merged, we can now cleanup the TCP and
TLS protocols a little bit, because there are stronger guarantees that
the sockets will be kept on the respective loops/threads.  We only need
asynchronous call for listening sockets (start, stop) and reading from
the TCP (because the isc_nm_read() might be called from read callback
again.

This commit does the following changes (they are intertwined together):

1. Cleanup most of the asynchronous events in the TCP code, and add
   comments for the events that needs to be kept asynchronous.

2. Remove isc_nm_resumeread() from the netmgr API, and replace
   isc_nm_resumeread() calls with existing isc_nm_read() calls.

3. Remove isc_nm_pauseread() from the netmgr API, and replace
   isc_nm_pauseread() calls with a new isc_nm_read_stop() call.

4. Disable the isc_nm_cancelread() for the streaming protocols, only the
   datagram-like protocols can use isc_nm_cancelread().

5. Add isc_nmhandle_close() that can be used to shutdown the socket
  earlier than after the last detach.  Formerly, the socket would be
  closed only after all reading and sending would be finished and the
  last reference would be detached.  The new isc_nmhandle_close() can
  be used to close the underlying socket earlier, so all the other
  asynchronous calls would call their respective callbacks immediately.

Co-authored-by: Ondřej Surý <ondrej@isc.org>
Co-authored-by: Artem Boldariev <artem@isc.org>
2022-09-22 14:51:15 +02:00
..
bench Use the semantic patch to do the unsigned -> unsigned int change 2022-09-19 15:56:02 +02:00
dns Test TLS transport in dispatch_test.c 2022-09-19 16:36:28 +00:00
include/tests Update netmgr, tasks, and applications to use isc_loopmgr 2022-08-26 09:09:24 +02:00
irs Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
isc Cleanup the asychronous code in the stream implementations 2022-09-22 14:51:15 +02:00
isccfg Update netmgr, tasks, and applications to use isc_loopmgr 2022-08-26 09:09:24 +02:00
libtest Update netmgr, tasks, and applications to use isc_loopmgr 2022-08-26 09:09:24 +02:00
ns Update netmgr, tasks, and applications to use isc_loopmgr 2022-08-26 09:09:24 +02:00
.gitignore Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
Makefile.am Tests and benchmark for isc_ascii 2022-09-12 12:23:39 +01:00
unit-test-driver.sh.in Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00