mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-01 20:49:35 -05:00
warn if "excessive" thread number is set (ITS#4249)
This commit is contained in:
parent
447b065abd
commit
47b4f99363
1 changed files with 7 additions and 0 deletions
|
|
@ -1069,6 +1069,13 @@ config_generic(ConfigArgs *c) {
|
|||
break;
|
||||
|
||||
case CFG_THREADS:
|
||||
if ( c->value_int > 2 * SLAP_MAX_WORKER_THREADS ) {
|
||||
snprintf( c->msg, sizeof( c->msg ),
|
||||
"warning, threads=%d larger than twice the default (2*%d=%d); YMMV",
|
||||
c->value_int, SLAP_MAX_WORKER_THREADS, 2 * SLAP_MAX_WORKER_THREADS );
|
||||
Debug(LDAP_DEBUG_ANY, "%s: %s.\n",
|
||||
c->log, c->msg, 0 );
|
||||
}
|
||||
if ( slapMode & SLAP_SERVER_MODE )
|
||||
ldap_pvt_thread_pool_maxthreads(&connection_pool, c->value_int);
|
||||
connection_pool_max = c->value_int; /* save for reference */
|
||||
|
|
|
|||
Loading…
Reference in a new issue