Create a logic app
| Product family | Azure |
|---|---|
| Document source | Azure Chaos Studio |
| Guide type | Configuration Guide |
| Skill level | Intermediate to advanced |
| Time | 15 - 60 minutes depending on environment |
This guide covers Create a logic app on Azure end to end. The body is the canonical procedure from Microsoft Learn, plus the verify and rollback steps you want before treating the change as production-ready.
Standing up a Logic App that drives a Chaos Studio experiment
A Logic App is the cheapest, most maintainable scheduler I know for Chaos Studio. It has a recurrence trigger, native managed identity support, and integrates cleanly with Teams, ServiceNow, and PagerDuty if you want to alert on the experiment result.
For a Gurugram media analytics startup, the Logic App took about two hours to build and has run a daily experiment without intervention for the last seven months. I've seen this fail when the storage account had a private endpoint but the Batch pool didn't, and downloads timed out silently.
The portal recipe
- Create a new Logic App (Consumption tier is fine for daily runs).
- Enable a system-assigned managed identity.
- Add a Recurrence trigger - frequency Day, interval 1, IST timezone.
- Add an HTTP action calling the experiment start endpoint with Managed Identity auth.
- Optionally add a Teams or webhook action to post the run result.
The shell-only path
az logic workflow create \
--resource-group rg-chaos \
--location centralindia \
--name la-chaos-runner \
--definition @./workflow.json
az logic workflow identity assign \
--resource-group rg-chaos \
--name la-chaos-runner
Permissions to assign
Grant the Logic App's managed identity Chaos Experiment Contributor on the experiment resource and Reader at the resource group. That is enough for a clean daily run.
Operational tips
- Pin the Logic App to a region close to your users to keep latency consistent.
- Set the workflow's run history retention to at least 30 days so you can audit any surprises.
- Wire alerts to fire on workflow failure - silent failure is the worst failure.
The pre-experiment checklist I never skip
Chaos Studio is one of those tools where the cost of a missing step is felt by people who did not click the button. The checklist below is what I run through before any non-trivial experiment, and it has prevented several genuinely embarrassing incidents.
- Blast radius - written down in plain English. "Up to 30 percent of pods in the checkout namespace for 3 minutes" is good. "Some pods" is not.
- Rollback - the exact command that ends the experiment if it misbehaves.
az chaos experiment stop --resource-group rg-chaos --name exp-xyzgoes on a sticky note. - Identity - the experiment managed identity has the narrowest role that allows the fault, scoped to the exact target resource group.
- Observability - dashboards for the SLO metric, the saturation metric, and the error budget burn rate are open before the run.
- Comms - the team channel and the on-call know the window and the rollback command.
- Approval - on production, written approval from the service owner. No exceptions.
I lost half a Saturday once with B2B SaaS company in Gurugram because we ran an experiment without confirming the rollback command worked in their isolated environment. I've seen this fail when an engineer assumed defaults survive a subscription move - they do not.
What I tell leadership before a Chaos Studio rollout
Engineering teams pitch tools. Leadership funds outcomes. The pitch deck I run with executives at Mumbai-based customers is three slides long.
Slide one - the user problem. Either we are paying too much for compute we do not use, or we are paying for an outage we did not predict. Chaos Studio addresses one of those head-on. Make the slide a single number with a unit. Rs 18,00,000 saved annually beats any chart.
Slide two - the operational model. Who owns the workload. Who owns the controls. Who owns the budget. Who responds to incidents. If those four owners are not named on the slide, the rollout will stall in committee.
Slide three - the first 90 days. A concrete plan with milestones. Week one is enablement. Week two is the first pilot. Month two is the first measurable outcome. Month three is the steady state. Pad nothing - if the plan slips, it should be because of something real, not because of vague timeline language.
The conversation works because executives can act on it. They can fund the program, name the owners, and ask for the 90-day check-in. Anything fuzzier sits in a slide deck and dies. I've seen this fail when the service principal had Contributor on the resource group but not on the subscription.
What the cost actually looks like
Most teams underestimate the supporting-services bill and overestimate the compute bill. Here is the line-item breakdown I see most often.
- Chaos Studio experiment runs (a few rupees per minute of experiment).
- Application Insights ingestion - the experiments produce useful events.
- Logic App or Function compute if you scheduled the experiments.
- Optional - dedicated monitoring workspace per environment.
A weekly chaos program for a QSR chain's IT cell in Hyderabad ran at about Rs 8,400 a month (USD 100), dominated by App Insights ingestion. The savings from one prevented incident pays for the entire year. Tag every resource with cost-center, environment, and owner. Build a Cost Management view that groups by tag. Pin it to the team dashboard. The day someone leaves a runaway pool on, you want the view to be the first thing in the morning standup, not the bill in a week.
One last note on cost - egress is the silent cost. A workload that talks to an on-prem system across ExpressRoute usually costs more in network than in compute. Plan accordingly, and consider private endpoints where the data is sensitive enough to justify the cost.
One incident I want you to remember
We ran a 90-second pod-kill experiment on a service that should have tolerated it. It did not. Half the pods were on a single underlying node and the experiment's fixed-percent selector killed all of them at once. Customer error rates spiked for 7 minutes. The fix was a Pod Disruption Budget plus an anti-affinity rule. Without the experiment we would have learned this from a customer ticket, not from a controlled drill.
The lesson is the same in every case - the platform is reliable, the tooling is reliable, the failure is almost always an assumption in your own configuration that the previous platform was lenient enough to mask. Treat every migration, every rollout, every experiment like a chance to discover one of those assumptions before a customer does it for you.
The observability I demand for any Chaos Studio experiment
I refuse to call a workload production-ready without these dashboards. They are cheap to build and impossible to live without once you have them.
- Operational view covering experiment runs, fault start and end events, SLO metric for the target service, error budget burn rate.
- Cost view grouped by tag, refreshed daily, alerted at budget threshold.
- SLO view showing the headline SLO metric, with the burn rate over the last hour, last day, and last week.
- Activity Log feed piped into a Teams channel for anything tagged with the workload's resource group.
For edtech platform in Gurugram, I built all four for them in an afternoon and the team's on-call rotation became measurably calmer inside two weeks. The dashboards do not stop incidents from happening - they shorten the loop between something going wrong and someone knowing.
Security corners worth a second look
Whatever security review you run, here are the questions I would push back on if I sat across the table.
- Identities - every workload uses a managed identity rather than a service principal with a static secret, unless there is a legitimate reason. Static secrets rotate at inconvenient times.
- Scopes - every role assignment is scoped to the narrowest resource that allows the workload to function. Subscription-scope Contributor is almost always wrong.
- Network - public endpoints are explicitly justified. Anything that talks to sensitive data uses private endpoints, with NSGs that deny everything else.
- Secrets - in Key Vault, with auto-rotation enabled wherever the dependent service supports it.
- Audit - Activity Log piped to a workspace with retention measured in months, not days, and an alert on any role assignment change.
None of this is exotic. All of it gets skipped when the team is moving fast and the security team trusts the engineering team. The compromise that works is to write the controls down once, get sign-off, and then automate them. Manual reviews stop scaling at about ten resources. Policy-driven controls scale to thousands. I've seen this fail when the service principal had Contributor on the resource group but not on the subscription.
How the team actually uses this day to day
Tools are only as good as the workflow around them. For the teams I have helped land this, the rhythm settles into something like this.
Daily - a quick standup that includes the cost dashboard. If yesterday's spend was 1.3x the seven-day moving average, someone owns figuring out why before lunch.
Weekly - a 30-minute reliability review. The week's incidents, the week's experiments, the week's near-misses. Nothing fancy. The discipline of running it on the calendar is what matters.
Monthly - a deeper postmortem on anything that breached SLO and a forward look at upgrades, certificate rotations, or platform retirements coming in the next 90 days.
Quarterly - a tabletop exercise. Pick the worst plausible failure, walk through the response, document the gaps, fix them before the next quarter.
For consulting client in Noida, putting this rhythm in place took about three meetings of patient nagging and then it ran itself. The team got faster at incidents, the leadership reviews got shorter, and the on-call rotation rotated through people who actually understood the system instead of people who were just hoping nothing broke on their week.
If I had to leave you with one rule
It is this. Chaos Studio rewards teams who treat it as a system, not as a feature. Stand up the observability before the workload. Write the runbook before the first incident. Put the controls in Policy, not in Slack messages. Pick the tightest scope, then make it tighter. Tag everything. Review the cost every week, not every month. The reward for that discipline is the kind of reliability your customers never notice, which is exactly what you want them to feel.
Related fixes
Related guides worth a look while you sort this one out:
- Next, you're going to fill out the Create Logic App fields with the following values
- Create an experiment from a template
- Create your fault analysis Workbook
- Create an app in the Amazon developer console
- Create a Document Intelligence Logic Apps workflow
- Create a project in the Document Intelligence Studio