Example: Processing MapR Streams with Storm
The Storm installation directory contains example programs. stormStreamsTest is an example program that integrate Storm with MapR Streams.
The stormStreamsTest example performs the following steps:
- Reads messages from a topic.
- Calculates amount of message passed through the topology in 5 seconds.
- Sends the calculated number of messages to a topic.
- Sends a copy of the source data to a topic.
For more information, see the source code and a README file in the following location:
/opt/mapr/storm/storm-<version>/examples/stormStreamsTest
.
storm jar [jar file] [topology][zookeeperHost:port] [bootstrap server host:port] [use kafka
09 API: true/false] [topic to read from] [topic to write to] [topic to send duplicated
source data]
The
[zookeeperHost:port] and [bootstrapServer:port] are ignored when you run submit the Storm
topology to MapR Streams. Regardless, including the placeholder text is required.storm jar storm-streams-test-1.0-jar-with-dependencies.jar storm.example.DemoTopology
localhost:5181 localhost:9092 true /streaming_data/marlin:events
/streaming_data/marlin:average /streaming_data/marlin:trash