You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "Michael Koepf (Jira)" <ji...@apache.org> on 2026/10/21 13:44:00 UTC
[jira] [Commented] (KAFKA-21324) Wrong parameter order in private ctor of WindowKeyQuery
[ https://issues.apache.org/jira/browse/KAFKA-21324?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18129669#comment-18129669 ]
Michael Koepf commented on KAFKA-21324:
---------------------------------------
cc: [~alisa23] since you confirmed it's [a real bug|https://issues.apache.org/jira/browse/KAFKA-20705]. wdyt? should we backport this?
> Wrong parameter order in private ctor of WindowKeyQuery
> -------------------------------------------------------
>
> Key: KAFKA-21324
> URL: https://issues.apache.org/jira/browse/KAFKA-21324
> Project: Kafka
> Issue Type: Bug
> Components: streams
> Affects Versions: 3.2.3, 3.3.2, 3.4.1, 3.5.2, 3.6.2, 3.7.2, 3.8.1, 3.9.2, 4.0.2, 4.1.2, 4.3.1, 4.2.2
> Reporter: Michael Koepf
> Priority: Major
>
> {{{{streams/src/main/java/org/apache/kafka/streams/query/WindowKeyQuery.java}} has the wrong parameter order in the {{private}} ctor. The builder method withKeyAndWindowStartRange invokes the constructor with}}
> {{new WindowKeyQuery<>(key, {*}Optional.of(timeFrom), Optional.of(timeTo){*})}}
> while the order is
> {{private WindowKeyQuery(final K key, {*}final Optional<Instant> timeTo, final Optional<Instant> timeFrom{*})}}
> The actual order should be
> {{private WindowKeyQuery(final K key, {*}final Optional<Instant> timeFrom, final Optional<Instant> timeTo{*})}}
> While this has been noticed and fixed on the trunk branch as part of [KAKFA-20705|https://issues.apache.org/jira/browse/KAFKA-20705], there is no dedicated issue nor it's fixed in already released Kafka versions.
> Could we backport this, at least for Kafka 4.x? I'd be willing to submit a PR.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)