Skip to content

Conversation

@Francisco-Gamino
Copy link
Contributor

@Francisco-Gamino Francisco-Gamino commented Nov 10, 2025

Description

The PR contains the following changes:

  • Upgraded Az.Functions to Autorest 4.x
    Resolves [Functions] Upgrade module autorest.powershell v4 #24403
    This upgrade introduces changes to internal types for models generated by Autorest, e.g., new models
    Microsoft.Azure.PowerShell.Cmdlets.Functions.Models.IGeoRegion instead of
    Microsoft.Azure.PowerShell.Cmdlets.Functions.Models.Api20231201.IGeoRegion.

  • Updated Az.Functions helpers:
    1) AppInsights helper (src/helpers/AppInsights/readme.noprofile.md) updated to build from the main branch. Previously, it was building from https://github.com/Azure/azure-rest-api-specs/blob/e0d9ceb1ca85e76a31b8496201499a7312824c09, but I needed a version that returns the APPLICATIONINSIGHTS_CONNECTION_STRING.
    2) Storage helper (src/helpers/Storage/readme.noprofile.md) updated to expose Blob container cmdlets, enabling creation, retrieval, and removal of blob containers. These are required to set deployment options for a Flex Consumption app.

  • Added support for creating Flex Consumption function apps:
    Resolves [Functions] Add support to create Flex Consumption function apps #24349
    1) Updated Get-AzFunctionAppAvailableLocation PlanType to include FlexConsumption.
    - Added ZoneRedundant to list locations where zone redundancy is supported (currently applies only to Flex Consumption).
    2) Added Get-AzFunctionAppFlexConsumptionRuntime, a new cmdlet to retrieve Flex Consumption function app runtimes supported at a specified location.
    3) Added a new parameter set to New-AzFunctionApp to support creating Flex Consumption function apps.
    - Added regression tests for Flex Consumption scenarios.

Cmdlet review for the new cmdlet and parameter set: https://github.com/Azure/azure-powershell-cmdlet-review-pr/issues/1524

Mandatory Checklist

  • SHOULD update ChangeLog.md file(s) appropriately
    • Update src/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.
      • A snippet outlining the change(s) made in the PR should be written under the ## Upcoming Release header in the past tense.
    • Should not change ChangeLog.md if no new release is required, such as fixing test case only.
  • SHOULD regenerate markdown help files if there is cmdlet API change. Instruction
  • SHOULD have proper test coverage for changes in pull request.
  • SHOULD NOT adjust version of module manually in pull request

Copilot AI review requested due to automatic review settings November 10, 2025 18:11
@azure-client-tools-bot-prd
Copy link

Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status.

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

This PR updates the Azure Functions PowerShell module with significant enhancements for Flex Consumption support, runtime version updates, and test improvements.

Key Changes

  • Adds Flex Consumption plan type support with new cmdlet Get-AzFunctionAppFlexConsumptionRuntime
  • Updates default runtime versions across multiple runtimes (PowerShell 7.2→7.4, Node 18→22, DotNet 6→8, Python 3.10→3.12, Java 17→21)
  • Refactors test suite with improved verbose logging, variable naming consistency, and enhanced test coverage for Flex Consumption scenarios

Reviewed Changes

Copilot reviewed 56 out of 66 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/helpers/Storage/readme.noprofile.md AutoRest configuration updates for Storage helper module with new directives for BlobContainer cmdlets
src/helpers/AppInsights/readme.noprofile.md Simplified AppInsights AutoRest configuration by removing redundant specification references
src/Functions/Functions/help/Get-AzFunctionAppFlexConsumptionRuntime.md New help documentation for Flex Consumption runtime cmdlet (placeholder examples need completion)
src/Functions/Functions/help/Az.Functions.md Module index updated to include new Flex Consumption cmdlet
src/Functions/Functions.Autorest/test/utils.ps1 Test utility updates with new environment variables for Flex testing, updated runtime versions, and additional test resource names
src/Functions/Functions.Autorest/test/env.json Test environment data refreshed with new resource names and updated configurations
src/Functions/Functions.Autorest/test/Update-AzFunctionAppSetting.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Update-AzFunctionAppPlan.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Update-AzFunctionApp.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Stop-AzFunctionApp.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Start-AzFunctionApp.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Restart-AzFunctionApp.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Remove-AzFunctionAppSetting.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Remove-AzFunctionAppPlan.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Remove-AzFunctionApp.Tests.ps1 Enhanced test with improved variable naming, verbose logging, and updated runtime versions
src/Functions/Functions.Autorest/test/New-Update-Remove-AzFunctionAppPlan.Tests.ps1 Improved test structure with BeforeAll block, enhanced logging, and consistent variable usage
src/Functions/Functions.Autorest/test/New-Update-Remove-AzFunctionApp.Tests.ps1 Major refactoring with reordered tests, improved logging, and new test scenarios
src/Functions/Functions.Autorest/test/New-AzFunctionAppPlan.Recording.json Updated test recording with new resource IDs and timestamps
src/Functions/Functions.Autorest/test/New-AzFunctionApp.Tests.ps1 Comprehensive test updates with runtime version changes, improved error handling, and enhanced validation
src/Functions/Functions.Autorest/test/New-AzFunctionApp.FlexConsumptionTests.ps1 New comprehensive test suite for Flex Consumption functionality with helper functions and multiple test scenarios
src/Functions/Functions.Autorest/test/New-AzFunctionApp.ACA.Tests.ps1 Enhanced ACA tests with improved variable scoping and verbose logging
src/Functions/Functions.Autorest/test/Get-Update-Remove-AzFunctionAppSetting.Tests.ps1 Improved test with BeforeAll block, better variable naming, and enhanced logging
src/Functions/Functions.Autorest/test/Get-AzFunctionAppSetting.Tests.ps1 Removed empty test file
src/Functions/Functions.Autorest/test/Get-AzFunctionAppFlexConsumptionRuntime.Tests.ps1 New comprehensive test suite for Flex Consumption runtime cmdlet with validation of supported runtimes and versions
src/Functions/Functions.Autorest/test/Get-AzFunctionAppAvailableLocation.Tests.ps1 Extended tests to validate Flex Consumption location support and zone redundancy
src/Functions/Functions.Autorest/docs/Get-AzFunctionAppFlexConsumptionRuntime.md New cmdlet documentation (placeholder examples need completion)
src/Functions/Functions.Autorest/docs/Az.Functions.md Module documentation updated with new Flex Consumption cmdlet reference
src/Functions/Functions.Autorest/custom/api/Support/Site.cs Namespace simplification for Site model
src/Functions/Functions.Autorest/custom/api/Support/AvailablePlanType.cs Added FlexConsumption plan type to available options
src/Functions/Functions.Autorest/custom/api/Support/AppServicePlan.cs Namespace simplification for AppServicePlan model
src/Functions/Functions.Autorest/custom/Update-AzFunctionAppSetting.ps1 Updated type references to use simplified namespaces

@isra-fel
Copy link
Member

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@isra-fel
Copy link
Member

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@isra-fel
Copy link
Member

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@Francisco-Gamino
Copy link
Contributor Author

Adding Functions folks for FYI

@nzthiago @amamounelsayed @CooperLink @castrodd

@isra-fel
Copy link
Member

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@dolauli
Copy link
Contributor

dolauli commented Nov 11, 2025

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

@notyashhh
Copy link
Member

/azp run

@azure-pipelines
Copy link
Contributor

Azure Pipelines successfully started running 3 pipeline(s).

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.

[Functions] Upgrade module autorest.powershell v4 [Functions] Add support to create Flex Consumption function apps

4 participants