hadoop-hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zs...@apache.org
Subject svn commit: r908656 - in /hadoop/hive/trunk: CHANGES.txt metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
Date Wed, 10 Feb 2010 20:15:33 GMT
Author: zshao
Date: Wed Feb 10 20:14:57 2010
New Revision: 908656

URL: http://svn.apache.org/viewvc?rev=908656&view=rev
Log:
HIVE-1150. Add comment to explain why we check for dir first in add_partitions(). (Paul Yang
via zshao)

Modified:
    hadoop/hive/trunk/CHANGES.txt
    hadoop/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java

Modified: hadoop/hive/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hive/trunk/CHANGES.txt?rev=908656&r1=908655&r2=908656&view=diff
==============================================================================
--- hadoop/hive/trunk/CHANGES.txt (original)
+++ hadoop/hive/trunk/CHANGES.txt Wed Feb 10 20:14:57 2010
@@ -66,6 +66,9 @@
 
     HIVE-1123. Checkstyle fixes. (Carl Steinbach via zshao)
 
+    HIVE-1150. Add comment to explain why we check for dir first in add_partitions().
+    (Paul Yang via zshao)
+
   OPTIMIZATIONS
 
   BUG FIXES

Modified: hadoop/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
URL: http://svn.apache.org/viewvc/hadoop/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java?rev=908656&r1=908655&r2=908656&view=diff
==============================================================================
--- hadoop/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
(original)
+++ hadoop/hive/trunk/metastore/src/java/org/apache/hadoop/hive/metastore/HiveMetaStore.java
Wed Feb 10 20:14:57 2010
@@ -570,6 +570,9 @@
 
         part.getSd().setLocation(partLocation.toString());
 
+        // Check to see if the directory already exists before calling mkdirs()
+        // because if the file system is read-only, mkdirs will throw an  
+        // exception even if the directory already exists.
         if (!wh.isDir(partLocation)) {
           if (!wh.mkdirs(partLocation)) {
             throw new MetaException(partLocation



Mime
View raw message