org.apache.spark
Class JavaSparkListener

Object
  extended by org.apache.spark.JavaSparkListener
All Implemented Interfaces:
SparkListener

public class JavaSparkListener
extends Object
implements SparkListener

Java clients should extend this class instead of implementing SparkListener directly. This is to prevent java clients from breaking when new events are added to the SparkListener trait. This is a concrete class instead of abstract to enforce new events get added to both the SparkListener and this adapter in lockstep.


Constructor Summary
JavaSparkListener()
           
 
Method Summary
 void onApplicationEnd(SparkListenerApplicationEnd applicationEnd)
          Called when the application ends
 void onApplicationStart(SparkListenerApplicationStart applicationStart)
          Called when the application starts
 void onBlockManagerAdded(SparkListenerBlockManagerAdded blockManagerAdded)
          Called when a new block manager has joined
 void onBlockManagerRemoved(SparkListenerBlockManagerRemoved blockManagerRemoved)
          Called when an existing block manager has been removed
 void onEnvironmentUpdate(SparkListenerEnvironmentUpdate environmentUpdate)
          Called when environment properties have been updated
 void onExecutorAdded(SparkListenerExecutorAdded executorAdded)
          Called when the driver registers a new executor.
 void onExecutorMetricsUpdate(SparkListenerExecutorMetricsUpdate executorMetricsUpdate)
          Called when the driver receives task metrics from an executor in a heartbeat.
 void onExecutorRemoved(SparkListenerExecutorRemoved executorRemoved)
          Called when the driver removes an executor.
 void onJobEnd(SparkListenerJobEnd jobEnd)
          Called when a job ends
 void onJobStart(SparkListenerJobStart jobStart)
          Called when a job starts
 void onStageCompleted(SparkListenerStageCompleted stageCompleted)
          Called when a stage completes successfully or fails, with information on the completed stage.
 void onStageSubmitted(SparkListenerStageSubmitted stageSubmitted)
          Called when a stage is submitted
 void onTaskEnd(SparkListenerTaskEnd taskEnd)
          Called when a task ends
 void onTaskGettingResult(SparkListenerTaskGettingResult taskGettingResult)
          Called when a task begins remotely fetching its result (will not be called for tasks that do not need to fetch the result remotely).
 void onTaskStart(SparkListenerTaskStart taskStart)
          Called when a task starts
 void onUnpersistRDD(SparkListenerUnpersistRDD unpersistRDD)
          Called when an RDD is manually unpersisted by the application
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaSparkListener

public JavaSparkListener()
Method Detail

onStageCompleted

public void onStageCompleted(SparkListenerStageCompleted stageCompleted)
Description copied from interface: SparkListener
Called when a stage completes successfully or fails, with information on the completed stage.

Specified by:
onStageCompleted in interface SparkListener
Parameters:
stageCompleted - (undocumented)

onStageSubmitted

public void onStageSubmitted(SparkListenerStageSubmitted stageSubmitted)
Description copied from interface: SparkListener
Called when a stage is submitted

Specified by:
onStageSubmitted in interface SparkListener
Parameters:
stageSubmitted - (undocumented)

onTaskStart

public void onTaskStart(SparkListenerTaskStart taskStart)
Description copied from interface: SparkListener
Called when a task starts

Specified by:
onTaskStart in interface SparkListener
Parameters:
taskStart - (undocumented)

onTaskGettingResult

public void onTaskGettingResult(SparkListenerTaskGettingResult taskGettingResult)
Description copied from interface: SparkListener
Called when a task begins remotely fetching its result (will not be called for tasks that do not need to fetch the result remotely).

Specified by:
onTaskGettingResult in interface SparkListener
Parameters:
taskGettingResult - (undocumented)

onTaskEnd

public void onTaskEnd(SparkListenerTaskEnd taskEnd)
Description copied from interface: SparkListener
Called when a task ends

Specified by:
onTaskEnd in interface SparkListener
Parameters:
taskEnd - (undocumented)

onJobStart

public void onJobStart(SparkListenerJobStart jobStart)
Description copied from interface: SparkListener
Called when a job starts

Specified by:
onJobStart in interface SparkListener
Parameters:
jobStart - (undocumented)

onJobEnd

public void onJobEnd(SparkListenerJobEnd jobEnd)
Description copied from interface: SparkListener
Called when a job ends

Specified by:
onJobEnd in interface SparkListener
Parameters:
jobEnd - (undocumented)

onEnvironmentUpdate

public void onEnvironmentUpdate(SparkListenerEnvironmentUpdate environmentUpdate)
Description copied from interface: SparkListener
Called when environment properties have been updated

Specified by:
onEnvironmentUpdate in interface SparkListener
Parameters:
environmentUpdate - (undocumented)

onBlockManagerAdded

public void onBlockManagerAdded(SparkListenerBlockManagerAdded blockManagerAdded)
Description copied from interface: SparkListener
Called when a new block manager has joined

Specified by:
onBlockManagerAdded in interface SparkListener
Parameters:
blockManagerAdded - (undocumented)

onBlockManagerRemoved

public void onBlockManagerRemoved(SparkListenerBlockManagerRemoved blockManagerRemoved)
Description copied from interface: SparkListener
Called when an existing block manager has been removed

Specified by:
onBlockManagerRemoved in interface SparkListener
Parameters:
blockManagerRemoved - (undocumented)

onUnpersistRDD

public void onUnpersistRDD(SparkListenerUnpersistRDD unpersistRDD)
Description copied from interface: SparkListener
Called when an RDD is manually unpersisted by the application

Specified by:
onUnpersistRDD in interface SparkListener
Parameters:
unpersistRDD - (undocumented)

onApplicationStart

public void onApplicationStart(SparkListenerApplicationStart applicationStart)
Description copied from interface: SparkListener
Called when the application starts

Specified by:
onApplicationStart in interface SparkListener
Parameters:
applicationStart - (undocumented)

onApplicationEnd

public void onApplicationEnd(SparkListenerApplicationEnd applicationEnd)
Description copied from interface: SparkListener
Called when the application ends

Specified by:
onApplicationEnd in interface SparkListener
Parameters:
applicationEnd - (undocumented)

onExecutorMetricsUpdate

public void onExecutorMetricsUpdate(SparkListenerExecutorMetricsUpdate executorMetricsUpdate)
Description copied from interface: SparkListener
Called when the driver receives task metrics from an executor in a heartbeat.

Specified by:
onExecutorMetricsUpdate in interface SparkListener
Parameters:
executorMetricsUpdate - (undocumented)

onExecutorAdded

public void onExecutorAdded(SparkListenerExecutorAdded executorAdded)
Description copied from interface: SparkListener
Called when the driver registers a new executor.

Specified by:
onExecutorAdded in interface SparkListener
Parameters:
executorAdded - (undocumented)

onExecutorRemoved

public void onExecutorRemoved(SparkListenerExecutorRemoved executorRemoved)
Description copied from interface: SparkListener
Called when the driver removes an executor.

Specified by:
onExecutorRemoved in interface SparkListener
Parameters:
executorRemoved - (undocumented)