-*- coding: utf-8 -*-
Changes with Apache 2.2.7
+ *) Event MPM: Add support for running under mod_ssl, by reverting to the
+ Worker MPM behaviors, when run under an input filter that buffers
+ its own data. [Paul Querna]
+
*) mod_charset_lite: Don't crash when the request has no associated
filename. [Jeff Trawick]
*) Rewrite of aaa modules to an authn/authz model.
[Dirk-Willem van Gulik, Justin Erenkrantz]
-
[Apache 2.1.0-dev includes those bug fixes and changes with the
Apache 2.0.xx tree as documented, and except as noted, below.]
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
[ start all new proposals below, under PATCHES PROPOSED. ]
- * Event MPM: Add clogging_input_filters to the conn_rec, enabling mod_ssl
- to revert to the Worker MPM IO behavoirs, rather than just hanging, when
- using the Event MPM. (minor MMN bump)
- Trunk version of patch:
- http://svn.apache.org/viewvc?view=rev&revision=360257
- http://svn.apache.org/viewvc?view=rev&revision=546328
- http://svn.apache.org/viewvc?view=rev&revision=546650
- http://svn.apache.org/viewvc?view=rev&revision=546715
- 2.2.x version of patch:
- http://people.apache.org/~pquerna/eventmpm-ssl-input-2.2.x.patch
- +1: pquerna, jim, rpluem
PATCHES PROPOSED TO BACKPORT FROM TRUNK:
[ New proposals should be added at the end of the list ]
* ap_get_server_description() (minor)
* 20051115.5 (2.2.5) Added ap_mpm_safe_kill() (minor)
* 20051115.6 (2.2.7) Added retry_set to proxy_worker (minor)
+ * 20051115.7 (2.2.7) Added conn_rec::clogging_input_filters (minor)
*
*/
#ifndef MODULE_MAGIC_NUMBER_MAJOR
#define MODULE_MAGIC_NUMBER_MAJOR 20051115
#endif
-#define MODULE_MAGIC_NUMBER_MINOR 6 /* 0...n */
+#define MODULE_MAGIC_NUMBER_MINOR 7 /* 0...n */
/**
* Determine if the server's current MODULE_MAGIC_NUMBER is at least a
conn_state_t *cs;
/** Is there data pending in the input filters? */
int data_in_input_filters;
+
+ /** Are there any filters that clogg/buffer the input stream, breaking
+ * the event mpm.
+ */
+ int clogging_input_filters;
};
/**
AP_DECLARE_DATA ap_filter_rec_t *ap_http_outerror_filter_handle;
AP_DECLARE_DATA ap_filter_rec_t *ap_byterange_filter_handle;
+static int ap_process_http_connection(conn_rec *c);
+
static const char *set_keep_alive_timeout(cmd_parms *cmd, void *dummy,
const char *arg)
{
request_rec *r;
conn_state_t *cs = c->cs;
+ if (c->clogging_input_filters) {
+ return ap_process_http_connection(c);
+ }
+
AP_DEBUG_ASSERT(cs->state == CONN_STATE_READ_REQUEST_LINE);
while (cs->state == CONN_STATE_READ_REQUEST_LINE) {
filter_ctx->pbioWrite = BIO_new(&bio_filter_out_method);
filter_ctx->pbioWrite->ptr = (void *)bio_filter_out_ctx_new(filter_ctx, c);
+ /* We insert a clogging input filter. Let the core know. */
+ c->clogging_input_filters = 1;
+
ssl_io_input_add_filter(filter_ctx, c, ssl);
SSL_set_bio(ssl, filter_ctx->pbioRead, filter_ctx->pbioWrite);
c->id = id;
c->bucket_alloc = alloc;
+ c->clogging_input_filters = 0;
return c;
}
c->sbh = sbh;
}
+ if (c->clogging_input_filters && !c->aborted) {
+ /* Since we have an input filter which 'cloggs' the input stream,
+ * like mod_ssl, lets just do the normal read from input filters,
+ * like the Worker MPM does.
+ */
+ ap_run_process_connection(c);
+ cs->state = CONN_STATE_LINGER;
+ }
+
if (cs->state == CONN_STATE_READ_REQUEST_LINE) {
if (!c->aborted) {
ap_run_process_connection(c);
if (cs->state == CONN_STATE_LINGER) {
ap_lingering_close(c);
- apr_bucket_alloc_destroy(cs->bucket_alloc);
apr_pool_clear(p);
ap_push_pool(worker_queue_info, p);
return 1;