mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-02 15:45:25 +00:00
chg: dev: Double the number of threadpool threads
Introduce this temporary workaround to reduce the impact of long-running tasks in offload threads which can block the resolution of queries. Related isc-projects/bind9#4898 Merge branch '4898-workaround-double-threadpool-threads' into 'v9.21.1-release' See merge request isc-private/bind9!740
This commit is contained in:
@@ -308,7 +308,10 @@ threadpool_initialize(uint32_t workers) {
|
|||||||
int r = uv_os_getenv("UV_THREADPOOL_SIZE", buf,
|
int r = uv_os_getenv("UV_THREADPOOL_SIZE", buf,
|
||||||
&(size_t){ sizeof(buf) });
|
&(size_t){ sizeof(buf) });
|
||||||
if (r == UV_ENOENT) {
|
if (r == UV_ENOENT) {
|
||||||
snprintf(buf, sizeof(buf), "%" PRIu32, workers);
|
/* FIXME The number of threadpool threads has been temporarily
|
||||||
|
* doubled to work around the issue [GL #4898] until a proper
|
||||||
|
* solution is implemented. */
|
||||||
|
snprintf(buf, sizeof(buf), "%" PRIu32, 2 * workers);
|
||||||
uv_os_setenv("UV_THREADPOOL_SIZE", buf);
|
uv_os_setenv("UV_THREADPOOL_SIZE", buf);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user