tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mt...@apache.org
Subject cvs commit: jakarta-tomcat-connectors/jk/native/apache-2.0 mod_jk.c
Date Wed, 09 Feb 2005 07:39:08 GMT
mturk       2005/02/08 23:39:08

  Modified:    jk/native/apache-2.0 mod_jk.c
  Log:
  Move jk_set_worker_def_cache_size to post config hook, so that
  it is set before the jk configuration is parsed.
  
  Revision  Changes    Path
  1.122     +12 -12    jakarta-tomcat-connectors/jk/native/apache-2.0/mod_jk.c
  
  Index: mod_jk.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/apache-2.0/mod_jk.c,v
  retrieving revision 1.121
  retrieving revision 1.122
  diff -u -r1.121 -r1.122
  --- mod_jk.c	7 Feb 2005 19:07:38 -0000	1.121
  +++ mod_jk.c	9 Feb 2005 07:39:08 -0000	1.122
  @@ -2225,7 +2225,6 @@
   static void jk_child_init(apr_pool_t * pconf, server_rec * s)
   {
       jk_server_conf_t *conf;
  -    int mpm_threads = 1;
       apr_status_t rv;
       int rc;
   
  @@ -2239,15 +2238,6 @@
   
       JK_TRACE_ENTER(conf->log);
   
  -    /* Set default connection cache size for worker mpm */
  -#if APR_HAS_THREADS
  -#ifndef AS400
  -    ap_mpm_query(AP_MPMQ_MAX_THREADS, &mpm_threads);
  -#endif
  -#endif
  -    if (mpm_threads > 0)
  -        jk_set_worker_def_cache_size(mpm_threads);
  -
       if ((rc = jk_shm_attach(jk_shm_file)) == 0) {
           if (JK_IS_DEBUG_LEVEL(conf->log))
               jk_log(conf->log, JK_LOG_DEBUG, "Attached shm:%s",
  @@ -2277,10 +2267,11 @@
                       server_rec * s)
   {
       int rc;
  +    int mpm_threads = 1;
  +
       /*     jk_map_t *init_map = NULL; */
       jk_map_t *init_map = conf->worker_properties;
   
  -    ;
       if ((rc = jk_shm_open(jk_shm_file)) == 0) {
           if (JK_IS_DEBUG_LEVEL(conf->log))
               jk_log(conf->log, JK_LOG_DEBUG, "Initialized shm:%s",
  @@ -2292,6 +2283,15 @@
           jk_log(conf->log, JK_LOG_ERROR, "Initializing shm:%s errno=%d",
                  jk_shm_name(), rc);
   
  +    /* Set default connection cache size for worker mpm */
  +#if APR_HAS_THREADS
  +#ifndef AS400
  +    if (ap_mpm_query(AP_MPMQ_MAX_THREADS, &mpm_threads) != APR_SUCCESS)
  +        mpm_threads = 1;
  +#endif
  +#endif
  +     jk_set_worker_def_cache_size(mpm_threads);
  +
       if (!uri_worker_map_alloc(&(conf->uw_map),
                                 conf->uri_to_context,
                                 conf->log)) {
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message