[Mirror] Some kind of OS: git://git.9front.org/plan9front/plan9front
Find a file
cinap_lenrek 69e9efa847 ndb/dns: avoid blocking 9p on refresh, use shorter 15second query timeout, cleanup
When writing "refresh" control message to trigger
garbage collection and there are other (query) processes active,
the 9p loop would block until these processes complete.

Instead, defer the garbage collection operation to these
outstanding processes once any of them completes,
keeping the 9p loop un-contended for longer.

When theres no other processes, we can garbage collect
ourselfs immediately (just as before).

Only acquire the dnvars lock on Twrite, so we can handle
other 9p requests while garbage collection is going on.

Also reduce the 60 second timeout to 15 second for queries.
Other dns servers usually use something between 10 and 30
seconds.

Avoid excessive nsec() and time() calls by having timems()
function that only uses nsec() and then updates global
nowms (millisecons) and now (seconds) variable.

After the end of readnet(), timems() needs to be called
anyway to update the query statistics so we can use that
as the new "now".
2023-10-15 21:20:30 +00:00
386 ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
68000 add signed fixed size integer typedefs 2018-05-12 19:19:52 +02:00
68020 ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
acme mkfiles: add 'mk test' support 2023-02-19 20:44:56 -05:00
adm/timezone timezones: change DST timezone string for South Australia 2019-11-20 11:49:16 +10:30
amd64 libc: change usize to 64-bit for amd64 and arm64, make memory(2) functions use usize 2021-07-25 15:54:22 +00:00
arm ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
arm64 libc: change usize to 64-bit for amd64 and arm64, make memory(2) functions use usize 2021-07-25 15:54:22 +00:00
lib grabrfc: update fetching 2023-10-10 03:16:04 +00:00
mips ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
power ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
power64 add signed fixed size integer typedefs 2018-05-12 19:19:52 +02:00
rc cpurc, termrc, bootrc: organize default device binds 2023-10-14 17:12:05 +00:00
sparc ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
sparc64 ape: sync flaot.h macros with u.h 2021-02-08 15:45:11 -08:00
spim /spim/include/ape/ureg.h: fixed missing ifndef 2023-03-07 04:26:34 +00:00
sys ndb/dns: avoid blocking 9p on refresh, use shorter 15second query timeout, cleanup 2023-10-15 21:20:30 +00:00