Skip to content

demanejar/spark-streaming-kafka-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

spark-streaming-kafka-demo

Demo Spark Streaming Consumer read data from kafka

Enable Kafka and create 1 topic with name "topic-1":

bin/kafka-topics.sh --create --topic topic-1 --bootstrap-server localhost:9092

Create producer:

bin/kafka-console-producer.sh --topic topic-1 --bootstrap-server localhost:9092

Build project to file .jar:

mvn clean package

Run file .jar in Spark with spark-submit:

spark-submit --class demo.sparkstreaming.StreamingConsumer target/SparkStreamingDemo-V1-jar-with-dependencies.jar

About

Demo Spark Streaming consumer read data from Kafka

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages