Skip to content

Commit

Permalink
address the comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Prabeesh K committed Jul 30, 2015
1 parent b90b709 commit 126608a
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions examples/src/main/python/streaming/mqtt_wordcount.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,14 @@
"""
A sample wordcount with MqttStream stream
Usage: mqtt_wordcount.py <broker url> <topic>
To work with Mqtt, Mqtt Message broker/server required.
Mosquitto (http://mosquitto.org/) is an open source Mqtt Broker
In ubuntu mosquitto can be installed using the command `$ sudo apt-get install mosquitto`
Run Mqtt publisher as
`$ bin/run-example \
org.apache.spark.examples.streaming.MQTTPublisher tcp://localhost:1883 foo`
and then run the example as
To run this in your local machine, you need to setup a MQTT broker and publisher first,
Mosquitto is one of the open source MQTT Brokers, see
http://mosquitto.org/
Eclipse paho project provides number of clients and utilities for working with MQTT, see
http://www.eclipse.org/paho/#getting-started
and then run the example
`$ bin/spark-submit --jars external/mqtt-assembly/target/scala-*/\
spark-streaming-mqtt-assembly-*.jar examples/src/main/python/streaming/mqtt_wordcount.py \
tcp://localhost:1883 foo`
Expand Down

0 comments on commit 126608a

Please sign in to comment.