KafkaConsumer.java 文件源码

java
阅读 29 收藏 0 点赞 0 评论 0

项目:dataflux 作者:
public KafkaConsumer(final String topic) {
    this.topic = topic;
    Properties props = null;
    try {

        //read in default configuration
        InputStream in = getClass().getResourceAsStream("/consumer.properties");

        props = new Properties();

        props.load(in);

        config = new ConsumerConfig(props);

        //in.close();
    } catch (IOException e) {
        e.printStackTrace();
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号