Browse Source

HADOOP-3560. Fixes a problem to do with split creation in archives. Contributed by Mahadev Konar.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/core/trunk@668396 13f79535-47bb-0310-9956-ffa450edef68
Devaraj Das 17 years ago
parent
commit
52ae96334c
2 changed files with 5 additions and 0 deletions
  1. 3 0
      CHANGES.txt
  2. 2 0
      src/tools/org/apache/hadoop/tools/HadoopArchives.java

+ 3 - 0
CHANGES.txt

@@ -598,6 +598,9 @@ Release 0.18.0 - Unreleased
 
     HADOOP-3363. Fix unformatted storage detection in FSImage. (shv)
 
+    HADOOP-3560. Fixes a problem to do with split creation in archives.
+    (Mahadev Konar via ddas)
+
 Release 0.17.0 - 2008-05-18
 
   INCOMPATIBLE CHANGES

+ 2 - 0
src/tools/org/apache/hadoop/tools/HadoopArchives.java

@@ -328,6 +328,7 @@ public class HadoopArchives implements Tool {
     try {
       // write the top level dirs in first 
       writeTopLevelDirs(srcWriter, srcPaths);
+      srcWriter.sync();
       // these are the input paths passed 
       // from the command line
       // we do a recursive ls on these paths 
@@ -356,6 +357,7 @@ public class HadoopArchives implements Tool {
           }
           srcWriter.append(new LongWritable(len), new 
               Text(toWrite));
+          srcWriter.sync();
           numFiles++;
           totalSize += len;
         }