]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
auth: replace domain-metadata-cache-ttl by zone-metadata-cache-ttl
authorKees Monshouwer <mind04@monshouwer.org>
Tue, 18 May 2021 16:44:20 +0000 (18:44 +0200)
committermind04 <mind04@monshouwer.org>
Wed, 19 May 2021 10:59:19 +0000 (12:59 +0200)
docs/settings.rst
docs/upgrading.rst
pdns/common_startup.cc
pdns/dbdnsseckeeper.cc
pdns/pdnsutil.cc
pdns/receiver.cc

index 6d84e346c56b7eb0ea78aac4a7a852e9c334df1a..6db781e07a5c593caca8ea2a3446da86f662fa38 100644 (file)
@@ -613,8 +613,8 @@ ADDITIONAL section when sending a referral.
 ``domain-metadata-cache-ttl``
 -----------------------------
 
--  Integer
--  Default: 60
+.. deprecated:: 4.5.0
+  Renamed to :ref:`setting-zone-metadata-cache-ttl`.
 
 Seconds to cache domain metadata from the database. A value of 0
 disables caching.
@@ -1896,3 +1896,17 @@ means no restriction.
 Seconds to cache a list of all known zones. A value of 0 will disable the cache.
 
 If your backends do not respond to unknown or dynamically generated zones, it is suggested to enable :ref:`setting-consistent-backends` and set this option to `60`.
+
+.. _setting-zone-metadata-cache-ttl:
+
+``zone-metadata-cache-ttl``
+-----------------------------
+
+.. versionchanged:: 4.5.0
+  This was called :ref:`setting-domain-metadata-cache-ttl` before 4.5.0.
+
+-  Integer
+-  Default: 60
+
+Seconds to cache zone metadata from the database. A value of 0
+disables caching.
index 6db6861a3b50ce3624e51ff4904f367dee11bfc5..fa9268a5c94772b31d00eaa068f98ced9b398470 100644 (file)
@@ -35,6 +35,7 @@ Their old names still work in 4.5.x, but will be removed in the release after it
 * :ref:`setting-slave-renotify` is now :ref:`setting-secondary-do-renotify`
 * :ref:`setting-slave` is now :ref:`setting-secondary`
 * :ref:`setting-superslave` is now :ref:`setting-autosecondary`
+* :ref:`setting-domain-metadata-cache-ttl` is now :ref:`setting-zone-metadata-ttl`
 
 Changed defaults
 ~~~~~~~~~~~~~~~~
index d6ea575777eed0b7c7a6f897f898e0e9187622bc..3b07d53517d49bc972e4f217e021ddb12f847584 100644 (file)
@@ -187,7 +187,8 @@ void declareArguments()
   ::arg().set("default-soa-edit","Default SOA-EDIT value")="";
   ::arg().set("default-soa-edit-signed","Default SOA-EDIT value for signed zones")="";
   ::arg().set("dnssec-key-cache-ttl","Seconds to cache DNSSEC keys from the database")="30";
-  ::arg().set("domain-metadata-cache-ttl","Seconds to cache domain metadata from the database")="60";
+  ::arg().set("domain-metadata-cache-ttl", "Seconds to cache zone metadata from the database") = "0";
+  ::arg().set("zone-metadata-cache-ttl", "Seconds to cache zone metadata from the database") = "60";
 
   ::arg().set("trusted-notification-proxy", "IP address of incoming notification proxy")="";
   ::arg().set("slave-renotify", "If we should send out notifications for secondaried updates")="no";
index ebe7bd1b0a935da6e78883e6a9a755003a809134..a06846b54b370a75a8e3d514c4569d860a6c3749 100644 (file)
@@ -230,7 +230,7 @@ bool DNSSECKeeper::getFromMeta(const DNSName& zname, const std::string& key, std
     d_metaUpdate=false;
   }
 
-  static int ttl = ::arg().asNum("domain-metadata-cache-ttl");
+  static int ttl = ::arg().asNum("zone-metadata-cache-ttl");
 
   if(!((++s_ops) % 100000)) {
     cleanup();
index 8c7d47943c066b9dc459db5f3d4ebdc2666f3ccf..e05ddb3a6068e2889d97f80fe88f956ff3b86db5 100644 (file)
@@ -135,7 +135,8 @@ static void loadMainConfig(const std::string& configdir)
   ::arg().set("default-soa-content","Default SOA content")="a.misconfigured.dns.server.invalid hostmaster.@ 0 10800 3600 604800 3600";
   ::arg().set("chroot","Switch to this chroot jail")="";
   ::arg().set("dnssec-key-cache-ttl","Seconds to cache DNSSEC keys from the database")="30";
-  ::arg().set("domain-metadata-cache-ttl","Seconds to cache domain metadata from the database")="60";
+  ::arg().set("domain-metadata-cache-ttl", "Seconds to cache zone metadata from the database") = "0";
+  ::arg().set("zone-metadata-cache-ttl", "Seconds to cache zone metadata from the database") = "60";
   ::arg().set("consistent-backends", "Assume individual domains are not divided over backends. Send only ANY lookup operations to the backend to reduce the number of lookups")="yes";
 
   // Keep this line below all ::arg().set() statements
index 545117eff5fc077224f8af448755206aeb76ab04..178f1bef80b69bf7dbdde52e372fb14433c22a93 100644 (file)
@@ -432,6 +432,8 @@ int main(int argc, char **argv)
     if (::arg().mustDo("slave-renotify")) ::arg().set("secondary-do-renotify")="yes";
     if (::arg().mustDo("superslave")) ::arg().set("autosecondary")="yes";
     if (::arg().mustDo("allow-unsigned-supermaster")) ::arg().set("allow-unsigned-autoprimary")="yes";
+    if (::arg().asNum("domain-metadata-cache-ttl"))
+      ::arg().set("zone-metadata-cache-ttl") = ::arg()["domain-metadata-cache-ttl"];
 
     // this mirroring back is on purpose, so that config dumps reflect the actual setting on both names
     if (::arg().mustDo("primary")) ::arg().set("master")="yes";
@@ -439,6 +441,8 @@ int main(int argc, char **argv)
     if (::arg().mustDo("secondary-do-renotify")) ::arg().set("slave-renotify")="yes";
     if (::arg().mustDo("autosecondary")) ::arg().set("superslave")="yes";
     if (::arg().mustDo("allow-unsigned-autoprimary")) ::arg().set("allow-unsigned-supermaster")="yes";
+    if (::arg().asNum("zone-metadata-cache-ttl"))
+      ::arg().set("domain-metadata-cache-ttl") = ::arg()["zone-metadata-cache-ttl"];
 
     g_log.setLoglevel((Logger::Urgency)(::arg().asNum("loglevel")));
     g_log.disableSyslog(::arg().mustDo("disable-syslog"));