flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From M Singh <mans2si...@yahoo.com>
Subject Re: Apache Flink - Manipulating the state of an object in an evictor or trigger
Date Fri, 19 Jul 2019 18:34:38 GMT
I am asking this question, just to understand the impact and best practices around it.  The
state I am referring to it the objects that are passed to evictor.

void evictBefore(Iterable<TimestampedValue<T>> elements, int size, W window, EvictorContext
And you are right, I also don't see this in this information in the docs.  That is the reason
I wanted to find out.
Thanks again for your time.
    On Friday, July 19, 2019, 02:15:02 AM EDT, Biao Liu <mmyy1110@gmail.com> wrote:
I don't find any official document about it.
There are several state relevant methods in `TriggerContext`. I believe it's absolutely safe
to use state in `Trigger` through `TriggerContext`.
Regarding to `Evictor`, there is no such methods in `EvictorContext`. After taking a glance
on relevant codes, I guess it's OK for now. But I suggest do not manipulate state in `Evictor`
until there is an official guarantee.
BTW, I'm just wondering why do you want to manipulate state in `Evictor`? If your requirement
is reasonable, maybe we could support it officially.

M Singh <mans2singh@yahoo.com> 于2019年7月14日周日 下午9:07写道:

Is it safe to manipulate the state of an object in the evictor or trigger ?  Are there any
best practices/dos and don't on this ?
View raw message