Search in sources :

Example 1 with StringScheme

use of org.apache.storm.kafka.StringScheme in project storm by apache.

the class TridentKafkaWordCount method newTridentKafkaConfig.

private static TridentKafkaConfig newTridentKafkaConfig(String zkUrl) {
    ZkHosts hosts = new ZkHosts(zkUrl);
    TridentKafkaConfig config = new TridentKafkaConfig(hosts, "test");
    config.scheme = new SchemeAsMultiScheme(new StringScheme());
    // Consume new data from the topic
    config.startOffsetTime = kafka.api.OffsetRequest.LatestTime();
    return config;
}
Also used : ZkHosts(org.apache.storm.kafka.ZkHosts) SchemeAsMultiScheme(org.apache.storm.spout.SchemeAsMultiScheme) StringScheme(org.apache.storm.kafka.StringScheme)

Aggregations

StringScheme (org.apache.storm.kafka.StringScheme)1 ZkHosts (org.apache.storm.kafka.ZkHosts)1 SchemeAsMultiScheme (org.apache.storm.spout.SchemeAsMultiScheme)1