note
event time
数据中附带的时间
延迟稍高(因为数据乱序以及数据晚到)
process time
和机器有关,某个operator收到数据的时间
window会自动对齐
window components
3 parts:
- 分组 (为下游算子多实例并行计算提供可能性)
- 窗口分配器(WindowAssigner)
- 触发器 (window function: reduce,aggregate,process)
- 清除器
可自定义,否则就使用默认的配置
window type
-
分类 tumbling window no overlap sliding window with overlap session window punctuated by a gap of inactivity 窗口的长度是可变的,每个窗口的开始和结束时间并不是确定的。
-
time-based window TimeWIndow: [startTime, endTime) time driving
-
count-based window data driving