costin 01/06/12 18:42:16 Modified: src/share/org/apache/tomcat/modules/mappers ReloadInterceptor.java src/share/org/apache/tomcat/util/depend DependManager.java Log: Added a setDebug to DependManager. Setting debug on the reload interceptor will also enable debugging in the DependManager ( those 2 are used to implement reloading ). JspInterceptor(34) uses a local DependManager for each page for the local JSPs. Revision Changes Path 1.8 +3 -1 jakarta-tomcat/src/share/org/apache/tomcat/modules/mappers/ReloadInterceptor.java Index: ReloadInterceptor.java =================================================================== RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/modules/mappers/ReloadInterceptor.java,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- ReloadInterceptor.java 2001/06/08 03:05:19 1.7 +++ ReloadInterceptor.java 2001/06/13 01:42:15 1.8 @@ -105,7 +105,9 @@ dm=new DependManager(); context.getContainer().setNote("DependManager", dm); } - + if( debug > 0 ) { + dm.setDebug( debug ); + } } /** Example of adding web.xml to the dependencies. 1.7 +10 -2 jakarta-tomcat/src/share/org/apache/tomcat/util/depend/DependManager.java Index: DependManager.java =================================================================== RCS file: /home/cvs/jakarta-tomcat/src/share/org/apache/tomcat/util/depend/DependManager.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- DependManager.java 2001/06/08 03:12:45 1.6 +++ DependManager.java 2001/06/13 01:42:16 1.7 @@ -134,7 +134,7 @@ public boolean shouldReload1() { // somebody else is checking, so we don't know yet. // assume we're fine - reduce the need for sync - if( debug > 0 && expired ) + if( debug > 0 && expired ) log( "ShouldReload1 E=" + expired + " C=" + checking); if( checking ) return expired; @@ -168,6 +168,7 @@ if( ! d.isLocal() ) { // if d is local, it'll just be marked as expired, // the DependManager will not. + // if( debug >0 ) expired=true; } } @@ -194,6 +195,9 @@ } public void setExpired( boolean e ) { + if( debug > 0 ) { + log( "SetExpired " + e ); + } for( int i=0; i<depsCount; i++ ) { deps[i].setExpired( e ); } @@ -211,7 +215,11 @@ // -------------------- Private - private static final int debug=0; + private int debug=0; + + public void setDebug( int i ) { + debug=i; + } void log( String s ) { System.out.println("DependManager: " + s );