]> git.ipfire.org Git - thirdparty/dovecot/core.git/commit
lib-dns: Add caching to dns client
authorAki Tuomi <aki.tuomi@open-xchange.com>
Fri, 10 Sep 2021 06:52:28 +0000 (09:52 +0300)
committerAki Tuomi <aki.tuomi@open-xchange.com>
Mon, 17 Jan 2022 11:52:09 +0000 (13:52 +0200)
commit47f44374201e83ade6204bb237b163fbd066134a
tree11a6ae6a7e0db694826410464ccc8bf95d3b26ad
parentbc6615a0ca2cbef9f145d1bde0979e63eaf8b62d
lib-dns: Add caching to dns client

Caching can be used with the client API. Setting cache_ttl_secs
to a suitable value will cache the entries for given seconds.
Entries are refreshed if looked up after half the ttl has elapsed.
src/lib-dns/dns-lookup.c
src/lib-dns/dns-lookup.h
src/lib-dns/test-dns-lookup.c