This application streams real time tweets by any topic(s) using Twitter Hosebird Client that is build on kafka.
- Java 8
- Maven
- Kafka
Clone this repository and install all dependencies.
# Install all dependencies using Maven
$ mvn install
- Create a Twitter app and generate the necessary secret keys.
- Include the generated keys in the Producer class.
In order to send tweets to the producer we have to start Zookeeper and Kafka.
# Start Zookeeper
$ zookeeper-server-start.bat config\zookeeper.properties
# Start Kafka
$ kafka-server-start.bat config\server.properties
# Create a topic
$ kafka-topics.bat --zookeeper 127.0.01:2181 --create --topic <YOUT TOPIC HERE> -partitions 6 --replication-factor 1
Now you can start the application.