List of usage examples for org.apache.hadoop.mapred JobClient getClusterStatus
public ClusterStatus getClusterStatus(boolean detailed) throws IOException
From source file:org.apache.accumulo.server.test.continuous.ContinuousStatsCollector.java
License:Apache License
private static String getMRStats() throws Exception { Configuration conf = CachedConfiguration.getInstance(); @SuppressWarnings("deprecation") JobClient jc = new JobClient(new org.apache.hadoop.mapred.JobConf(conf)); ClusterStatus cs = jc.getClusterStatus(false); return "" + cs.getMapTasks() + " " + cs.getMaxMapTasks() + " " + cs.getReduceTasks() + " " + cs.getMaxReduceTasks() + " " + cs.getTaskTrackers() + " " + cs.getBlacklistedTrackers(); }
From source file:org.apache.accumulo.test.continuous.ContinuousStatsCollector.java
License:Apache License
private static String getMRStats() throws Exception { Configuration conf = CachedConfiguration.getInstance(); // No alternatives for hadoop 20 JobClient jc = new JobClient(new org.apache.hadoop.mapred.JobConf(conf)); ClusterStatus cs = jc.getClusterStatus(false); return "" + cs.getMapTasks() + " " + cs.getMaxMapTasks() + " " + cs.getReduceTasks() + " " + cs.getMaxReduceTasks() + " " + cs.getTaskTrackers() + " " + cs.getBlacklistedTrackers(); }