You could use ValueState (keyed by key) to store the event. And when each event arrives, check the value in the State to determine if either of "Field1" or "Field2" has changed. If either of the fields have changed, update the state with the new event and perform the trigger (emitting the modified event) operation. If neither has changed don't do anything (leave State alone)
On Tue, Jul 30, 2019 at 11:03 AM Yoandy Rodríguez <[hidden email]> wrote:
I have a stream of events in the form (key, field1, field2) and I would
like to detect every time field2 value changes and emit a new
event on another stream. I searched StackOverflow and  was the
closest to my use case but not quite since I don't have a pattern
Is it possible to express something like this using Flink?