Thursday, May 28, 2020

How to Utilize Microsoft Power Automate for Azure DevOps (ADO) Monitoring and Alert?

Our project is heavily using Azure DevOps (ADO) as a backlog management tool, and as part of Release Train Engineer (RTE)'s responsibility is to make sure everyone uses it properly and updates it regularly. Due to this, every week I will send reminder emails to all scrum masters and product owners in our program. I will include some information that needs everyone's actions (e.g. list of orphan work-items with no linkage, list of open/non-closed work-items from past iterations, etc.). I do it in semi-auto process like below:

I try to find an easy way to make it automatic, I've been researching some methods until my friend suggested I can use Microsoft Power Automate (it's called Microsoft Flow before). After doing some hands-on, actually it's quite easy to use and has a good user friendly user interface. I just need to create the flow with some steps that connect to Microsoft products and services by drag and drop for workflow creation, configure the setting on each step and set it as a scheduler. Voila, it's solved my problem statement. Here's what I did to make it works:
  • Open the Power Automate URL here.
  • After login, from the left menu choose My flows. Click + New button to create the new flow. For my case I choose "Scheduled - from blank" because I want to make a scheduler flow, then define the flow name and recurring time.

  • In the flow designer flow page, I created these simple flow with some steps using Microsoft products and services:

  • Here's the detail on each step:
1. Recurrence: it's the recurrence step to define the scheduling time (interval, frequency, timezone, start time, etc.), by default it's added when choosing the new "Scheduled - from blank" template.
2. Azure DevOps - Get query results: it's the step to call existing saved query from ADO. Define the organization name, project name, and the query id.
3. Data Operation - Create HTML table 2: it's the step to construct an html table based on output from ADO query. So the output won't be that messy and can be parsed into a single table. Define the table header and the column/field name from the query result.
4. Office 365 Outlook - Send an email (V2): it's the step to send email exactly like an email window in a normal Outlook, we need to define the To, Subject, and Email body. In the email body, I embed output from the previous step of HTML table creation.
5. Microsoft Teams - Post a message (V3): it's the step to post a message in Teams channel. We need to specify Teams folder name, channel and message content.

  • After saving the flow, click the turn-on button to activate the flow. Refer to the status value, if it's On then it's already active:

Finally, here's the result:
  • Email sent out to respective recipients:
  • Message sent out to Teams channel:

There's so much we can do here by connecting to some Microsoft products and services (e.g. SharePoint, Power BI, Office365, Azure services, etc.) or even available third party service connectors. Each connector has their own unique trigger and action, it's quite interesting technology to be explored more.

Other than above flow, I created another two scheduler flows for my SAFe cadences reminder, which is to weekly remind:
  • Scrum Masters to update Mural boards that show the latest facilitation status of each meeting cadences in each iteration.
  • Product Owners to update the team Mural board to show the latest progress of each key deliveries item in each iteration.

Post a Comment

Whatsapp Button works on Mobile Device only

Start typing and press Enter to search