]> git.ipfire.org Git - thirdparty/pdns.git/commit
Tell packet cache it's max size and use it on insert to immediately
authorOtto Moerbeek <otto@drijf.net>
Sun, 6 Feb 2022 14:38:48 +0000 (15:38 +0100)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Fri, 1 Apr 2022 08:08:53 +0000 (10:08 +0200)
commiteeab0dc2bfd93649bc4fa8f995ee9e7da9a86503
tree7283ac060bc20a3450245db8df3eee7568d0c409
parent5abc5e10c037764d2da5f3b8977a73bd58644e14
Tell packet cache it's max size and use it on insert to immediately
delete the oldest entry when we're over-sized.

Also, if we're seeing a stale cache item, don't move it to the front
of the sequence, as we're almost always going to update it and then
it will be moved again to the back.
pdns/cachecleaner.hh
pdns/recpacketcache.cc
pdns/recpacketcache.hh
pdns/recursordist/rec-main.cc
pdns/test-recpacketcache_cc.cc