mjsax commented on PR #21304: URL: https://github.com/apache/kafka/pull/21304#issuecomment-3873815264
@UladzislauBlok -- I was just thinking about this more, and it seems it's less straightforward? I believe, the goal of the current impl is to setup a guard: We want to ensure that the key is indeed fixed. The existing class is `final` so it cannot be extended what prevent users to side-step the guard via a sub-class. KS code creates in instance of `FixKeyRecord` controlling the key, and passes it into `process(...)` method, and users are forced to re-use the passed in object, ensuring that the key cannot be modified. Changing the class to an interface, would open the door to change the key via user's implementation of the interface, and thus remove the guard we have in place... Thoughts? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
