struts-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From musa...@apache.org
Subject svn commit: r811701 - /struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java
Date Sat, 05 Sep 2009 19:07:51 GMT
Author: musachy
Date: Sat Sep  5 19:07:51 2009
New Revision: 811701

URL: http://svn.apache.org/viewvc?rev=811701&view=rev
Log:
add log statement

Modified:
    struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java

Modified: struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java
URL: http://svn.apache.org/viewvc/struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java?rev=811701&r1=811700&r2=811701&view=diff
==============================================================================
--- struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java
(original)
+++ struts/struts2/trunk/plugins/spring/src/main/java/org/apache/struts2/spring/ClassReloadingXMLWebApplicationContext.java
Sat Sep  5 19:07:51 2009
@@ -201,11 +201,15 @@
 
     private void reload(File file) {
         if (classLoader != null) {
-            if (LOG.isDebugEnabled())
+            final boolean debugEnabled = LOG.isDebugEnabled();
+            if (debugEnabled)
                 LOG.debug("Change detected in file [#0], reloading class loader", file.getAbsolutePath());
             classLoader.reload();
-            if (reloadConfig && Dispatcher.getInstance() != null)
+            if (reloadConfig && Dispatcher.getInstance() != null) {
+                if (debugEnabled)
+                    LOG.debug("Change detected in file [#0], reloading configuration", file.getAbsolutePath());
                 Dispatcher.getInstance().getConfigurationManager().reload();
+            }
         }
     }
 



Mime
View raw message