0xffff-zhiyan commented on code in PR #22805:
URL: https://github.com/apache/kafka/pull/22805#discussion_r3618055242
##########
core/src/main/scala/kafka/server/DynamicBrokerConfig.scala:
##########
@@ -106,7 +107,7 @@ object DynamicBrokerConfig {
Using.resource(
RecordsSnapshotReader.of(
rawSnapshotReader,
- raftManager.recordSerde,
+ RecordsDecodingStrategy.dataAndControl(raftManager.recordSerde),
Review Comment:
I see. I notice that this problem only applies to `RecordsSnapshotReader`.
What about we split `RecordsSnapshotReader` into two different factory
methods. External callers keep using the original `of(...)`, which takes a
`RecordSerde` directly so they don't need to set decoding strategy and raft
internal callers use a new `ofDecodingStrategy(...)`, which takes a
`RecordsDecodingStrategy` so they can pick `controlOnly()` etc. WDYT?
--
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]