1
這是intentioal在卡夫卡0.8.2.0版本,org.apache.kafka.clients.consumer.KafkaConsumer,方法:卡夫卡消費者0.8.2.0投票錯誤
public Map<String, ConsumerRecords<K, V>> poll(long timeout) {
return null;
}
0.8.xx的哪個版本我用?
這是intentioal在卡夫卡0.8.2.0版本,org.apache.kafka.clients.consumer.KafkaConsumer,方法:卡夫卡消費者0.8.2.0投票錯誤
public Map<String, ConsumerRecords<K, V>> poll(long timeout) {
return null;
}
0.8.xx的哪個版本我用?
我剛剛意識到上面的方法和許多這樣的方法不僅僅是在0.8-x.x版本的Kafka中實現的,它們僅在0.9.0.0版本之後纔可用!因此,這意味着我應該使用下列內容:
https://cwiki.apache.org/confluence/display/KAFKA/Consumer+Group+Example
關於如何寫一個卡夫卡的消費者做參考!