Skip to content

Add MemorySizeInGB parameter for SQL Managed Instance CRUD #28341

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

UrosKrsticMIPerf
Copy link

Description

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 Copilot AI review requested due to automatic review settings August 6, 2025 14:29
Copy link

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

@UrosKrsticMIPerf UrosKrsticMIPerf changed the title Add temporary changes Add MemorySizeInGB parameter for SQL Managed Instance CRUD Aug 6, 2025
Copy link
Contributor

@Copilot 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 adds support for flexible memory configuration to Azure SQL Managed Instance by introducing a new MemorySizeInGb parameter. The changes enable users to specify custom memory sizes when creating or updating managed instances through PowerShell cmdlets.

Key Changes

  • Added MemorySizeInGb property to the managed instance model and cmdlets
  • Updated the adapter to handle the new memory size parameter in API calls
  • Added comprehensive test coverage for the flexible memory functionality

Reviewed Changes

Copilot reviewed 11 out of 30 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
src/Sql/Sql/ManagedInstance/Services/AzureSqlManagedInstanceAdapter.cs Added memory size mapping between model and API requests/responses
src/Sql/Sql/ManagedInstance/Model/AzureSqlManagedInstanceModel.cs Added MemorySizeInGb property to the managed instance model
src/Sql/Sql/ManagedInstance/Cmdlet/SetAzureSqlManagedInstance.cs Added MemorySizeInGb parameter to Set-AzSqlManagedInstance cmdlet
src/Sql/Sql/ManagedInstance/Cmdlet/NewAzureSqlManagedInstance.cs Added MemorySizeInGb parameter to New-AzSqlManagedInstance cmdlet
src/Sql/Sql/ChangeLog.md Added placeholder entry for the flexible memory feature
src/Sql/Sql.Test/SessionRecords/Microsoft.Azure.Commands.Sql.Test.ScenarioTests.ManagedInstanceCrudScenarioTests/TestCreateManagedInstanceFlexibleMemory.json Added test session recording for flexible memory testing
src/Sql/Sql.Test/ScenarioTests/ManagedInstanceCrudScenarioTests.ps1 Added PowerShell test functions for flexible memory scenarios
src/Sql/Sql.Test/ScenarioTests/ManagedInstanceCrudScenarioTests.cs Added C# test methods for flexible memory functionality
src/Sql/Sql.Test/ScenarioTests/Common.ps1 Added helper function for flexible memory test parameters
src/Sql/Sql.Management.Sdk/README.md Updated API specification version to support flexible memory
build.sln Added solution file for build configuration

@@ -93,6 +93,11 @@ public class AzureSqlManagedInstanceModel
/// </summary>
public int? VCores { get; set; }

/// <summary>
/// Gets or sets the number of VCores.
Copy link
Preview

Copilot AI Aug 6, 2025

Choose a reason for hiding this comment

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

The documentation comment is incorrect. This property represents memory size in GB, not the number of VCores. It should be '/// Gets or sets the memory size in GB.'

Suggested change
/// Gets or sets the number of VCores.
/// Gets or sets the memory size in GB.

Copilot uses AI. Check for mistakes.

@@ -18,6 +18,7 @@
- Additional information about change #1
-->
## Upcoming Release
placeholder to sql mi flexible memory feature
Copy link
Preview

Copilot AI Aug 6, 2025

Choose a reason for hiding this comment

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

The changelog entry should be more descriptive and follow proper formatting. It should describe what was added in past tense, such as '* Added MemorySizeInGb parameter to New-AzSqlManagedInstance and Set-AzSqlManagedInstance cmdlets for flexible memory configuration'.

Suggested change
placeholder to sql mi flexible memory feature
* Added `MemorySizeInGb` parameter to `New-AzSqlManagedInstance` and `Set-AzSqlManagedInstance` cmdlets for flexible memory configuration.

Copilot uses AI. Check for mistakes.

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.

1 participant