Class TwitterKafkaFilter

java.lang.Object
tweetoscope.tweetsFilter.TwitterKafkaFilter

public final class TwitterKafkaFilter extends Object
Reacts to the reception of a new Tweet, if the Tweet matches the filter condition, downstream subscribers are notified, otherwise the process is silent. Tweets are received from
invalid reference
distributed_tweetoscope.tweetsProducer.TweetsProducer
via Java Flow. Filtered Tweets are passes down to the
invalid reference
distributed_tweetoscope.HashtagCounter
via Java Flow.
Author:
Virginie Galtier
  • Field Details

    • consumer

      protected static org.apache.kafka.clients.consumer.KafkaConsumer<Void,String> consumer
    • producer

      protected static org.apache.kafka.clients.producer.KafkaProducer<Void,String> producer
    • bootstrapServers

      protected String bootstrapServers
    • tweetTopic

      protected String tweetTopic
    • filteredTopic

      protected String filteredTopic
    • tweetsFilter

      protected TweetFilter tweetsFilter
  • Constructor Details

    • TwitterKafkaFilter

      public TwitterKafkaFilter(String bootstrapServers, String tweetTopic, String filteredTopic, String filterType, String filterCriteria)
  • Method Details

    • main

      public static void main(String[] arg)