commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1369337 - in /commons/proper/jcs/trunk/src: changes/changes.xml java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java
Date Sat, 04 Aug 2012 14:59:57 GMT
Author: tv
Date: Sat Aug  4 14:59:56 2012
New Revision: 1369337

URL: http://svn.apache.org/viewvc?rev=1369337&view=rev
Log:
Fix for JCS-77: NullPointerException thrown by IndexedDiskCache if IndexedDisk calls fail
to initialize.

Modified:
    commons/proper/jcs/trunk/src/changes/changes.xml
    commons/proper/jcs/trunk/src/java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java

Modified: commons/proper/jcs/trunk/src/changes/changes.xml
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/changes/changes.xml?rev=1369337&r1=1369336&r2=1369337&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/changes/changes.xml (original)
+++ commons/proper/jcs/trunk/src/changes/changes.xml Sat Aug  4 14:59:56 2012
@@ -20,6 +20,10 @@
 	</properties>
 	<body>
 		<release version="2.0" date="unreleased" description="JDK 1.5 based major release">
+            <action dev="tv" type="fix" issue="JCS-77" due-to="Matt Morrisson">
+                NullPointerException thrown by IndexedDiskCache if IndexedDisk calls fail
to 
+                initialize.
+            </action>
             <action dev="tv" type="fix" issue="JCS-90" due-to="Diego Rivera">
                 When issuing a shutDown() command, JCS fails to clean up the Queue Processor

                 thread.

Modified: commons/proper/jcs/trunk/src/java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java
URL: http://svn.apache.org/viewvc/commons/proper/jcs/trunk/src/java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java?rev=1369337&r1=1369336&r2=1369337&view=diff
==============================================================================
--- commons/proper/jcs/trunk/src/java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java
(original)
+++ commons/proper/jcs/trunk/src/java/org/apache/jcs/auxiliary/disk/indexed/IndexedDiskCache.java
Sat Aug  4 14:59:56 2012
@@ -185,19 +185,19 @@ public class IndexedDiskCache<K extends 
             {
                 log.info( logCacheName + "Indexed Disk Cache is alive." );
             }
+
+            // TODO: Should we improve detection of whether or not the file should be optimized.
+            if ( isRealTimeOptimizationEnabled && keyHash.size() > 0 )
+            {
+                // Kick off a real time optimization, in case we didn't do a final optimization.
+                doOptimizeRealTime();
+            }
         }
         catch ( Exception e )
         {
             log.error( logCacheName + "Failure initializing for fileName: " + fileName +
" and directory: "
                 + this.rafDir.getAbsolutePath(), e );
         }
-
-        // TODO: Should we improve detection of whether or not the file should be optimized.
-        if ( isRealTimeOptimizationEnabled && keyHash.size() > 0 )
-        {
-            // Kick off a real time optimization, in case we didn't do a final optimization.
-            doOptimizeRealTime();
-        }
     }
 
     /**



Mime
View raw message