By default a number of router worker threads is set to a number

of CPUs.
This commit is contained in:
Igor Sysoev
2017-07-05 22:53:29 +03:00
parent 842aa9ab46
commit 4ed0a15cd0

View File

@@ -305,6 +305,10 @@ nxt_router_conf_create(nxt_task_t *task, nxt_router_temp_conf_t *tmcf,
return NXT_ERROR; return NXT_ERROR;
} }
if (tmcf->conf->threads == 0) {
tmcf->conf->threads = nxt_ncpu;
}
http = nxt_conf_get_path(conf, &http_path); http = nxt_conf_get_path(conf, &http_path);
if (http == NULL) { if (http == NULL) {