-*- coding: utf-8 -*-
Changes with Apache 2.5.0
+ *) mpm_event: Don't count connections in lingering close state when
+ calculating how many additional connections may be accepted.
+ [Stefan Fritsch]
+
*) mod_deflate: Skip compression if compression is enabled at SSL level.
[Stefan Fritsch]
<p>This directive can be used to fine-tune the per-process connection
limit. A process will only accept new connections if the current number of
- connections is lower than:</p>
+ connections (not counting connections in the "closing" state) is lower
+ than:</p>
<p class="indent"><strong>
<directive module="mpm_common">ThreadsPerChild</directive> +
"All workers busy, not accepting new conns"
"in this process");
}
- else if (apr_atomic_read32(&connection_count) > threads_per_child
- + ap_queue_info_get_idlers(worker_queue_info) *
- worker_factor / WORKER_FACTOR_SCALE)
+ else if ( (int)apr_atomic_read32(&connection_count)
+ - (int)apr_atomic_read32(&lingering_count)
+ > threads_per_child
+ + ap_queue_info_get_idlers(worker_queue_info) *
+ worker_factor / WORKER_FACTOR_SCALE)
{
if (!listeners_disabled)
disable_listensocks(process_slot);
ps->suspended = apr_atomic_read32(&suspended_count);
ps->lingering_close = apr_atomic_read32(&lingering_count);
}
- if (listeners_disabled && !workers_were_busy &&
- (int)apr_atomic_read32(&connection_count) <
- ((int)ap_queue_info_get_idlers(worker_queue_info) - 1) *
- worker_factor / WORKER_FACTOR_SCALE + threads_per_child)
+ if (listeners_disabled && !workers_were_busy
+ && (int)apr_atomic_read32(&connection_count)
+ - (int)apr_atomic_read32(&lingering_count)
+ < ((int)ap_queue_info_get_idlers(worker_queue_info) - 1)
+ * worker_factor / WORKER_FACTOR_SCALE + threads_per_child)
{
listeners_disabled = 0;
enable_listensocks(process_slot);