You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mapreduce-commits@hadoop.apache.org by sh...@apache.org on 2009/10/12 07:54:45 UTC

svn commit: r824238 - in /hadoop/mapreduce/trunk: CHANGES.txt src/java/org/apache/hadoop/mapred/ClusterStatus.java src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java

Author: sharad
Date: Mon Oct 12 05:54:45 2009
New Revision: 824238

URL: http://svn.apache.org/viewvc?rev=824238&view=rev
Log:
MAPREDUCE-1076. Deprecate ClusterStatus and add javadoc in ClusterMetrics. Contributed by Amareshwari Sriramadasu.

Modified:
    hadoop/mapreduce/trunk/CHANGES.txt
    hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/ClusterStatus.java
    hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java

Modified: hadoop/mapreduce/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/CHANGES.txt?rev=824238&r1=824237&r2=824238&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/CHANGES.txt (original)
+++ hadoop/mapreduce/trunk/CHANGES.txt Mon Oct 12 05:54:45 2009
@@ -742,3 +742,6 @@
     consistent, thereby fixing inconsistencies in metering tasks.
     (Sreekanth Ramakrishnan via yhemanth)
 
+    MAPREDUCE-1076. Deprecate ClusterStatus and add javadoc in ClusterMetrics.
+    (Amareshwari Sriramadasu via sharad)
+

Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/ClusterStatus.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/ClusterStatus.java?rev=824238&r1=824237&r2=824238&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/ClusterStatus.java (original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapred/ClusterStatus.java Mon Oct 12 05:54:45 2009
@@ -27,6 +27,8 @@
 import org.apache.hadoop.io.Text;
 import org.apache.hadoop.io.Writable;
 import org.apache.hadoop.io.WritableUtils;
+import org.apache.hadoop.mapreduce.ClusterMetrics;
+import org.apache.hadoop.mapreduce.TaskTrackerInfo;
 
 /**
  * Status information on the current state of the Map-Reduce cluster.
@@ -57,7 +59,9 @@
  * {@link JobClient#getClusterStatus()}.</p>
  * 
  * @see JobClient
+ * @deprecated  Use {@link ClusterMetrics} or {@link TaskTrackerInfo} instead
  */
+@Deprecated
 public class ClusterStatus implements Writable {
   /**
    * Class which encapsulates information about a blacklisted tasktracker.

Modified: hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java?rev=824238&r1=824237&r2=824238&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java (original)
+++ hadoop/mapreduce/trunk/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java Mon Oct 12 05:54:45 2009
@@ -71,30 +71,65 @@
     this.numDecommissionedTrackers = numDecommisionedNodes;
   }
   
+  /**
+   * Get number of occupied map slots in the cluster.
+   * 
+   * @return occupied map slot count
+   */
   public int getOccupiedMapSlots() { 
     return runningMaps;
   }
   
+  /**
+   * Get the number of occupied reduce slots in the cluster.
+   * 
+   * @return occupied reduce slot count
+   */
   public int getOccupiedReduceSlots() { 
     return runningReduces; 
   }
   
+  /**
+   * Get the total number of map slots in the cluster.
+   * 
+   * @return map slot capacity
+   */
   public int getMapSlotCapacity() {
     return mapSlots;
   }
   
+  /**
+   * Get the total number of reduce slots in the cluster.
+   * 
+   * @return reduce slot capacity
+   */
   public int getReduceSlotCapacity() {
     return reduceSlots;
   }
   
+  /**
+   * Get the number of active trackers in the cluster.
+   * 
+   * @return active tracker count.
+   */
   public int getTaskTrackerCount() {
     return numTrackers;
   }
   
+  /**
+   * Get the number of blacklisted trackers in the cluster.
+   * 
+   * @return blacklisted tracker count
+   */
   public int getBlackListedTaskTrackerCount() {
     return numBlacklistedTrackers;
   }
   
+  /**
+   * Get the number of decommissioned trackers in the cluster.
+   * 
+   * @return decommissioned tracker count
+   */
   public int getDecommissionedTaskTrackerCount() {
     return numDecommissionedTrackers;
   }