Class MockTwitterStreamRandom

All Implemented Interfaces:
Runnable, Flow.Publisher<com.twitter.clientlib.model.Tweet>

public final class MockTwitterStreamRandom extends OfflineTweetsProducer
Mimics the TwitterStreamSampleReaderSingleton class. To be used when the Twitter sampled stream rate limit is exceeded for instance. Creates a continuous stream of random Tweets.
Author:
Virginie Galtier
  • Constructor Details

    • MockTwitterStreamRandom

      public MockTwitterStreamRandom()
      Creates a new MockTwitterStreamRandom.
  • Method Details

    • run

      public void run()
      Posts random Tweets to the
      invalid reference
      distributed_tweetoscope.TweetoscopeAppConfig#TWEETS_TOPIC_NAME
      Kafka topic. A random Tweet text is a concatenation of hashtags chosen from a reduced set. The Tweet is also assigned a language among a reduced list.