Skip to content

A spark streaming sample running in HDInsight spark 2.2 to pull data from eventhubs

Notifications You must be signed in to change notification settings

xiopeter3345/spark-streaming-eventhub-sample

Repository files navigation

spark-streaming-eventhub-sample

A spark streaming sample running in HDInsight spark 2.2 to pull data from eventhubs

1. Prepare Environment
2. Compile and Run the sample
  • Compile

    ssh to head node and execute the following commands to download the program and compile:

    git clone https://github.com/xiopeter3345/spark-streaming-eventhub-sample.git cd spark-streaming-eventhub-sample sbt clean sbt compile sbt package

    The generated jar file will be generated to ./target/scala-2.11

  • Run the program

    cd ./target/scala-2.11

    spark-submit --master yarn-cluster --class com.microsoft.css.lazhu.App --num-executors 1 --executor-memory 1G --executor-cores 1 --driver-memory 1G spark-streaming_2.11-1.0.jar

  • Event Hub sender CDRecord.cs and Program.cs are C# sample code to send JSON format to event hub. Please make sure connection string is correctly set.

About

A spark streaming sample running in HDInsight spark 2.2 to pull data from eventhubs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published