org.apache.pig.tools.pigstats
Class JobStats

java.lang.Object
  extended by org.apache.pig.newplan.Operator
      extended by org.apache.pig.tools.pigstats.JobStats

@InterfaceAudience.Public
@InterfaceStability.Evolving
public final class JobStats
extends Operator

This class encapsulates the runtime statistics of a MapReduce job. Job statistics is collected when job is completed.


Nested Class Summary
static class JobStats.JobState
           
 
Field Summary
static String ALIAS
           
static String ALIAS_LOCATION
           
static String FAILURE_HEADER
           
static String FEATURE
           
static String SUCCESS_HEADER
           
static String SUCCESS_HEADER_LOCAL
           
 
Fields inherited from class org.apache.pig.newplan.Operator
annotations, hashPrime, location, name, plan
 
Method Summary
 void accept(PlanVisitor v)
          Accept a visitor at this node in the graph.
 String getAlias()
           
 String getAliasLocation()
           
 long getAvgMapTime()
           
 long getAvgREduceTime()
           
 long getBytesWritten()
          Returns the total bytes written to user specified HDFS locations of this job.
 String getErrorMessage()
           
 Exception getException()
           
 String getFeature()
           
 org.apache.hadoop.mapred.Counters getHadoopCounters()
           
 long getHdfsBytesWritten()
           
 List<InputStats> getInputs()
           
 String getJobId()
           
 long getMapInputRecords()
           
 long getMapOutputRecords()
           
 long getMaxMapTime()
           
 long getMaxReduceTime()
           
 long getMinMapTime()
           
 long getMinReduceTime()
           
 Map<String,Long> getMultiStoreCounters()
           
 int getNumberMaps()
           
 int getNumberReduces()
           
 List<OutputStats> getOutputs()
           
 long getProactiveSpillCountObjects()
           
 long getProactiveSpillCountRecs()
           
 long getRecordWrittern()
          Returns the total number of records in user specified output locations of this job.
 long getReduceInputRecords()
           
 long getReduceOutputRecords()
           
 long getSMMSpillCount()
           
 JobStats.JobState getState()
           
 boolean isEqual(Operator operator)
          This is like a shallow equals comparison.
 boolean isSuccessful()
           
 
Methods inherited from class org.apache.pig.newplan.Operator
annotate, getAnnotation, getLocation, getName, getPlan, removeAnnotation, setLocation, setPlan
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ALIAS

public static final String ALIAS
See Also:
Constant Field Values

ALIAS_LOCATION

public static final String ALIAS_LOCATION
See Also:
Constant Field Values

FEATURE

public static final String FEATURE
See Also:
Constant Field Values

SUCCESS_HEADER

public static final String SUCCESS_HEADER
See Also:
Constant Field Values

FAILURE_HEADER

public static final String FAILURE_HEADER
See Also:
Constant Field Values

SUCCESS_HEADER_LOCAL

public static final String SUCCESS_HEADER_LOCAL
See Also:
Constant Field Values
Method Detail

getJobId

public String getJobId()

getState

public JobStats.JobState getState()

isSuccessful

public boolean isSuccessful()

getErrorMessage

public String getErrorMessage()

getException

public Exception getException()

getNumberMaps

public int getNumberMaps()

getNumberReduces

public int getNumberReduces()

getMaxMapTime

public long getMaxMapTime()

getMinMapTime

public long getMinMapTime()

getAvgMapTime

public long getAvgMapTime()

getMaxReduceTime

public long getMaxReduceTime()

getMinReduceTime

public long getMinReduceTime()

getAvgREduceTime

public long getAvgREduceTime()

getMapInputRecords

public long getMapInputRecords()

getMapOutputRecords

public long getMapOutputRecords()

getReduceOutputRecords

public long getReduceOutputRecords()

getReduceInputRecords

public long getReduceInputRecords()

getSMMSpillCount

public long getSMMSpillCount()

getProactiveSpillCountObjects

public long getProactiveSpillCountObjects()

getProactiveSpillCountRecs

public long getProactiveSpillCountRecs()

getHdfsBytesWritten

public long getHdfsBytesWritten()

getHadoopCounters

public org.apache.hadoop.mapred.Counters getHadoopCounters()

getOutputs

public List<OutputStats> getOutputs()

getInputs

public List<InputStats> getInputs()

getMultiStoreCounters

public Map<String,Long> getMultiStoreCounters()

getAlias

public String getAlias()

getAliasLocation

public String getAliasLocation()

getFeature

public String getFeature()

getBytesWritten

public long getBytesWritten()
Returns the total bytes written to user specified HDFS locations of this job.


getRecordWrittern

public long getRecordWrittern()
Returns the total number of records in user specified output locations of this job.


accept

public void accept(PlanVisitor v)
            throws FrontendException
Description copied from class: Operator
Accept a visitor at this node in the graph.

Specified by:
accept in class Operator
Parameters:
v - Visitor to accept.
Throws:
FrontendException

isEqual

public boolean isEqual(Operator operator)
Description copied from class: Operator
This is like a shallow equals comparison. It returns true if two operators have equivalent properties even if they are different objects. Here properties mean equivalent plan and equivalent name.

Specified by:
isEqual in class Operator
Returns:
true if two object have equivalent properties, else false


Copyright © 2007-2012 The Apache Software Foundation