Hi All,
I was playing with queryable state. As queryable stream can not be modified how do I use the output of say my reduce function for further processing. Below is 1 example. I am sure I have done it wrong :). I am using reduce function twice or do I need to use rich reduce function and use the queryable state there. Thanks public class reducetest { |
Hi All,
I was playing with queryable state. As queryable stream can not be modified how do I use the output of say my reduce function for further processing. Below is 1 example. I can see that I am processing the data twice. One for the Queryable stream and once for the my original stream. That means state will be kept twice as well? In simple term I would like to query the state from rf reduce function and I would like my stream to be written to Kafka. If I use like below I am able to do so but it seems to me that there is duplicate state storing as well as duplicate work is being done. Is there any alternate for what I am trying to achieve this? Thanks public class reducetest { |
I have used connected streams where one part of the connected stream maintains state and the other part consumes it.
However it was not queryable externally. For state that is queryable externally you are right you probably need another operator to store state and support query-ability.
Sent from my iPhone
|
Free forum by Nabble | Edit this page |