I am looking at the example producer code for kafka 0.8. I notice it is possible to specify a key when creating KeyedMessage. This key will be used for assigning the message to some partition. I wonder if the key will be received by the consumer. Thanks. Libo
Thanks for both of you. The key is actually very useful. If the key increases monotonically, it can be used as the version of the message. Say version 1 is sent first followed by version 2. It is possible that version 2 is received first by the consumer. When version 1 is received, it will be ignored if version 2 has already been received. Regards,
Note that the key is provided by the application. Kafka itself makes no effort to make sure messages are in key order.
Jun On Mon, May 13, 2013 at 8:34 AM, Yu, Libo <[EMAIL PROTECTED]> wrote:
Jun Rao 2013-05-13, 16:27
NEW: Monitor These Apps!
Apache Lucene, Apache Solr and all other Apache Software Foundation projects and their respective logos are trademarks of the Apache Software Foundation.
Elasticsearch, Kibana, Logstash, and Beats are trademarks of Elasticsearch BV, registered in the U.S. and in other countries. This site and Sematext Group is in no way affiliated with Elasticsearch BV.
Service operated by Sematext