Commit 6a672d40 authored by Nils Goroll's avatar Nils Goroll Committed by Pål Hermunn Johansen

Apply queue limits only to requests

We should queue bo tasks to avoid failing client requests
unnecessarily.

The detailed parameter description of the queue_limit was already
correct, improve the short one.
parent 674cd521
......@@ -243,8 +243,11 @@ Pool_Task(struct pool *pp, struct pool_task *task, enum task_how how)
return (0);
}
/* Acceptors are not subject to queue limits */
if (how == TASK_QUEUE_VCA ||
/*
* queue limits only apply to client threads - all other
* work is vital and needs do be done at the earliest
*/
if (how != TASK_QUEUE_REQ ||
pp->lqueue < cache_param->wthread_max +
cache_param->wthread_queue_limit + pp->nthr) {
pp->nqueued++;
......
......@@ -187,7 +187,7 @@ struct parspec WRK_parspec[] = {
"10", "requests" },
{ "thread_queue_limit", tweak_uint, &mgt_param.wthread_queue_limit,
"0", NULL,
"Permitted queue length per thread-pool.\n"
"Permitted request queue length per thread-pool.\n"
"\n"
"This sets the number of requests we will queue, waiting "
"for an available thread. Above this limit sessions will "
......
......@@ -1230,7 +1230,7 @@ PARAM(
/* units */ NULL,
/* flags */ EXPERIMENTAL,
/* s-text */
"Permitted queue length per thread-pool.\n"
"Permitted request queue length per thread-pool.\n"
"\n"
"This sets the number of requests we will queue, waiting for an "
"available thread. Above this limit sessions will be dropped "
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment