hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r636704 - in /hadoop/core/trunk: CHANGES.txt src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java
Date Thu, 13 Mar 2008 10:44:22 GMT
Author: ddas
Date: Thu Mar 13 03:44:13 2008
New Revision: 636704

URL: http://svn.apache.org/viewvc?rev=636704&view=rev
Log:
HADOOP-2995. Fixes StreamBaseRecordReader's getProgress to return a floating point number.
Contributed by Dave Brosius.

Modified:
    hadoop/core/trunk/CHANGES.txt
    hadoop/core/trunk/src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java

Modified: hadoop/core/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/CHANGES.txt?rev=636704&r1=636703&r2=636704&view=diff
==============================================================================
--- hadoop/core/trunk/CHANGES.txt (original)
+++ hadoop/core/trunk/CHANGES.txt Thu Mar 13 03:44:13 2008
@@ -190,6 +190,9 @@
     HADOOP-2996. Fixes uses of StringBuffer in StreamUtils class.
     (Dave Brosius via ddas)
 
+    HADOOP-2995. Fixes StreamBaseRecordReader's getProgress to return a 
+    floating point number. (Dave Brosius via ddas)
+
 Release 0.16.1 - 2008-03-13
 
   INCOMPATIBLE CHANGES

Modified: hadoop/core/trunk/src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java?rev=636704&r1=636703&r2=636704&view=diff
==============================================================================
--- hadoop/core/trunk/src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java
(original)
+++ hadoop/core/trunk/src/contrib/streaming/src/java/org/apache/hadoop/streaming/StreamBaseRecordReader.java
Thu Mar 13 03:44:13 2008
@@ -84,7 +84,7 @@
     if (end_ == start_) {
       return 1.0f;
     } else {
-      return (in_.getPos() - start_) / (end_ - start_);
+      return ((float)(in_.getPos() - start_)) / ((float)(end_ - start_));
     }
   }
   



Mime
View raw message