Create Azure DevOps or GitHub bugs from Azure Monitor logs
When operating distributed applications it can be a lot of work if you want to copy error details into tickets and work items for your teams to look at.
I rely heavily on Azure Monitor and the capabilities to explore exceptions and failures in Application Insights.
There's a fairly new capability that recently released into General Availability, which helps us create work items directly from a logged event in Application Insights.
From Application Insights, select any of your failed events and explore further. When you decide you need to log this as a bug or a work item to your team, you can do that from here:
If you haven't already set up a workbook template, you will get the option to do that now.
From the next view, you can create and define the workbook template. I am calling mine "Production Exceptions", and associating relevant tags that will help in the work item in Azure DevOps.
Create the template, and now you can again click "Create work item" -> "Production Exceptions". The name of the menu item here will be the name you gave it in the previous step.
You now decide whether to log this as a Work Item (task), or as an Exception (bug). Select "Create a bug for this exception".
You'll be redirected to the Azure DevOps (or GitHub) page with all the details you have defined.
In my case, the template will give me this:
- Title: The exception, but I usually modify this manually for each new bug.
- Tags: "WEU", and "ProductionException" as I defined in my template.
- Repro Steps: All the information from Application Insights, including a link back to the very same item in app insights, so anyone picking this up can go back to see the full telemetry (if they are authorized to do so).
That's it. I hope it can help speed up the DevOps and DevSecOps processes you embrace. Because you do embrace them, right?