Hi I'm trying to make an alert system that matches following condition.
Each document has following fields.
- status # either 'incomplete' or 'complete'
- insert_time # timestamp when the document has been inserted
And the condition when I want alert to be sent is as follows.
select documents
- whose time difference between 'insert_time' and current_time stamp is greater than 20minutes
- whose status is incomplete.
My condition code is as follows.
( I haven't included 2) part here yet)
"condition": {
"compare": {
"((new Date().getTime()/1000)-doc['this_day'].value)/60" :
{ "gt" : 20
}
}
}
Alarm itself is working properly every one minute but not getting email. (not 'firing')
So I'm wondering what I've done wrong.
Thx in advance.
Best
Gee