StreamingContext.
addStreamingListener
Add a [[org.apache.spark.streaming.scheduler.StreamingListener]] object for receiving system events related to streaming.