I have two unbounded streams each with a 2 minute window and AfterWatermark.pastEndOfWindow()
trigger. After checking the results from an outer join it seems that the windows are not aligned. Beam aligns the data on the left side of the join, but takes data on the right across 4 minute overlapping intervals:
Stream A |--| (observed range after join from window 1)
|--| (observed range after join from window 2)
|--| (observed range after join from window 3)
Stream B |----| (observed range after join from window 1)
|----| (observed range after join from window 2)
|----| (observed range after join from window 3)
So for example window 1 has events from Stream A for 0-2 time period (as expected) and events from Stream B from 0-4 time period, and in window 2, I got events from Stream A time period 2-4 and Stream B, time period 2-6.
How Beam decided which window the data goes, in a join coming from two fixed windows, which are not aligned?