Last active
September 11, 2021 11:51
-
-
Save pacodelacruz/e886f7b5bebb1aa3745faafeccde916e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
traces | |
| where operation_Name == "FlowRunLastJob" | |
| extend resource = parse_json(tostring(parse_json(tostring(customDimensions.prop__properties)).resource)) | |
| extend error = parse_json(tostring(customDimensions.prop__error)) | |
| project timestamp | |
, LogicApp = tostring(cloud_RoleName) | |
, Workflow = tostring(resource.workflowName) | |
, WorkflowRunId = tostring(customDimensions.prop__flowRunSequenceId) | |
, ClientTrackingId = tostring(customDimensions.prop__clientTrackingId) | |
, WorkflowStatus = customDimensions.prop__status | |
, ErrorCode = error.code | |
, ErrorMessage = error.message | |
| join kind = leftouter ( // trackedProperties | |
traces | |
| where customDimensions.prop__properties has "trackedProperties" | |
| extend trackedProperties = parse_json(tostring(parse_json(tostring(customDimensions.prop__properties)).trackedProperties)) | |
| project InterfaceId = trackedProperties.InterfaceId | |
, WorkflowRunId = tostring(customDimensions.prop__flowRunSequenceId) | |
| where isnotnull(InterfaceId) | |
) | |
on $left.WorkflowRunId == $right.WorkflowRunId | |
| project timestamp | |
, InterfaceId | |
, LogicApp | |
, Workflow | |
, WorkflowRunId | |
, ClientTrackingId | |
, WorkflowStatus | |
, ErrorCode | |
, ErrorMessage | |
| sort by timestamp desc | |
//| where InterfaceId contains "" | |
//| where ClientTrackingId contains "" | |
//| where LogicApp contains "" | |
//| where Workflow contains "" | |
| where WorkflowStatus == "Failed" | |
//| where WorkflowStatus == "Cancelled" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment