mjsax commented on code in PR #21768:
URL: https://github.com/apache/kafka/pull/21768#discussion_r2944198195
##########
streams/src/main/java/org/apache/kafka/streams/state/internals/MeteredTimestampedKeyValueStoreWithHeaders.java:
##########
@@ -294,9 +338,10 @@ private <R> QueryResult<R> runTimestampedRangeQuery(final
Query<R> query,
if (rawResult.isSuccess()) {
final KeyValueIterator<Bytes, byte[]> iterator =
rawResult.getResult();
final KeyValueIterator<K, ValueAndTimestamp<V>> resultIterator =
- (KeyValueIterator<K, ValueAndTimestamp<V>>) new
MeteredTimestampedKeyValueStoreWithHeadersIterator(
+ (KeyValueIterator<K, ValueAndTimestamp<V>>) new
MeteredTimestampedKeyValueStoreWithHeadersQueryIterator(
Review Comment:
It's because of backward compatibility in the DSL. There is existing code,
which uses IQ to access the state stores, and it expects to get back
`ValueAndTimestamp` type. We change all the DSL code to use
metered/caching/changelogging-header-stores and only keep the inner-most
byte-store the default ts-store.
Thus, if users upgrade to 4.3, nothing should change for them, and thus we
cannot just start to return `ValueTimestampHeaders` type -- this would break
app even if they do not enable header stores in the DSL.
Does this make sense? -- It's known feature gap that IQ will not allow to
query header with AK 4.3, and it's something we need a followup KIP to add.
--
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]