cloud-fan commented on code in PR #35799:
URL: https://github.com/apache/spark/pull/35799#discussion_r2487509416


##########
streaming/src/main/scala/org/apache/spark/streaming/StreamingContext.scala:
##########
@@ -622,6 +621,27 @@ class StreamingContext private[streaming] (
     }
   }
 
+  /**
+   * Registers streaming listeners specified in spark.streaming.extraListeners.
+   */
+  private def registerExtraStreamingListener(): Unit = {
+    try {
+      conf.get(STREAMING_EXTRA_LISTENERS).foreach { classNames =>
+        val listeners = Utils.loadExtensions(classOf[StreamingListener], 
classNames, conf)
+        listeners.foreach { listener =>
+          addStreamingListener(listener)
+          logInfo(s"Registered streaming listener 
${listener.getClass().getName()}")
+        }
+      }
+    } catch {
+      case e: Exception =>
+        try {
+          stop()

Review Comment:
   is it also how to handle normal spark listeners? We fail the entire Spark 
application if any listener fails to be registered?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to