Uploaded image for project: 'Zeppelin'
  1. Zeppelin
  2. ZEPPELIN-4128

Zeppelin - unable to stop spark streaming query when awaitTermination is used.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 0.8.1
    • None
    • Interpreters
    • None

    Description

      When basic spark streaming  example with zeppelin  is executed, its not been possible to stop the paragraph once its started.

      cancel/stop the paragraph is not stopping the execution.

      Sample code executed in zeppelin paragraph:

      import org.apache.spark.sql.functions._
      import org.apache.spark.sql.SparkSession

      val spark = SparkSession.builder.appName("StructuredNetworkWordCount").getOrCreate()

      import spark.implicits._

      val lines = spark.readStream.format("socket").option("host", "localhost").option("port", 9999).load()

      // Split the lines into words
      val words = lines.as[String].flatMap(_.split(" "))

      // Generate running word count
      val wordCounts = words.groupBy("value").count()

      val query = wordCounts.writeStream.outputMode("complete").format("console").start()

      query.awaitTermination()

       

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            srini.daruna Srinivasarao Daruna
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: