0

I created some http functions using java and deployed to. Azure function app but now I need to trigger Email notifications to end users if function fail For this I have created alert rule resource with some condition query & Action group resources for sending emails and sms but, it is delaying sending notifications for 15min So please suggest me how to trigger notifications if my function fails?

2
  • please check my SO-thread answer, is This helpful? Commented Oct 6, 2022 at 3:09
  • Hi Rithwik sorry for late response & Thanks for answering.... Can you please explain me how your below condition query works? requests | where duration > 1000
    – Venkatesh
    Commented Oct 11, 2022 at 4:34

1 Answer 1

0

In continuation to comments, please find below answer.

requests  
| where duration > 1000

requests is the table that contains our duration time, source, result of function, etc.

enter image description here

Duration is the time taken to completely run the azure function. If the function takes more than specified minutes, it sends an alert. So, it sends notification in form of alert.

1000 is in milliseconds.(1000 milliseconds)

6
  • Great!... But my functions are http functions that will copy file from one container to another container so, sometimes my function will run 10sec, 20sec etc., Based on File size to copy so, I think this condition query don't work for me
    – Venkatesh
    Commented Oct 11, 2022 at 17:15
  • I given. ''' union (requests), (exception) |where success=false |where timestamp> ago(1d). ''' but this condition not triggering email notifications immediately it is sending email after 5-15min, when function failed
    – Venkatesh
    Commented Oct 11, 2022 at 17:18
  • Also I need to know one thing, is it possible to create new table in Application insight?
    – Venkatesh
    Commented Oct 11, 2022 at 17:23
  • Yes, you can create a table in log analytics Commented Oct 12, 2022 at 7:33
  • Yaa... I know we can in log analytics resource but, is it possible in application insight resource?
    – Venkatesh
    Commented Oct 12, 2022 at 9:40

Not the answer you're looking for? Browse other questions tagged or ask your own question.