aboutsummaryrefslogtreecommitdiff
path: root/contrib/unbound/daemon/worker.h
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/unbound/daemon/worker.h')
-rw-r--r--contrib/unbound/daemon/worker.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/contrib/unbound/daemon/worker.h b/contrib/unbound/daemon/worker.h
index 3887d0405ae6..b7bb52fd715b 100644
--- a/contrib/unbound/daemon/worker.h
+++ b/contrib/unbound/daemon/worker.h
@@ -72,7 +72,13 @@ enum worker_commands {
/** obtain statistics without statsclear */
worker_cmd_stats_noreset,
/** execute remote control command */
- worker_cmd_remote
+ worker_cmd_remote,
+ /** for fast-reload, perform stop */
+ worker_cmd_reload_stop,
+ /** for fast-reload, start again */
+ worker_cmd_reload_start,
+ /** for fast-reload, poll to make sure worker has released data */
+ worker_cmd_reload_poll
};
/**
@@ -86,6 +92,10 @@ struct worker {
struct daemon* daemon;
/** thread id */
ub_thread_type thr_id;
+#ifdef HAVE_GETTID
+ /** thread tid, the LWP id. */
+ pid_t thread_tid;
+#endif
/** pipe, for commands for this worker */
struct tube* cmd;
/** the event base this worker works with */
@@ -114,7 +124,7 @@ struct worker {
/** do we need to restart or quit (on signal) */
int need_to_exit;
/** allocation cache for this thread */
- struct alloc_cache alloc;
+ struct alloc_cache *alloc;
/** per thread statistics */
struct ub_server_stats stats;
/** thread scratch regional */
@@ -127,6 +137,8 @@ struct worker {
/** dnstap environment, changed for this thread */
struct dt_env dtenv;
#endif
+ /** reuse existing cache on reload if other conditions allow it. */
+ int reuse_cache;
};
/**