Hi Senthilnathan, In the motivation isn't it a little misleading to say "On the producer side, we clearly preserve an order for the two messages, <K1, V1> <K1, V2>"? IMHO, the semantics of the producer are clear that having an observed order of sending records from different producers is not sufficient to guarantee ordering on the broker. You really need to send the 2nd record only after the 1st record is acked. It's the difficultly of achieving that in practice that's the true motivation for your KIP.
I can see the attraction of using timestamps, but it would be helpful to explain how that really solves the problem. When the producers are in different processes on different machines you're relying on their clocks being synchronized, which is a whole subject in itself. Even if they're synchronized the resolution of System.currentTimeMillis() is typically many milliseconds. If your producers are in different threads of the same process that could be a real problem because it makes ties quite likely. And you don't explain why it's OK to resolve ties using the offset. The basis of your argument is that the offset is giving you the wrong answer. So it seems to me that using it as a tiebreaker is just narrowing the chances of getting the wrong answer. Maybe none of this matters for your use case, but I think it should be spelled out in the KIP, because it surely would matter for similar use cases. Using a sequence at least removes the problem of ties, but the interesting bit is now in how you deal with races between threads/processes in getting a sequence number allocated (which is out of scope of the KIP, I guess). How is resolving that race any simpler that resolving the motivating race by waiting for the ack of the first record sent? Kind regards, Tom On Mon, Oct 21, 2019 at 9:06 PM Senthilnathan Muthusamy <senth...@microsoft.com.invalid> wrote: > Hi All, > > We are bring back the KIP-280 to live with small correct for the > discussion & voting. Thanks to previous author Luis Cabral on the KIP-280 > initiation and we are taking over to complete and get it into 2.4... > > Below is the correction that we made to the existing KIP-280: > > * Allowing the compact strategy configuration at the topic level as > the log compaction is at the topic level and a broker can have multiple > topics. This allows the flexibility to have the strategy at both broker > level (i.e. for all topics within the broker) and topic level (i.e. for a > subset of topics within a broker) as well... > > KIP-280: > https://cwiki.apache.org/confluence/display/KAFKA/KIP-280%3A+Enhanced+log+compaction > PULL REQUEST: https://github.com/apache/kafka/pull/7528 (unit test > coverage in progress) > > Previous Thread DISCUSS: > https://lists.apache.org/thread.html/79aa6e50d7c737ddf83455dd8063692a535a1afa558620fe1a1496d3@%3Cdev.kafka.apache.org%3E > Previous Thread VOTE: > https://lists.apache.org/thread.html/b2ecd73ce849741f0c40b4f801c3f7650583497812713e240e1ac2b7@%3Cdev.kafka.apache.org%3E > > Appreciate your timely action. > > PS: Initiating a separate thread as I was not able to reply to the > existing threads... > > Thanks, > Senthil >