logicapps
logicapps copied to clipboard
What's the best way to create Alerts for failed workflows (Logic App Standard)?
We're currently looking for a possibility to create Alerts that notify us when a specific amount of workflows fail. Since there's no build-in Alert (like for consumption-based Logic Apps) we're currently using Kusto query:
traces | extend RunId_s = tostring(parse_json(tostring(parse_json(tostring(customDimensions.prop__properties)).resource)).runId) | extend workflowName = tostring(parse_json(tostring(parse_json(tostring(customDimensions.prop__properties)).resource)).workflowName) | extend endState = customDimensions.prop__status | where message startswith "Workflow run end" or message startswith "Workflow run disp" | where endState == "Failed" | sort by timestamp | distinct RunId_s
But honestly, it feels unsatisfying to create such a query for such a simple task plus not all workflows have a trace with the last failed action - which is weird but another topic.
Does anybody have some better solution?
We also tried this query:
customMetrics | where name == "Runs Failed" or operation_Name == "FlowRunLastJob" | order by timestamp
But unfortunately this doesn't give us any information about which workflow failed.
You can catch LA Standard workflow errors based on http status codes, most likely the Http Server Errors and Http 4xx signal names is what you're looking for. Personally i would catch all errors where possible and handle them before the workflow fails.
This issue is stale because it has been open for 30 days with no activity.
This issue was closed because it has been inactive for 7 days since being marked as stale.
Please reopen. There's currently no way to find all workflow executions on the logs and no guidance on how to exploit these logs.
Closing this but keeping #558 open as a duplicate
This is 558 and is marked as closed. Can you please reopen?
Sorry, did not mean to close this one, it's also flagged so it won't get auto closed. I'll get someone from the back end to take a look at this and see what options we have.
The support for Logic Apps metrics is coming by the end of the year. This will include metrics for runs, actions and trigger level events that you can use for monitoring and alerting.