Azure Logic Apps CI/CD – Part 1 – Introduction
In a series of posts I will demonstrate how to setup a continuous integration and continuous deployment (CI/CD) pipeline for Azure Logic Apps. I also intend to touch on general Logic Apps development topics along the way and the broader subject of DevOps practices.
This first blog post introduces the scenario and the Logic App that will eventually be a well oiled component of slick automated delivery pipeline using Visual Studio Team Services (VSTS).
Introduction to the Scenario – Low or High Priority Purchase Order Processing
In order to demonstrate CI/CD with Logic Apps we will use the following simple Logic App:
The Logic App does the following:
- Receives a batch of Purchase Orders (PO) via an HTTP request.
- The variable “CBRFilter” is initialized that will be assigned the calculated priority of the PO.
- This variable will be initialized further on, for the purposes of Content Based Routing (CBR) on Azure Service Bus.
- The Condition action will evaluate the total PO amount and assign low or high priority accordingly.
- If the PO amount is < $200K, then the CBR filter variable will be assigned the value “PriorityLow”.
- If the the PO amount is >= $200K, then the CBR filter variable will be assigned the value “PriorityHigh”.
- Finally, we publish the PO to a Service Bus topic with the low/high priority filter assigned such that the message will appear on the low/high priority topic subscription.
Testing the Logic App
Ok, let’s take the Logic App for a spin and try it out.
Using Postman, I call the Logic App endpoint, passing in a PO batch as follows:
Logging in to the Azure Portal, I can check that the Logic App has worked as expected and has assigned a “high priority” CBR filter, since the total PO batch amount is indeed > $200K:
And using Service Bus Explorer, I can see that the PO has been picked up by the high priority topic subscription:
So this concludes Part 1 of this series where I will demonstrate setting up a CI/CD pipeline for the Logic App that has been introduced in this post.
In the next post I will take you through downloading and parameterising an ARM template using Visual Studio that will be used for deploying the Logic App to the various Azure Resource Groups.