You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by mb...@apache.org on 2013/06/17 09:58:23 UTC
svn commit: r1493672 -
/hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java
Author: mbertozzi
Date: Mon Jun 17 07:58:23 2013
New Revision: 1493672
URL: http://svn.apache.org/r1493672
Log:
HBASE-8749 Potential race condition between FSUtils.renameAndSetModifyTime() and HFile/LogCleaner
Modified:
hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java
Modified: hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java
URL: http://svn.apache.org/viewvc/hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java?rev=1493672&r1=1493671&r2=1493672&view=diff
==============================================================================
--- hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java (original)
+++ hbase/branches/0.94/src/main/java/org/apache/hadoop/hbase/HBaseFileSystem.java Mon Jun 17 07:58:23 2013
@@ -259,9 +259,8 @@ public abstract class HBaseFileSystem {
*/
public static boolean renameAndSetModifyTime(final FileSystem fs, Path src, Path dest)
throws IOException {
- if (!renameDirForFileSystem(fs, src, dest)) return false;
// set the modify time for TimeToLive Cleaner
- fs.setTimes(dest, EnvironmentEdgeManager.currentTimeMillis(), -1);
- return true;
+ fs.setTimes(src, EnvironmentEdgeManager.currentTimeMillis(), -1);
+ return renameDirForFileSystem(fs, src, dest);
}
}