[
https://issues.apache.org/jira/browse/FLINK-29692?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17714985#comment-17714985
]
Jark Wu commented on FLINK-29692:
---------------------------------
Hi [~charles-tan], thank you for sharing your use case. I'm just curious that
is it possible to support your use case by using Group Aggregate instead of
Window Aggregate? For example:
{code}
SELECT user, COUNT(*) as cnt
FROM withdrawal
GROUP BY
user,
DATE_FORMAT(withdrawal_timestamp, "yyyy-MM-dd HH:00") -- trim into hour
HAVING cnt >= 3
{code}
IIUC, this can also archive that "notified if a withdrawal from a bank account
happens 3 times in an hour" ASAP. And you may get better performance from the
tuning[1].
[1]: https://nightlies.apache.org/flink/flink-docs-master/docs/dev/table/tuning/
> Support early/late fires for Windowing TVFs
> -------------------------------------------
>
> Key: FLINK-29692
> URL: https://issues.apache.org/jira/browse/FLINK-29692
> Project: Flink
> Issue Type: New Feature
> Components: Table SQL / Planner
> Affects Versions: 1.15.3
> Reporter: Canope Nerda
> Priority: Major
>
> I have cases where I need to 1) output data as soon as possible and 2) handle
> late arriving data to achieve eventual correctness. In the logic, I need to
> do window deduplication which is based on Windowing TVFs and according to
> source code, early/late fires are not supported yet in Windowing TVFs.
> Actually 1) contradicts with 2). Without early/late fires, we had to
> compromise, either live with fresh incorrect data or tolerate excess latency
> for correctness.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)