You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Kamal C <ka...@gmail.com> on 2016/09/27 15:26:51 UTC

Log Compaction: How Key comparison works?

Hi all,

    The log compaction article [1] doesn't explains how key comparison
takes place. AFAIK, Kafka don't de-serialize the records and using MD5
algorithm. I'm using Kafka java client-v10. Could someone explain whether
the below statements are correct:

1. Key can be of any data-type ?
2. K1 == K1 returns true ?
3. K1.equals(K1) returns true ? (Even, if custom equals() and hashcode()
implemented)

[1]: https://cwiki.apache.org/confluence/display/KAFKA/Log+Compaction

- Kamal