Skip to content

Add azure-upgrade skill for Azure Functions Consumption to Flex Consumption migration#1211

Merged
kvenkatrajan merged 10 commits intomicrosoft:mainfrom
MadhuraBharadwaj-MSFT:main
Mar 12, 2026
Merged

Add azure-upgrade skill for Azure Functions Consumption to Flex Consumption migration#1211
kvenkatrajan merged 10 commits intomicrosoft:mainfrom
MadhuraBharadwaj-MSFT:main

Conversation

@MadhuraBharadwaj-MSFT
Copy link
Contributor

@MadhuraBharadwaj-MSFT MadhuraBharadwaj-MSFT commented Mar 10, 2026

Add azure-upgrade skill for Azure Functions Consumption to Flex Consumption migration

Summary

Introduces a new skill to guide assessment and automated upgrades of Azure Functions apps from Consumption Plan to Flex Consumption Plan. This is the first "Azure-to-Azure" upgrade scenario — the skill framework supports adding more upgrade paths in the future.

What's included

File Purpose
SKILL.md Top-level skill definition with triggers, rules, MCP tools, and workflow
references/global-rules.md Destructive action policy, ask_user requirements, identity-first auth
references/workflow-details.md Phase diagram, status tracking template, error handling
references/services/functions/assessment.md Full assessment report template (10 sections)
references/services/functions/consumption-to-flex.md Scenario playbook — phases, compatibility, risks, IaC differences
references/services/functions/automation.md All az CLI scripts (7 steps)

Key features

  • Automated eligibility check via az functionapp flex-migration list
  • One-command migration via az functionapp flex-migration start (config only — code deployed separately)
  • User choice for code deployment: CI/CD pipeline update, local publish, or existing package
  • Smoke test validation — hits the app URL after deployment to confirm it's reachable
  • Practical next steps — rollback guidance, security hardening, cleanup timing
  • Trigger migration risks — table of risks/mitigations for Blob, Cosmos DB, Event Hubs, Service Bus, etc.
  • Deprecated settings filter — list of app settings that should NOT be migrated to Flex

Scope

  • Platform: Linux only (Windows support planned for future)
  • Source: Consumption Plan (Y1/Dynamic)
  • Target: Flex Consumption Plan (FC1/FlexConsumption)

Related docs

Testing

  • Skill loads without YAML frontmatter errors
  • Triggers on prompts like "upgrade my function app to Flex Consumption"
  • flex-migration list returns eligible/ineligible apps
  • Full upgrade workflow completes successfully on a test app

@MadhuraBharadwaj-MSFT
Copy link
Contributor Author

Manual testing successful

  1. Source Linux Consumption app that needs to be migrated (HTTP trigger execution results below)
image 2. Prompt tested "upgrade my Linux Consumption apps to Flex Consumption". Skill invocation works as expected. image 3. Accurately lists Linux Consumption apps in user's subscriptions image 4. Generates an assessment report and provides options for the new Flex app's name image 5. Migration to Flex Consumption successful  image 6. Test: Flex Consumption HTTP trigger Function executes successfully image

- Add unit, trigger, and integration tests for azure-upgrade skill
- Add create-function-app-consumption.sh setup script
- Condense SKILL.md description to meet 60-word limit
- Register azure-upgrade in tests/skills.json
@saikoumudi saikoumudi marked this pull request as ready for review March 12, 2026 18:17
Copilot AI review requested due to automatic review settings March 12, 2026 18:17
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new azure-upgrade skill under plugin/skills/ to guide Azure-to-Azure “upgrade” workflows, starting with Azure Functions Linux Consumption → Flex Consumption, and wires it into the test suite and integration schedule.

Changes:

  • Added new azure-upgrade skill content (SKILL.md + reference docs for workflow, rules, assessment template, and automation scripts).
  • Added unit, trigger (with snapshots), and integration tests for azure-upgrade, plus a helper shell script for integration setup.
  • Registered azure-upgrade in tests/skills.json and added it to the integration test schedule.

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tests/skills.json Adds azure-upgrade to the skills list and scheduled integration runs.
tests/azure-upgrade/unit.test.ts Validates the new skill’s metadata and required content sections.
tests/azure-upgrade/triggers.test.ts Adds trigger coverage + snapshots for keyword extraction behavior.
tests/azure-upgrade/integration.test.ts Runs an end-to-end agent session for Consumption → Flex migration flow.
tests/azure-upgrade/create-function-app-consumption.sh Script used by the integration test to create a source Consumption app.
tests/azure-upgrade/snapshots/triggers.test.ts.snap Snapshot baseline for trigger keywords/metadata.
plugin/skills/azure-upgrade/SKILL.md Defines the new skill’s triggers, rules, scenarios, and workflow outline.
plugin/skills/azure-upgrade/references/global-rules.md Global safety and confirmation rules for upgrade operations.
plugin/skills/azure-upgrade/references/workflow-details.md Workflow phase details and upgrade-status.md tracking template.
plugin/skills/azure-upgrade/references/services/functions/assessment.md Standardized assessment report template + required headings.
plugin/skills/azure-upgrade/references/services/functions/consumption-to-flex.md Scenario playbook for Consumption → Flex migration.
plugin/skills/azure-upgrade/references/services/functions/automation.md CLI-driven step-by-step automation scripts for the scenario.

You can also share your feedback on Copilot code review. Take the survey.

Copilot AI review requested due to automatic review settings March 12, 2026 22:47
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.

Comments suppressed due to low confidence (1)

plugin/skills/azure-upgrade/references/services/functions/automation.md:369

  • The “Verify Plan” step only prints serverFarmId, which identifies the plan but doesn’t actually validate that the plan is Flex Consumption (FC1/FlexConsumption). To make this a real verification step, follow up by querying the referenced App Service plan and asserting its SKU/tier matches Flex Consumption.
### Verify Plan

```bash
az functionapp show --name <NEW_APP_NAME> --resource-group <RESOURCE_GROUP> --query "serverFarmId"
</details>



---

You can also share your feedback on Copilot code review. [Take the survey](https://www.surveymonkey.com/r/XP6L3XJ).

@kvenkatrajan kvenkatrajan merged commit 00d55a1 into microsoft:main Mar 12, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants