Skip to content

[skip ci] Archive e43e09834049e3a7e00332e9859b468f2eb4c445 #27967

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

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -847,6 +847,52 @@
</TableRowEntries>
</TableControl>
</View>
<View>
<Name>Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Models.StorageTaskUpdateProperties</Name>
<ViewSelectedBy>
<TypeName>Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Models.StorageTaskUpdateProperties#Multiple</TypeName>
</ViewSelectedBy>
<TableControl>
<TableHeaders>
<TableColumnHeader>
<Label>CreationTimeInUtc</Label>
</TableColumnHeader>
<TableColumnHeader>
<Label>Description</Label>
</TableColumnHeader>
<TableColumnHeader>
<Label>Enabled</Label>
</TableColumnHeader>
<TableColumnHeader>
<Label>ProvisioningState</Label>
</TableColumnHeader>
<TableColumnHeader>
<Label>TaskVersion</Label>
</TableColumnHeader>
</TableHeaders>
<TableRowEntries>
<TableRowEntry>
<TableColumnItems>
<TableColumnItem>
<PropertyName>CreationTimeInUtc</PropertyName>
</TableColumnItem>
<TableColumnItem>
<PropertyName>Description</PropertyName>
</TableColumnItem>
<TableColumnItem>
<PropertyName>Enabled</PropertyName>
</TableColumnItem>
<TableColumnItem>
<PropertyName>ProvisioningState</PropertyName>
</TableColumnItem>
<TableColumnItem>
<PropertyName>TaskVersion</PropertyName>
</TableColumnItem>
</TableColumnItems>
</TableRowEntry>
</TableRowEntries>
</TableControl>
</View>
<View>
<Name>Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Models.SystemData</Name>
<ViewSelectedBy>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@{
GUID = 'cc1d1de1-1601-4440-82c6-76c6673d8aba'
RootModule = './Az.StorageAction.psm1'
ModuleVersion = '0.1.0'
ModuleVersion = '1.0.0'
CompatiblePSEditions = 'Core', 'Desktop'
Author = 'Microsoft Corporation'
CompanyName = 'Microsoft Corporation'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the Apache License, Version 2.0 (the ""License"");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an ""AS IS"" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code
// is regenerated.

using System;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

[assembly: System.Reflection.AssemblyCompanyAttribute("Microsoft")]
[assembly: System.Reflection.AssemblyCopyrightAttribute("Copyright © Microsoft")]
[assembly: System.Reflection.AssemblyProductAttribute("Microsoft Azure PowerShell")]
[assembly: System.Reflection.AssemblyTitleAttribute("Microsoft Azure PowerShell - StorageAction")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("0.1.2")]
[assembly: System.Reflection.AssemblyVersionAttribute("0.1.2")]
[assembly: System.Runtime.InteropServices.ComVisibleAttribute(false)]
[assembly: System.CLSCompliantAttribute(false)]




Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,15 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

$context = Get-AzContext
if (-not $context -and -not $testPlayback) {
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
exit
}

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand All @@ -159,8 +168,6 @@ begin {
List1 = 'Az.StorageAction.private\Get-AzStorageActionTask_List1';
}
if (('Get', 'List', 'List1') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
if ($testPlayback) {
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
} else {
Expand All @@ -174,6 +181,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ param(

[Parameter()]
[Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Category('Query')]
[System.String]
[System.Int32]
# Optional, specifies the maximum number of Storage Task Assignment Resource IDs to be included in the list response.
${Maxpagesize},

Expand Down Expand Up @@ -115,6 +115,15 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

$context = Get-AzContext
if (-not $context -and -not $testPlayback) {
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
exit
}

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand All @@ -137,8 +146,6 @@ begin {
List = 'Az.StorageAction.private\Get-AzStorageActionTaskAssignment_List';
}
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
if ($testPlayback) {
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
} else {
Expand All @@ -152,6 +159,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ param(

[Parameter()]
[Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Category('Query')]
[System.String]
[System.Int32]
# Optional, specifies the maximum number of Storage Task Assignment Resource IDs to be included in the list response.
${Maxpagesize},

Expand Down Expand Up @@ -122,6 +122,15 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

$context = Get-AzContext
if (-not $context -and -not $testPlayback) {
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
exit
}

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand All @@ -144,8 +153,6 @@ begin {
List = 'Az.StorageAction.private\Get-AzStorageActionTasksReport_List';
}
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
if ($testPlayback) {
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
} else {
Expand All @@ -159,6 +166,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,15 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

$context = Get-AzContext
if (-not $context -and -not $testPlayback) {
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
exit
}

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand All @@ -239,8 +248,6 @@ begin {
PreviewViaJsonString = 'Az.StorageAction.private\Invoke-AzStorageActionTaskPreviewAction_PreviewViaJsonString';
}
if (('PreviewExpanded', 'PreviewViaJsonFilePath', 'PreviewViaJsonString') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
if ($testPlayback) {
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
} else {
Expand All @@ -254,6 +261,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@

<#
.Synopsis
Asynchronously creates a new storage task resource with the specified parameters.
Asynchronously create a new storage task resource with the specified parameters.
If a storage task is already created and a subsequent create request is issued with different properties, the storage task properties will be updated.
If a storage task is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
If a storage task is already created and a subsequent create request is issued with the exact same set of properties, the request will succeed.
.Description
Asynchronously creates a new storage task resource with the specified parameters.
Asynchronously create a new storage task resource with the specified parameters.
If a storage task is already created and a subsequent create request is issued with different properties, the storage task properties will be updated.
If a storage task is already created and a subsequent create or update request is issued with the exact same set of properties, the request will succeed.
If a storage task is already created and a subsequent create request is issued with the exact same set of properties, the request will succeed.
.Example
$ifoperation = New-AzStorageActionTaskOperationObject -Name SetBlobTier -Parameter @{"tier"= "Hot"} -OnFailure break -OnSuccess continue
New-AzStorageActionTask -Name mytask1 -ResourceGroupName group001 -Location eastus2euap -Enabled -Description 'my storage task' -IfCondition "[[equals(AccessTier, 'Cool')]]" -IfOperation $ifoperation
Expand Down Expand Up @@ -128,7 +128,7 @@ param(
[Parameter(ParameterSetName='CreateExpanded')]
[Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Category('Body')]
[System.Management.Automation.SwitchParameter]
# Decides if enable a system assigned identity for the resource.
# Determines whether to enable a system-assigned identity for the resource.
${EnableSystemAssignedIdentity},

[Parameter(ParameterSetName='CreateExpanded')]
Expand Down Expand Up @@ -226,6 +226,15 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

$context = Get-AzContext
if (-not $context -and -not $testPlayback) {
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
exit
}

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand All @@ -250,8 +259,6 @@ begin {
CreateViaJsonString = 'Az.StorageAction.private\New-AzStorageActionTask_CreateViaJsonString';
}
if (('CreateExpanded', 'CreateViaJsonFilePath', 'CreateViaJsonString') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
if ($testPlayback) {
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
} else {
Expand All @@ -265,6 +272,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ begin {
$PSBoundParameters['OutBuffer'] = 1
}
$parameterSet = $PSCmdlet.ParameterSetName

$testPlayback = $false
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.StorageAction.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }

if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
Expand Down Expand Up @@ -101,6 +104,9 @@ begin {
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
}
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
if ($wrappedCmd -eq $null) {
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
}
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
$steppablePipeline.Begin($PSCmdlet)
Expand Down
Loading