Hi,
Thanks for adding the detail. It seems quite straightforward to
implement in the producer code.

AS1: Personally, and of course this is a matter of taste and just one
opinion, I don’t like adding Headers to RecordMetadata. It seems to me
that RecordMetadata is information about the record that’s been produced
whereas the Headers are really part of the record itself. So, I prefer the
alternative which overloads ProducerInterceptor.onAcknowledgement.

AS2: ProducerBatch and FutureRecordMetadata are both internal classes
and do not need to be documented in the KIP.

AS3: This KIP is adding rather than replcaing the constructor for 
RecordMetadata.
You should define the value for the Headers if an existing constructor
without headers is used.

AS4: You should add a method `Headers headers()` to RecordMetadata.


I wonder what other community members think about whether it’s a good
idea to extend RecordMetadata with the headers.

Thanks,
Andrew

> On 29 Jul 2024, at 05:36, Rich C. <chenjy.r...@gmail.com> wrote:
>
> Hi all,
>
> Thank you for the positive feedback. I added proposal changes to KIP-512
> and included a FAQ section to address some concerns.
>
> Hi Andrew, yes, this KIP focuses on
> `ProducerInterceptor.onAcknowledgement`. I added FAQ#3 to explain that.
>
> Hi Matthias, for your question about "RecordMetadata being Kafka metadata" in
> this thread
> <https://lists.apache.org/list?dev@kafka.apache.org:lte=1M:make%20Record%20Headers%20available%20in%20onAcknowledgement>,
> I added FAQ#2 to explain that. If I have missed any documentation regarding
> the design of RecordMetadata, please let me know.
>
> Regards,
> Rich
>
>
> On Fri, Jul 26, 2024 at 4:00 PM Andrew Schofield <andrew_schofi...@live.com>
> wrote:
>
>> Hi Rich,
>> Thanks for resurrecting this KIP. It seems like a useful idea to me and
>> I’d be interested in seeing the proposed public interfaces.
>>
>> I note that you specifically called out the
>> ProducerInterceptor.onAcknowledgement
>> method, as opposed to the producer Callback.onCompletion method.
>>
>> Thanks,
>> Andrew
>>
>>> On 26 Jul 2024, at 04:54, Rich C. <chenjy.r...@gmail.com> wrote:
>>>
>>> Hi Kevin,
>>>
>>> Thanks for your support.
>>>
>>> Hi Matthias,
>>>
>>> I apologize for the confusion. I've deleted the Public Interface sections
>>> for now. I think we should focus on discussing its necessity with the
>>> community. I'll let it sit for a few more days, and if there are no
>>> objections, I will propose changes over the weekend and share them here
>>> again.
>>>
>>> Regards,
>>> Rich
>>>
>>>
>>> On Thu, Jul 25, 2024 at 5:51 PM Matthias J. Sax <mj...@apache.org>
>> wrote:
>>>
>>>> Rich,
>>>>
>>>> thanks for resurrecting this KIP. I was not part of the original
>>>> discussion back in the day, but personally agree with your assessment
>>>> that making headers available in the callbacks would make developer's
>>>> life much simpler.
>>>>
>>>> For the KIP itself, starting with "Public Interface" section, everything
>>>> is formatted as "strike through". Can you fix this? It's confusing as
>>>> it's apparently not correctly formatted, but unclear which (if any)
>>>> parts should be formatted like this. In general, wiki pages have
>>>> history, so strike-through should be used rather rarely but the wiki
>>>> page should just contain the latest proposal. (If one want to see the
>>>> history, it's there anyway).
>>>>
>>>>
>>>> -Matthias
>>>>
>>>> On 7/23/24 6:36 AM, Kevin Lam wrote:
>>>>> Hi,
>>>>>
>>>>> Thanks for starting the discussion. Latency Measurement and Tracing
>>>>> Completeness are both good reasons to support this feature, and would
>> be
>>>>> interested to see this move forward.
>>>>>
>>>>> On Mon, Jul 22, 2024 at 11:15 PM Rich C. <chenjy.r...@gmail.com>
>> wrote:
>>>>>
>>>>>> Hi Everyone,
>>>>>>
>>>>>> I hope this email finds you well.
>>>>>>
>>>>>> I would like to start a discussion on KIP-512. The initial version of
>>>>>> KIP-512 was created in 2019, and I have resurrected it in 2024 with
>> more
>>>>>> details about the motivation behind it.
>>>>>>
>>>>>> You can view the current version of the KIP here: KIP-512: Make Record
>>>>>> Headers Available in onAcknowledgement.
>>>>>> <
>>>>>>
>>>>
>> https://cwiki.apache.org/confluence/display/KAFKA/KIP-512%3A+make+Record+Headers+available+in+onAcknowledgement
>>>>>>>
>>>>>>
>>>>>> Let's focus on discussing the necessity of this feature first. If we
>>>> agree
>>>>>> on its importance, we can then move on to discussing the proposed
>>>> changes.
>>>>>>
>>>>>> Looking forward to your feedback.
>>>>>>
>>>>>> Best regards,
>>>>>> Rich


Reply via email to