[
https://issues.apache.org/jira/browse/FLINK-8322?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16304285#comment-16304285
]
Bowen Li edited comment on FLINK-8322 at 12/27/17 7:17 AM:
-----------------------------------------------------------
This might be a followup of [this email
thread|http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/Why-TimerService-interface-in-ProcessFunction-doesn-t-have-deleteEventTimeTimer-td12719.html]
According to my research, this can be done by exposing
{{numProcessingTimeTimers(N namespace)}} and {{numEventTimeTimers(N
namespace)}}. But their performance is both {{O[n]}}, which seems to be a bit
inefficient and thus falls to the same situation with {{delete()}} that we may
not want to expose to users.
[~StephanEwen] [~aljoscha] Any suggestions?
was (Author: phoenixjiangnan):
This might be a followup of [this email
thread|http://apache-flink-user-mailing-list-archive.2336050.n4.nabble.com/Why-TimerService-interface-in-ProcessFunction-doesn-t-have-deleteEventTimeTimer-td12719.html]
According to my research, this can be done by exposing
{{numProcessingTimeTimers(N namespace)}} and {{numEventTimeTimers(N
namespace)}}. But their performance is both {{O(n)}}, which seems to be a bit
inefficient and thus falls to the same situation with {{delete()}} that we may
not want to expose to users.
[~StephanEwen] [~aljoscha] Any suggestions?
> support getting number of existing timers in TimerService
> ---------------------------------------------------------
>
> Key: FLINK-8322
> URL: https://issues.apache.org/jira/browse/FLINK-8322
> Project: Flink
> Issue Type: Improvement
> Components: DataStream API
> Affects Versions: 1.4.0
> Reporter: Bowen Li
> Assignee: Bowen Li
>
> We have the use cases where we want to use timers as scheduled threads - e.g.
> add a timer to wake up x hours later and do something (reap old data usualy)
> only if there's no existing timers, basically we only want at most 1 timer
> exists for the key all the time
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)