Skip to content
Snippets Groups Projects
Commit 3b5b0f64 authored by Jonathan Hoppe's avatar Jonathan Hoppe Committed by Jan Kadlec
Browse files

Allow for timeouts when scheduling zone expire.


Increase the expire time for zones with very short expiry. Without
this a zone may expire if there is a timeout, and once it has expired
it won't be served until it is refreshed. Sometimes, customers load
zones with SOA values that we have little control over.

Signed-off-by: default avatarJan Kadlec <jan.kadlec@nic.cz>
parent 2ee1653b
No related branches found
No related tags found
No related merge requests found
......@@ -252,6 +252,9 @@ int zones_refresh_ev(event_t *e)
/* Schedule EXPIRE timer on first attempt. */
if (!zd->xfr_in.expire) {
uint32_t expire_tmr = zones_jitter(zones_soa_expire(zone));
// Allow for timeouts. Otherwise zones with very short
// expiry may expire before the timeout is reached.
expire_tmr += 2 * (conf()->max_conn_idle * 1000);
zd->xfr_in.expire = evsched_schedule_cb(
e->parent,
zones_expire_ev,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment