Hi Sagar

I implemented a very similar interface for KIP-213, the foreign-key joiner.
We pulled it out of the final implementation and instead used RocksDB range
instead. You can see the particular code where we use RocksDB.range(...) to
get the same iterator result.

https://github.com/apache/kafka/blob/trunk/streams/src/main/java/org/apache/kafka/streams/kstream/internals/foreignkeyjoin/ForeignJoinSubscriptionProcessorSupplier.java#L95

We pulled it out because there were numerous awkward acrobatics to
integrate *prefixSeek()* function into the Kafka Streams code. Basically, I
wanted to be able to access *prefixSeek()* the same way I can access
*range()* for any state store, and in particular use it for storing data
with a particular foreign key (as per the previous URL). However, I found
out that it required way too many changes to expose the *prefixSeek()*
functionality while still being able to leverage all the nice Kafka Streams
state management + supplier functionality, so we made a decision just to
stick with *range()* and pull everything else out.

I guess my question here is, how do you anticipate using *prefixSeek()*
within the framework of Kafka Streams, or the Processor API?

Adam



On Tue, May 12, 2020 at 2:52 AM Sagar <sagarmeansoc...@gmail.com> wrote:

> Hi All,
>
> I would like to start a discussion on the KIP that I created below to add
> prefix scan support in State Stores:
>
>
> https://cwiki.apache.org/confluence/display/KAFKA/KIP-614%3A+Add+Prefix+Scan+support+for+State+Stores
>
> Thanks!
> Sagar.
>

Reply via email to