Hi Xingbo,

Thank you for your valuable suggestions.

Indeed, we need to provide clearer abstractions for StateDescriptor and State 
APIs, I have updated the FLIP accordingly. Looking forward to your feedbacks!

Best,
Shuiqiang

> 在 2020年12月14日,上午11:27,Xingbo Huang <hxbks...@gmail.com> 写道:
> 
> Thanks Shuiqiang for starting this discussion.
> 
> Big +1 for this feature. State access support can further improve the
> functionality of our existing Python DataStream.
> 
> I have 2 comments regarding to the design doc:
> 
> a) I think that `StateDescriptor` needs to hold the variable `typeInfo`
> instead of letting each implementation class hold `typeInfo` itself.For
> example, `ListStateDescriptor` does not hold `elem_type_info`, but passes
> `ListTypeInfo(elem_type_info)` to the construct method of `StateDescriptor`.
> 
> b) I think we need to add the `MergingState` and `AppendingState`
> interfaces, and then extract the `get` and `add` methods from `ListState`,
> `AggregatingState`, and `ReducingState` into `AppendingState`. Then let
> `ListState`, `AggregatingState` and `ReducingState` inherit `MergingState`.
> 
> Best,
> Xingbo
> 
> Shuiqiang Chen <acqua....@gmail.com> 于2020年12月11日周五 下午9:44写道:
> 
>> Hi devs,
>> 
>> In FLIP-130, we have already supported Python DataStream stateless APIs so
>> that users are able to perform some basic data transformations. To
>> implement more complex data processing, we need to provide state access
>> support. So I would propose to add state access APIs in Python DataStream
>> API to support stateful operations on a KeyedStream. More details are in
>> the FLIP wiki page [1].
>> 
>> Any feedback will be highly appreciated!
>> 
>> [1]
>> 
>> https://cwiki.apache.org/confluence/display/FLINK/FLIP-153%3A+Support+state+access+in+Python+DataStream+API
>> 
>> Best,
>> Shuiqiang
>> 

Reply via email to