Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-11-02 Thread Hao Li
Thanks Hanyu! Make sense. I was mistaken that timestamp is also in the key for these queries. Hao On Mon, Oct 30, 2023 at 1:46 PM Hanyu (Peter) Zheng wrote: > Hi, Hao, > > For TimestampedKeyQuery, it only returns the value of the key, and the > value should be ValueAndTimestamp. > If you want

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-11-02 Thread Bill Bejeck
Hi Hanyu, One minor comment. Can you update the KIP to add the behavior when developer uses a TimestampedXQuery against a non-timestamped store? Thanks! Bill On Mon, Oct 30, 2023 at 4:46 PM Hanyu (Peter) Zheng wrote: > Hi, Hao, > > For TimestampedKeyQuery, it only returns the value of the

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-30 Thread Hanyu (Peter) Zheng
Hi, Hao, For TimestampedKeyQuery, it only returns the value of the key, and the value should be ValueAndTimestamp. If you want to get an iterator of `ValueAndTimestamp`, you can use TimestampedRangeQuery. Sincerely, Hanyu On Mon, Oct 30, 2023 at 1:42 PM Hanyu (Peter) Zheng wrote: > Hi,

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-30 Thread Hanyu (Peter) Zheng
Hi, Matthias, Now, if we use TimestampedKeyQuery to query kv-store, it will throw a exception, the exception like this: java.lang.IllegalArgumentException: Cannot get result for failed query. Sincerely, Hanyu On Thu, Oct 26, 2023 at 3:45 PM Hao Li wrote: > Thanks for the KIP Hanyu! One

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-26 Thread Hao Li
Thanks for the KIP Hanyu! One question: why not return an iterator of `ValueAndTimestamp` for `TimestampedKeyQuery`? I suppose for a ts-kv-store, there could be multiple timestamps associated with the same key? Hao On Thu, Oct 26, 2023 at 10:23 AM Matthias J. Sax wrote: > Would we really get a

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-26 Thread Matthias J. Sax
Would we really get a ClassCastException? From my understanding, the store would reject the query as unsupported and thus the returned `QueryResult` object would have it's internal flag set to indicate the failure, but no exception would be thrown directly? (Of course, there might be an

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-25 Thread Hanyu (Peter) Zheng
Hi, Bill, Thank you for your reply. Yes, now, if a user executes a timestamped query against a non-timestamped store, It will throw ClassCastException. If a user uses KeyQuery to query kv-store or ts-kv-store, it always return V. If a user uses TimestampedKeyQuery to query kv-store, it will throw

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-25 Thread Hanyu (Peter) Zheng
Thank you Lucas, I will fix the capitalization. When a user executes a timestamped query against a non-timestamped store, It will throw ClassCastException. Sincerely, Hanyu On Tue, Oct 24, 2023 at 1:36 AM Lucas Brutschy wrote: > Hi Hanyu, > > reading the KIP, I was wondering the same thing as

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-24 Thread Lucas Brutschy
Hi Hanyu, reading the KIP, I was wondering the same thing as Bill. Other than that, this looks good to me. Thanks for KIP. nit: you have method names `LowerBound` and `UpperBound`, where you probably want to fix the capitalization. Cheers, Lucas On Mon, Oct 23, 2023 at 5:46 PM Bill Bejeck

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-23 Thread Bill Bejeck
Hey Hanyu, Thanks for the KIP, it's a welcomed addition. Overall, the KIP looks good to me, I just have one comment. Can you discuss the expected behavior when a user executes a timestamped query against a non-timestamped store? I think it should throw an exception vs. using some default value.

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-20 Thread Hanyu (Peter) Zheng
Thank you Matthias, I will modify the KIP to eliminate this restriction. Sincerely, Hanyu On Fri, Oct 20, 2023 at 2:04 PM Hanyu (Peter) Zheng wrote: > Thank you Alieh, > > In these two new query types, I will remove 'get' from all getter method > names. > > Sincerely, > Hanyu > > On Fri, Oct

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-20 Thread Hanyu (Peter) Zheng
Thank you Alieh, In these two new query types, I will remove 'get' from all getter method names. Sincerely, Hanyu On Fri, Oct 20, 2023 at 10:40 AM Matthias J. Sax wrote: > Thanks for the KIP Hanyu, > > One questions: > > > To address this inconsistency, we propose that KeyQuery should be >

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-20 Thread Matthias J. Sax
Thanks for the KIP Hanyu, One questions: To address this inconsistency, we propose that KeyQuery should be restricted to querying kv-stores only, ensuring that it always returns a plain V type, making the behavior of the aforementioned code more predictable. Similarly, RangeQuery should

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-20 Thread Alieh Saeedi
Hey Hanyu, Thanks for the KIP. It seems good to me. Just one point: AFAIK, we are going to remove "get" from the name of all getter methods. Cheers, Alieh On Thu, Oct 19, 2023 at 5:44 PM Hanyu (Peter) Zheng wrote: > Hello everyone, > > I would like to start the discussion for KIP-992:

Re: [DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-19 Thread Hanyu (Peter) Zheng
Hello everyone, I would like to start the discussion for KIP-992: Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery The KIP can be found here:

[DISCUSS] KIP-992 Proposal to introduce IQv2 Query Types: TimestampedKeyQuery and TimestampedRangeQuery

2023-10-19 Thread Hanyu (Peter) Zheng
https://cwiki.apache.org/confluence/display/KAFKA/KIP-992%3A+Proposal+to+introduce+IQv2+Query+Types%3A+TimestampedKeyQuery+and+TimestampedRangeQuery -- [image: Confluent] Hanyu (Peter) Zheng he/him/his Software Engineer Intern +1 (213) 431-7193 <+1+(213)+431-7193>