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-1.3 mod_jk.c
Date Mon, 13 Dec 2004 09:11:24 GMT
mturk       2004/12/13 01:11:24

  Modified:    jk/native/apache-1.3 mod_jk.c
  Log:
  Add more logging.
  
  Revision  Changes    Path
  1.59      +27 -3     jakarta-tomcat-connectors/jk/native/apache-1.3/mod_jk.c
  
  Index: mod_jk.c
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/apache-1.3/mod_jk.c,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -r1.58 -r1.59
  --- mod_jk.c	7 Dec 2004 14:02:51 -0000	1.58
  +++ mod_jk.c	13 Dec 2004 09:11:24 -0000	1.59
  @@ -1599,8 +1599,11 @@
                                                         module_config,
                                                         &jk_module);
           jk_logger_t *l = conf->log ? conf->log : main_log;
  +        jk_worker_t *worker;
   
  -        jk_worker_t *worker = wc_get_worker_for_name(worker_name, l);
  +        JK_TRACE_ENTER(l);
  +
  +        worker = wc_get_worker_for_name(worker_name, l);
   
           if (worker) {
   #ifndef NO_GETTIMEOFDAY
  @@ -1670,17 +1673,38 @@
                   }
   #endif
               }
  -
  +            else {
  +                jk_log(l, JK_LOG_ERROR, "Could not init service"
  +                       " for worker=%s\n",
  +                       worker_name);
  +                JK_TRACE_EXIT(l);
  +                return HTTP_INTERNAL_SERVER_ERROR;                
  +            }
               jk_close_pool(&private_data.p);
   
               if (rc) {
                   /* If tomcat returned no body and the status is not OK,
                      let apache handle the error code */
                   if (!r->sent_bodyct && r->status >= HTTP_BAD_REQUEST)
{
  +                    jk_log(l, JK_LOG_INFO, "No body with status=%d"
  +                           " for worker=%s\n",
  +                           r->status, worker_name);
  +                    JK_TRACE_EXIT(l);
                       return r->status;
                   }
  +                jk_log(l, JK_LOG_INFO, "Service returned error=%d"
  +                       " with status=%d for worker=%s\n",
  +                       rc, r->status, worker_name);
  +                JK_TRACE_EXIT(l);
                   return OK;      /* NOT r->status, even if it has changed. */
               }
  +        }
  +        else {
  +            jk_log(l, JK_LOG_ERROR, "Could not init service"
  +                   " for worker=%s\n",
  +                   worker_name);
  +            JK_TRACE_EXIT(l);
  +            return HTTP_INTERNAL_SERVER_ERROR;                
           }
       }
   
  
  
  

---------------------------------------------------------------------
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