this was previously only done in ns_client_endrequest(), which is
called by client_reset_cb() when a client is released. this could
make the system report more recursive clients than were actually
recursing, and caused intermittent test failures in 'fetchlimit'.
this supercedes the experiment in commit eab6c2bff
("attach to nmhandle during zerottl refetch"), and ensures that
the client can't be reset before fetch_callback() is reached.
- MSVC doesn't like empty {} initializers
- Emulate stdalign.h on Windows with __declspec(align())
- There's no usleep on Windows
- Add missing symbols to libns.def and libisc.def
- Proper use of SO_REUSE****
- libuv detection in Configure
- Minor fixes to the atomics code
- when we attempt to shut down a parent socket, but its children
still have active handles, the destruction is delayed, and previously
it was never resumed. now, when the last handle for a child socket is
detached, we check again whether the parent can be destroyed.
- the netmgr is not shut down until all references to it are detached.
- document functions in netmgr.h and netmgr-int.h
- combine identical callback typedefs into one
- remove functions that were never called
- make functions called in only one file static
- rename isc__nm_handle_*() functions to isc__nm_async_*() to avoid
confusion with the isc__nmhandle type.
- clean up isc_nmevent structures - make generic types and just typedef to them
- fix atomic clang warnings in astack
- add pause/resume read for TCP
- add sequential (not-pipelining) support for TCPDNS
- keep peer address in the socket for TCP connections, it's constant for a socket
this delays the destruction of the client object until after the
prefetch is finished.
also added some missing CTRACE logging in query.c, in the process of
diagnosing this error.
- add reference counters to manager; all client objects attach and
detach from the manager
- ensure that when a client object is detached, if references have gone
to zero, the associated nmhandle object is detached. this should
trigger the freeing of both the nmhandle object and the client object
- as client objects are now allocated along with network manager clients
and will be accounted for by the network manager, there's no longer a
need to call exit_check(). its functions are now replaced by the
nmhandle reset and put callbacks.
- there is no need to keep a 'clients' list in ns_clientmgr()
- (however, TODO, the client manager should now be reference counted)
- added some logging to show when clients are allocated, reset, or freed
- ns_client_next() has no remaining function except to log the reason
for a failure. its name has therefore been changed to ns_client_drop().
- Start netmgr with named, shutdown at the end
- udplistener in interfacemgr uses netmgr
- use per-client buffer for udp send
- first steps at making ns_client_request use netmgr for UDP
- uncrustify
- Make interfacemgr and interface references isc_refcount_t instead of locked ints
- Use clock_gettime instead of gettimeofday
- Cleanup get_client, use one interface for clientmgr instead of attaching it to each client
- 'extra' field at the end of handle - for client data
- clientmgr has a taskpool, clients attach to it
- TCP support