]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Reduce QPDB_VIRTUAL to 10 seconds
authorOndřej Surý <ondrej@isc.org>
Fri, 21 Mar 2025 05:17:55 +0000 (06:17 +0100)
committerOndřej Surý <ondrej@isc.org>
Wed, 16 Apr 2025 09:21:38 +0000 (11:21 +0200)
The *DB_VIRTUAL value was introduced to allow the clients (presumably
ns_clients) that has been running for some time to access the cached
data that was valid at the time of its inception.  The default value
of 5 minutes is way longer than longevity of the ns_client object as
the resolver will give up after 2 minutes.

Reduce the value to 10 seconds to accomodate to honour the original
more closely, but still allow some leeway for clients that started some
time in the past.

Our measurements show that even setting this value to 0 has no
statistically significant effect, thus the value of 10 seconds should be
on the safe side.

lib/dns/qpcache.c

index 3b7f5680b1d95ca3fb92897901264b7723fba214..ab44cf1d36fab4f5fa77cfb1d7c19ff88359f6d6 100644 (file)
 #define HEADERNODE(h) ((qpcnode_t *)((h)->node))
 
 /*
- * Allow clients with a virtual time of up to 5 minutes in the past to see
+ * Allow clients with a virtual time of up to 10 seconds in the past to see
  * records that would have otherwise have expired.
  */
-#define QPDB_VIRTUAL 300
+#define QPDB_VIRTUAL 10
 
 /*
  * This defines the number of headers that we try to expire each time the