costin 2002/06/05 12:25:40 Modified: jk/native2/server/apache2 jk_apache2.h jk_logger_apache2.c jk_service_apache2.c mod_jk2.c Log: Patch from Mladen Turk: Organize the mod_jk2 in a way that it can be extended. Common includes are moved to jk_apache2.h (perhaps this should be renamed to the mod_jk2.h). Revision Changes Path 1.10 +23 -4 jakarta-tomcat-connectors/jk/native2/server/apache2/jk_apache2.h Index: jk_apache2.h =================================================================== RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/server/apache2/jk_apache2.h,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- jk_apache2.h 31 May 2002 18:29:48 -0000 1.9 +++ jk_apache2.h 5 Jun 2002 19:25:39 -0000 1.10 @@ -59,9 +59,29 @@ * Description: Apache 2 plugin for Jakarta/Tomcat * Author: Gal Shachor <[EMAIL PROTECTED]> * Henri Gomez <[EMAIL PROTECTED]> - * Version: $Revision: 1.9 $ + * Version: $Revision: 1.10 $ */ +#ifndef JK_APACHE2_H +#define JK_APACHE2_H + +#include "apu_compat.h" +#include "ap_config.h" +#include "apr_lib.h" +#include "apr_date.h" +#include "apr_strings.h" +#include "apr_pools.h" +#include "apr_tables.h" +#include "apr_hash.h" + +#include "httpd.h" +#include "http_config.h" +#include "http_request.h" +#include "http_core.h" +#include "http_protocol.h" +#include "http_main.h" +#include "http_log.h" + #include "jk_global.h" #include "jk_map.h" #include "jk_pool.h" @@ -72,6 +92,7 @@ #include "jk_uriMap.h" #include "jk_requtil.h" +extern module AP_MODULE_DECLARE_DATA jk2_module; int JK_METHOD jk2_service_apache2_init(jk_env_t *env, jk_ws_service_t *s); @@ -85,6 +106,4 @@ jk_bean_t *result, const char *type, const char *name); - - - +#endif /* JK_APACHE2_H */ 1.24 +1 -8 jakarta-tomcat-connectors/jk/native2/server/apache2/jk_logger_apache2.c Index: jk_logger_apache2.c =================================================================== RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/server/apache2/jk_logger_apache2.c,v retrieving revision 1.23 retrieving revision 1.24 diff -u -r1.23 -r1.24 --- jk_logger_apache2.c 16 May 2002 20:55:23 -0000 1.23 +++ jk_logger_apache2.c 5 Jun 2002 19:25:39 -0000 1.24 @@ -75,15 +75,8 @@ * @author Costin Manolache */ -#include "jk_env.h" -#include "jk_map.h" -#include "jk_logger.h" -#include <stdio.h> - -#include "httpd.h" -#include "http_log.h" - #include "jk_apache2.h" +#include <stdio.h> #define HUGE_BUFFER_SIZE (8*1024) 1.25 +4 -28 jakarta-tomcat-connectors/jk/native2/server/apache2/jk_service_apache2.c Index: jk_service_apache2.c =================================================================== RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/server/apache2/jk_service_apache2.c,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- jk_service_apache2.c 31 May 2002 18:29:48 -0000 1.24 +++ jk_service_apache2.c 5 Jun 2002 19:25:39 -0000 1.25 @@ -59,40 +59,16 @@ * Description: Apache 2 plugin for Jakarta/Tomcat * Author: Gal Shachor <[EMAIL PROTECTED]> * Henri Gomez <[EMAIL PROTECTED]> - * Version: $Revision: 1.24 $ + * Version: $Revision: 1.25 $ */ -#include "apu_compat.h" -#include "ap_config.h" -#include "apr_lib.h" -#include "apr_date.h" -#include "apr_strings.h" - -#include "httpd.h" -#include "http_config.h" -#include "http_request.h" -#include "http_core.h" -#include "http_protocol.h" -#include "http_main.h" -#include "http_log.h" - -#include "scoreboard.h" - -#include "util_script.h" /* * Jakarta (jk_) include files */ -#include "jk_global.h" -#include "jk_map.h" -#include "jk_pool.h" -#include "jk_env.h" -#include "jk_service.h" -#include "jk_worker.h" -#include "jk_workerEnv.h" -#include "jk_uriMap.h" -#include "jk_requtil.h" - #include "jk_apache2.h" + +#include "scoreboard.h" +#include "util_script.h" /* #define USE_APRTABLES */ 1.33 +7 -30 jakarta-tomcat-connectors/jk/native2/server/apache2/mod_jk2.c Index: mod_jk2.c =================================================================== RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native2/server/apache2/mod_jk2.c,v retrieving revision 1.32 retrieving revision 1.33 diff -u -r1.32 -r1.33 --- mod_jk2.c 3 Jun 2002 11:24:25 -0000 1.32 +++ mod_jk2.c 5 Jun 2002 19:25:39 -0000 1.33 @@ -59,25 +59,15 @@ * Description: Apache 2 plugin for Jakarta/Tomcat * * Author: Gal Shachor <[EMAIL PROTECTED]> * * Henri Gomez <[EMAIL PROTECTED]> * - * Version: $Revision: 1.32 $ * + * Version: $Revision: 1.33 $ * ***************************************************************************/ /* * mod_jk: keeps all servlet/jakarta related ramblings together. */ -#include "apu_compat.h" -#include "ap_config.h" -#include "apr_lib.h" -#include "apr_date.h" -#include "apr_strings.h" - -#include "httpd.h" -#include "http_config.h" -#include "http_request.h" -#include "http_core.h" -#include "http_protocol.h" -#include "http_main.h" -#include "http_log.h" + + +#include "jk_apache2.h" #include "scoreboard.h" #include "util_script.h" @@ -86,20 +76,6 @@ static char file_name[_MAX_PATH]; #endif -/* - * Jakarta (jk_) include files - */ -#include "jk_global.h" -#include "jk_map.h" -#include "jk_pool.h" -#include "jk_env.h" -#include "jk_service.h" -#include "jk_worker.h" -#include "jk_workerEnv.h" -#include "jk_uriMap.h" -#include "jk_requtil.h" - -#include "jk_apache2.h" #define JK_HANDLER ("jakarta-servlet2") #define JK_MAGIC_TYPE ("application/x-jakarta-servlet2") @@ -156,8 +132,9 @@ int rc; rc=workerEnv->config->setPropertyString( env, workerEnv->config, (char *)name, value ); - if( rc!=JK_OK ) { - fprintf( stderr, "mod_jk2: Unrecognized option %s %s\n", name, value); + if (rc!=JK_OK) { + ap_log_perror(APLOG_MARK, APLOG_NOTICE, 0, cmd->temp_pool, + "mod_jk2: Unrecognized option %s %s\n", name, value); } return NULL;
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>