hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From w...@apache.org
Subject svn commit: r1546246 - /hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java
Date Thu, 28 Nov 2013 00:44:54 GMT
Author: wang
Date: Thu Nov 28 00:44:54 2013
New Revision: 1546246

URL: http://svn.apache.org/r1546246
Log:
HDFS-5562. TestCacheDirectives and TestFsDatasetCache should stub out native mlock. Contributed
by Colin Patrick McCabe and Akira Ajisaka.

Modified:
    hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java

Modified: hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java?rev=1546246&r1=1546245&r2=1546246&view=diff
==============================================================================
--- hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java
(original)
+++ hadoop/common/trunk/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/nativeio/NativeIO.java
Thu Nov 28 00:44:54 2013
@@ -142,6 +142,10 @@ public class NativeIO {
         NativeIO.POSIX.posixFadviseIfPossible(identifier, fd, offset,
             len, flags);
       }
+
+      public boolean verifyCanMlock() {
+        return NativeIO.isAvailable();
+      }
     }
 
     /**
@@ -163,6 +167,10 @@ public class NativeIO {
       public long getOperatingSystemPageSize() {
         return 4096;
       }
+
+      public boolean verifyCanMlock() {
+        return true;
+      }
     }
 
     static {



Mime
View raw message