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:58:02 UTC
svn commit: r824239 - in /hadoop/mapreduce/branches/branch-0.21: 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:58:02 2009
New Revision: 824239
URL: http://svn.apache.org/viewvc?rev=824239&view=rev
Log:
MAPREDUCE-1076. svn merge -r 824237:824238 http://svn.apache.org/repos/asf/hadoop/mapreduce/trunk
Modified:
hadoop/mapreduce/branches/branch-0.21/CHANGES.txt
hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapred/ClusterStatus.java
hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java
Modified: hadoop/mapreduce/branches/branch-0.21/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/branches/branch-0.21/CHANGES.txt?rev=824239&r1=824238&r2=824239&view=diff
==============================================================================
--- hadoop/mapreduce/branches/branch-0.21/CHANGES.txt (original)
+++ hadoop/mapreduce/branches/branch-0.21/CHANGES.txt Mon Oct 12 05:58:02 2009
@@ -723,3 +723,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/branches/branch-0.21/src/java/org/apache/hadoop/mapred/ClusterStatus.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapred/ClusterStatus.java?rev=824239&r1=824238&r2=824239&view=diff
==============================================================================
--- hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapred/ClusterStatus.java (original)
+++ hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapred/ClusterStatus.java Mon Oct 12 05:58:02 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/branches/branch-0.21/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java?rev=824239&r1=824238&r2=824239&view=diff
==============================================================================
--- hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java (original)
+++ hadoop/mapreduce/branches/branch-0.21/src/java/org/apache/hadoop/mapreduce/ClusterMetrics.java Mon Oct 12 05:58:02 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;
}