[Opensrf-commits] r1474 - trunk/src/gateway
svn at svn.open-ils.org
svn at svn.open-ils.org
Fri Oct 24 12:31:14 EDT 2008
Author: erickson
Date: 2008-10-24 12:31:07 -0400 (Fri, 24 Oct 2008)
New Revision: 1474
Modified:
trunk/src/gateway/osrf_http_translator.c
trunk/src/gateway/osrf_json_gateway.c
Log:
the pool cleanup handler which was thought to only run on top-level child process exit is running on cloned processes cleanup. this is how mod_cgi runs scripts. disabling cleanup for now. note: this cleanup is new to 1.0
Modified: trunk/src/gateway/osrf_http_translator.c
===================================================================
--- trunk/src/gateway/osrf_http_translator.c 2008-10-24 16:30:33 UTC (rev 1473)
+++ trunk/src/gateway/osrf_http_translator.c 2008-10-24 16:31:07 UTC (rev 1474)
@@ -318,10 +318,14 @@
static void osrfHttpTranslatorWriteChunk(osrfHttpTranslator* trans, transport_message* msg) {
ap_rprintf(trans->apreq,
"Content-type: %s\n\n%s\n\n", JSON_CONTENT_TYPE, msg->body);
- if(trans->complete)
+ osrfLogInternal(OSRF_LOG_MARK, "Apache sending data: Content-type: %s\n\n%s\n\n", JSON_CONTENT_TYPE, msg->body);
+ if(trans->complete) {
ap_rprintf(trans->apreq, "--%s--\n", trans->delim);
- else
+ osrfLogInternal(OSRF_LOG_MARK, "Apache sending data: --%s--\n", trans->delim);
+ } else {
ap_rprintf(trans->apreq, "--%s\n", trans->delim);
+ osrfLogInternal(OSRF_LOG_MARK, "Apache sending data: --%s\n", trans->delim);
+ }
ap_rflush(trans->apreq);
}
@@ -437,7 +441,8 @@
osrfConnected = 1;
// at pool destroy time (= child exit time), cleanup
- apr_pool_cleanup_register(p, NULL, childExit, NULL);
+ // XXX causes us to disconnect even for clone()'d process cleanup (as in mod_cgi)
+ //apr_pool_cleanup_register(p, NULL, childExit, apr_pool_cleanup_null);
}
static int handler(request_rec *r) {
Modified: trunk/src/gateway/osrf_json_gateway.c
===================================================================
--- trunk/src/gateway/osrf_json_gateway.c 2008-10-24 16:30:33 UTC (rev 1473)
+++ trunk/src/gateway/osrf_json_gateway.c 2008-10-24 16:31:07 UTC (rev 1474)
@@ -99,7 +99,8 @@
// when this pool is cleaned up, it means the child
// process is going away. register some cleanup code
- apr_pool_cleanup_register(p, NULL, child_exit, NULL);
+ // XXX causes us to disconnect even for clone()'d process cleanup (as in mod_cgi)
+ //apr_pool_cleanup_register(p, NULL, child_exit, apr_pool_cleanup_null);
}
static int osrf_json_gateway_method_handler (request_rec *r) {
More information about the opensrf-commits
mailing list