Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dnsdist: Add a negative TTL option to the packet cache #6740

merged 2 commits into from Jun 21, 2018


Copy link

Short description

So it's possible to cap the TTL of NODATA and NXDOMAIN answers.
Also fixes a bug in the editTTLs() feature, where the wrong section was passed to the callback.

Closes #6579.


I have:

  • read the document
  • compiled this code
  • tested this code
  • included documentation (including possible behaviour changes)
  • documented the code
  • added or modified regression test(s)
  • added or modified unit test(s)

@rgacogne rgacogne added this to the dnsdist-1.3.x milestone Jun 14, 2018
@pieterlexis pieterlexis merged commit d64f1bd into PowerDNS:master Jun 21, 2018
@rgacogne rgacogne deleted the dnsdist-packetcache-neg-ttl branch June 21, 2018 15:47
@@ -521,6 +524,7 @@ See :doc:`../guides/cache` for a how to.
:param bool dontAge: Don't reduce TTLs when serving from the cache. Use this when :program:`dnsdist` fronts a cluster of authoritative servers
:param int numberOfShards: Number of shards to divide the cache into, to reduce lock contention
:param bool deferrableInsertLock: Whether the cache should give up insertion if the lock is held by another thread, or simply wait to get the lock
:param bool maxNegativeTTL: Cache a NXDomain or NoData answer from the backend for at most this amount of seconds, even if the TTL of the SOA record is higher
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think this param must be an int not a bool just doc ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

Successfully merging this pull request may close these issues.

dnsdist: max-negative-ttl setting for PacketCache
3 participants