aliehsaeedii commented on code in PR #21684:
URL: https://github.com/apache/kafka/pull/21684#discussion_r2915218134
##########
streams/src/main/java/org/apache/kafka/streams/state/internals/MeteredKeyValueStore.java:
##########
@@ -420,18 +432,26 @@ public void close() {
}
}
- protected V outerValue(final byte[] value) {
- return value != null ? serdes.valueFrom(value, new RecordHeaders()) :
null;
+ protected byte[] serializeValue(final V value) {
+ return value != null ? serdes.rawValue(value,
internalContext.headers()) : null;
Review Comment:
@mjsax
Regarding backward compability, I think this risk is very low because, most
serdes ignore headers - the default interface methods delegate to the
non-headers versions. Using `internalContext.headers()` is semantically
correct behavior - serdes should have access to record context.
1Q: should we check if `internalContext != null`?
--
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]