Skip to content

Conversation

Aman-Jain-14
Copy link
Member

Description

Adding support for Import, AutoExport and AutoImport HSM Jobs

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 September 6, 2025 14:02
Copy link

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

@Aman-Jain-14 Aman-Jain-14 deleted the dev/amajai/main-storagecache_support_for_import_autoexport_autoimport branch September 6, 2025 14:03
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 pull request adds support for Import, AutoExport and AutoImport HSM Jobs to the StorageCache module, significantly expanding the functionality for managing Azure Machine Learning (AML) file systems and caching operations.

Key Changes

  • Introduces comprehensive job management capabilities for Import, AutoExport, and AutoImport operations
  • Adds new cmdlets for creating, retrieving, updating, and removing HSM jobs
  • Extends the New-AzStorageCacheAmlFileSystem cmdlet with new root squash settings and import prefix parameters

Reviewed Changes

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

Show a summary per file
File Description
Az.StorageCache.psd1 Updated module manifest with new function exports and dependency version
Az.StorageCache.md Added documentation for all new HSM job management cmdlets
New-AzStorageCacheAmlFileSystem.md Enhanced with new root squash and import prefix parameters
StorageCache.sln Updated project reference GUID
Multiple test files Added comprehensive test coverage for new cmdlets
Multiple help files Documentation for new Get/Clear/Debug/Invoke cmdlets

. ($mockingPath | Select-Object -First 1).FullName
}

New-AzStorageCacheAutoImportJob -AmlFilesystemName 'acctest43511' -Name 'sampleAutoImportJob' -ResourceGroupName 'acctest43511' -Location 'Canada Central' -AutoImportPrefix @('/path1', '/path2')
Copy link
Preview

Copilot AI Sep 6, 2025

Choose a reason for hiding this comment

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

The test file contains hardcoded values for resource names and subscription IDs that should be parameterized or use environment variables for better test portability and security.

Copilot uses AI. Check for mistakes.

. ($mockingPath | Select-Object -First 1).FullName
}

New-AzStorageCacheAutoExportJob -AmlFilesystemName 'acctest43511' -Name 'sampleUpdateJob' -ResourceGroupName 'acctest43511' -Location 'Canada Central' -AutoExportPrefix @('/path1')
Copy link
Preview

Copilot AI Sep 6, 2025

Choose a reason for hiding this comment

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

Similar to the AutoImportJob test, this file contains hardcoded resource names and subscription IDs that should be parameterized for better test maintainability.

Copilot uses AI. Check for mistakes.

Comment on lines +51 to +61
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```

```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```

{{ Add description here }}

Copy link
Preview

Copilot AI Sep 6, 2025

Choose a reason for hiding this comment

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

The help file contains placeholder text for examples that should be replaced with actual working examples to provide meaningful documentation for users.

Suggested change
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```
```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```
{{ Add description here }}
### Example 1: Allocate space to a storage target in a cache
```powershell
$spaceAllocation = @(
@{
Name = "storagetarget1"
Size = 1000
}
)
Invoke-AzStorageCacheSpaceCachAllocation -CacheName "myCache" -ResourceGroupName "myResourceGroup" -SpaceAllocation $spaceAllocation

This example allocates 1000 units of space to the storage target named "storagetarget1" in the cache "myCache" within the resource group "myResourceGroup".

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