costin 01/07/03 16:55:27
Modified: src/share/org/apache/tomcat/modules/config ApacheConfig.java
Log:
Added the JkDebug option - another small step in having all user
setable options in server.xml ( and not having the user touch
any server config file ).
Note that JkDebug should be moved in workers.properties, along with
many other jk options - the file is common to all servers.
Right now I'll use ApacheConfig, and move later - I can't test with
IIS and NES and it'll be easier to wait until everything is finished
for apache, and then update the others ( by removing what will no longer
be needed )
Revision Changes Path
1.14 +16 -7
jakarta-tomcat/src/share/org/apache/tomcat/modules/config/ApacheConfig.java
Index: ApacheConfig.java
===================================================================
RCS file:
/home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/config/ApacheConfig.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- ApacheConfig.java 2001/07/03 23:50:32 1.13
+++ ApacheConfig.java 2001/07/03 23:55:27 1.14
@@ -1,4 +1,4 @@
-/* $Id: ApacheConfig.java,v 1.13 2001/07/03 23:50:32 costin Exp $
+/* $Id: ApacheConfig.java,v 1.14 2001/07/03 23:55:27 costin Exp $
* ====================================================================
*
* The Apache Software License, Version 1.1
@@ -105,7 +105,7 @@
<p>
@author Costin Manolache
@author Mel Martinez
- @version $Revision: 1.13 $ $Date: 2001/07/03 23:50:32 $
+ @version $Revision: 1.14 $ $Date: 2001/07/03 23:55:27 $
*/
public class ApacheConfig extends BaseInterceptor {
@@ -142,6 +142,8 @@
private String jkProto = null;
private int portInt=0;
String tomcatHome;
+
+ private String jkDebug=null;
// default is true until we can map all web.xml directives
// Or detect only portable directives were used.
@@ -259,6 +261,14 @@
jkProto = protocol;
}
+
+ /** Set the verbosity level for mod_jk.
+ ( use debug, error, etc )
+ */
+ public void setJkDebug( String level ) {
+ jkDebug=level;
+ }
+
// -------------------- Initialize/guess defaults --------------------
/** Initialize defaults for properties that are not set
@@ -396,13 +406,12 @@
+ jkLog.toString().replace('\\', '/')
+ "\"");
mod_jk.println();
- mod_jk.println("#");
- mod_jk.println("# Log level to be used by mod_jk");
- mod_jk.println("#");
// XXX Make it configurable
- mod_jk.println("JkLogLevel error");
- mod_jk.println();
+ if( jkDebug != null ) {
+ mod_jk.println("JkLogLevel " + jkDebug);
+ mod_jk.println();
+ }
}