Hi Could you please check whether the key and namespace are the same? when getting a result for the value state, Flink will use current key and current namespace to retrieve the result.
Best, Congxian Parth Sarathy <parth.sara...@microfocus.com> 于2019年12月22日周日 下午9:54写道: > Hi, > > I am using flink 1.8.2, event time stream for sliding window transformation > with custom trigger. Window size is 15 seconds, slide size is also 15 > seconds with 30 seconds allowed lateness. In the trigger implementation > couple of class level ValueStateDescriptors are used, the corresponding > ValueState variables are updated/initialized in the onElement method and > these are used in onEventTime method. On sending two records at 90 seconds > interval, with current time updated in timestamp field of the messages, > onEventTime method was called when the second record arrived, for the > window > with the first record, and in this method the values in the corresponding > ValueState variables were found to be null. When the two records were sent > with time difference of 75 seconds the values in the ValueStates were > present. > > What could be the reason for the values in ValueStates becoming null when > time difference between the messages was around 90 seconds or higher? I > checked that the TTL in the default StateTtlConfig is very high, so I am > not > sure why the states expired. > > Thanks, > Parth Sarathy > > > > -- > Sent from: > http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/ >