Skip to content

Commit 2b9b9a0

Browse files
[skip ci] Archive 1020487 (#27628)
1 parent f0c2ef8 commit 2b9b9a0

File tree

374 files changed

+30925
-11913
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

374 files changed

+30925
-11913
lines changed

generated/DynatraceObservability/DynatraceObservability.Autorest/Az.DynatraceObservability.format.ps1xml

Lines changed: 387 additions & 427 deletions
Large diffs are not rendered by default.

generated/DynatraceObservability/DynatraceObservability.Autorest/Az.DynatraceObservability.psd1

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
DotNetFrameworkVersion = '4.7.2'
1212
RequiredAssemblies = './bin/Az.DynatraceObservability.private.dll'
1313
FormatsToProcess = './Az.DynatraceObservability.format.ps1xml'
14-
FunctionsToExport = 'Get-AzDynatraceMonitor', 'Get-AzDynatraceMonitorAppService', 'Get-AzDynatraceMonitoredResource', 'Get-AzDynatraceMonitorHost', 'Get-AzDynatraceMonitorLinkableEnv', 'Get-AzDynatraceMonitorMarketplaceSaaSResourceDetail', 'Get-AzDynatraceMonitorMetricStatus', 'Get-AzDynatraceMonitorSSOConfig', 'Get-AzDynatraceMonitorSSODetail', 'Get-AzDynatraceMonitorTagRule', 'Get-AzDynatraceMonitorVMHostPayload', 'New-AzDynatraceMonitor', 'New-AzDynatraceMonitorFilteringTagObject', 'New-AzDynatraceMonitorSSOConfig', 'New-AzDynatraceMonitorTagRule', 'Remove-AzDynatraceMonitor', 'Remove-AzDynatraceMonitorTagRule', 'Update-AzDynatraceMonitor', '*'
15-
AliasesToExport = '*'
14+
FunctionsToExport = 'Get-AzDynatraceMonitor', 'Get-AzDynatraceMonitorAppService', 'Get-AzDynatraceMonitoredResource', 'Get-AzDynatraceMonitorHost', 'Get-AzDynatraceMonitorLinkableEnv', 'Get-AzDynatraceMonitorMarketplaceSaaSResourceDetail', 'Get-AzDynatraceMonitorMetricStatus', 'Get-AzDynatraceMonitorSSOConfig', 'Get-AzDynatraceMonitorSSODetail', 'Get-AzDynatraceMonitorTagRule', 'Get-AzDynatraceMonitorVMHostPayload', 'New-AzDynatraceMonitor', 'New-AzDynatraceMonitorFilteringTagObject', 'New-AzDynatraceMonitorSSOConfig', 'New-AzDynatraceMonitorTagRule', 'Remove-AzDynatraceMonitor', 'Remove-AzDynatraceMonitorTagRule', 'Update-AzDynatraceMonitor', 'Update-AzDynatraceMonitorSSOConfig', 'Update-AzDynatraceMonitorTagRule'
1615
PrivateData = @{
1716
PSData = @{
1817
Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'DynatraceObservability'

generated/DynatraceObservability/DynatraceObservability.Autorest/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
[assembly: System.Reflection.AssemblyCopyrightAttribute("Copyright © Microsoft")]
2121
[assembly: System.Reflection.AssemblyProductAttribute("Microsoft Azure PowerShell")]
2222
[assembly: System.Reflection.AssemblyTitleAttribute("Microsoft Azure PowerShell - DynatraceObservability")]
23-
[assembly: System.Reflection.AssemblyFileVersionAttribute("0.1.2")]
24-
[assembly: System.Reflection.AssemblyVersionAttribute("0.1.2")]
23+
[assembly: System.Reflection.AssemblyFileVersionAttribute("0.2.0")]
24+
[assembly: System.Reflection.AssemblyVersionAttribute("0.2.0")]
2525
[assembly: System.Runtime.InteropServices.ComVisibleAttribute(false)]
2626
[assembly: System.CLSCompliantAttribute(false)]
2727

generated/DynatraceObservability/DynatraceObservability.Autorest/check-dependencies.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@
1212
# Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code
1313
# is regenerated.
1414
# ----------------------------------------------------------------------------------
15-
param([switch]$Isolated, [switch]$Accounts, [switch]$Pester, [switch]$Resources)
15+
param([switch]$NotIsolated, [switch]$Accounts, [switch]$Pester, [switch]$Resources)
1616
$ErrorActionPreference = 'Stop'
1717

18-
if(-not $Isolated) {
18+
if(-not $NotIsolated) {
1919
Write-Host -ForegroundColor Green 'Creating isolated process...'
2020
$pwsh = [System.Diagnostics.Process]::GetCurrentProcess().Path
21-
& "$pwsh" -NoExit -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -Isolated
21+
& "$pwsh" -NoExit -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -NotIsolated
2222
return
2323
}
2424

generated/DynatraceObservability/DynatraceObservability.Autorest/exports/Get-AzDynatraceMonitor.ps1

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ New-AzDynatraceMonitor -ResourceGroupName dyobrg -Name dyob-pwsh01 -Location eas
3131
.Inputs
3232
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IDynatraceObservabilityIdentity
3333
.Outputs
34-
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IMonitorResource
34+
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IMonitorResource
3535
.Notes
3636
COMPLEX PARAMETER PROPERTIES
3737
@@ -48,7 +48,7 @@ INPUTOBJECT <IDynatraceObservabilityIdentity>: Identity Parameter
4848
https://learn.microsoft.com/powershell/module/az.dynatraceobservability/get-azdynatracemonitor
4949
#>
5050
function Get-AzDynatraceMonitor {
51-
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IMonitorResource])]
51+
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IMonitorResource])]
5252
[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
5353
param(
5454
[Parameter(ParameterSetName='Get', Mandatory)]
@@ -79,7 +79,6 @@ param(
7979
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Path')]
8080
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IDynatraceObservabilityIdentity]
8181
# Identity Parameter
82-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
8382
${InputObject},
8483

8584
[Parameter()]
@@ -138,6 +137,15 @@ begin {
138137
$PSBoundParameters['OutBuffer'] = 1
139138
}
140139
$parameterSet = $PSCmdlet.ParameterSetName
140+
141+
$testPlayback = $false
142+
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
143+
144+
$context = Get-AzContext
145+
if (-not $context -and -not $testPlayback) {
146+
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
147+
exit
148+
}
141149

142150
if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
143151
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
@@ -162,9 +170,7 @@ begin {
162170
List = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitor_List';
163171
List1 = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitor_List1';
164172
}
165-
if (('Get', 'List', 'List1') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId')) {
166-
$testPlayback = $false
167-
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
173+
if (('Get', 'List', 'List1') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
168174
if ($testPlayback) {
169175
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
170176
} else {
@@ -178,6 +184,9 @@ begin {
178184
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
179185
}
180186
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
187+
if ($wrappedCmd -eq $null) {
188+
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
189+
}
181190
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
182191
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
183192
$steppablePipeline.Begin($PSCmdlet)

generated/DynatraceObservability/DynatraceObservability.Autorest/exports/Get-AzDynatraceMonitorAppService.ps1

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@ Gets list of App Services with Dynatrace PaaS OneAgent enabled
2323
Get-AzDynatraceMonitorAppService -ResourceGroupName dyobrg -MonitorName dyob-pwsh01
2424
2525
.Outputs
26-
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IAppServiceInfo
26+
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IAppServiceInfo
2727
.Link
2828
https://learn.microsoft.com/powershell/module/az.dynatraceobservability/get-azdynatracemonitorappservice
2929
#>
3030
function Get-AzDynatraceMonitorAppService {
31-
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IAppServiceInfo])]
31+
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IAppServiceInfo])]
3232
[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
3333
param(
3434
[Parameter(Mandatory)]
@@ -107,6 +107,15 @@ begin {
107107
$PSBoundParameters['OutBuffer'] = 1
108108
}
109109
$parameterSet = $PSCmdlet.ParameterSetName
110+
111+
$testPlayback = $false
112+
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
113+
114+
$context = Get-AzContext
115+
if (-not $context -and -not $testPlayback) {
116+
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
117+
exit
118+
}
110119

111120
if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
112121
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
@@ -128,9 +137,7 @@ begin {
128137
$mapping = @{
129138
List = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitorAppService_List';
130139
}
131-
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId')) {
132-
$testPlayback = $false
133-
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
140+
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
134141
if ($testPlayback) {
135142
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
136143
} else {
@@ -144,6 +151,9 @@ begin {
144151
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
145152
}
146153
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
154+
if ($wrappedCmd -eq $null) {
155+
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
156+
}
147157
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
148158
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
149159
$steppablePipeline.Begin($PSCmdlet)

generated/DynatraceObservability/DynatraceObservability.Autorest/exports/Get-AzDynatraceMonitorHost.ps1

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@ List the VM/VMSS resources currently being monitored by the Dynatrace resource.
2323
Get-AzDynatraceMonitorHost -ResourceGroupName dyobrg -MonitorName dyob-pwsh01
2424
2525
.Outputs
26-
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IVMInfo
26+
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IVMInfo
2727
.Link
2828
https://learn.microsoft.com/powershell/module/az.dynatraceobservability/get-azdynatracemonitorhost
2929
#>
3030
function Get-AzDynatraceMonitorHost {
31-
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.IVMInfo])]
31+
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.IVMInfo])]
3232
[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
3333
param(
3434
[Parameter(Mandatory)]
@@ -107,6 +107,15 @@ begin {
107107
$PSBoundParameters['OutBuffer'] = 1
108108
}
109109
$parameterSet = $PSCmdlet.ParameterSetName
110+
111+
$testPlayback = $false
112+
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
113+
114+
$context = Get-AzContext
115+
if (-not $context -and -not $testPlayback) {
116+
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
117+
exit
118+
}
110119

111120
if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
112121
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
@@ -128,9 +137,7 @@ begin {
128137
$mapping = @{
129138
List = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitorHost_List';
130139
}
131-
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId')) {
132-
$testPlayback = $false
133-
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
140+
if (('List') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
134141
if ($testPlayback) {
135142
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
136143
} else {
@@ -144,6 +151,9 @@ begin {
144151
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
145152
}
146153
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
154+
if ($wrappedCmd -eq $null) {
155+
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
156+
}
147157
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
148158
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
149159
$steppablePipeline.Begin($PSCmdlet)

generated/DynatraceObservability/DynatraceObservability.Autorest/exports/Get-AzDynatraceMonitorLinkableEnv.ps1

Lines changed: 33 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,13 @@ Gets all the Dynatrace environments that a user can link a azure resource to
2323
Get-AzDynatraceMonitorLinkableEnv -ResourceGroupName dyobrg -Name dyob-pwsh01 -Region 'East US' -UserPrincipal '[email protected]' -TenantId 'xxxxxxxx-xxxxx-xxxx-xxxx-xxxxx'
2424
2525
.Outputs
26-
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.ILinkableEnvironmentResponse
26+
Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.ILinkableEnvironmentResponse
2727
.Link
2828
https://learn.microsoft.com/powershell/module/az.dynatraceobservability/get-azdynatracemonitorlinkableenv
2929
#>
3030
function Get-AzDynatraceMonitorLinkableEnv {
31-
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.Api20230427.ILinkableEnvironmentResponse])]
32-
[CmdletBinding(DefaultParameterSetName='ListExpanded', PositionalBinding=$false)]
31+
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Models.ILinkableEnvironmentResponse])]
32+
[CmdletBinding(DefaultParameterSetName='ListExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
3333
param(
3434
[Parameter(Mandatory)]
3535
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Path')]
@@ -51,24 +51,36 @@ param(
5151
# The ID of the target subscription.
5252
${SubscriptionId},
5353

54-
[Parameter(Mandatory)]
54+
[Parameter(ParameterSetName='ListExpanded', Mandatory)]
5555
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Body')]
5656
[System.String]
5757
# Azure region in which we want to link the environment
5858
${Region},
5959

60-
[Parameter(Mandatory)]
60+
[Parameter(ParameterSetName='ListExpanded', Mandatory)]
6161
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Body')]
6262
[System.String]
6363
# Tenant Id of the user in which they want to link the environment
6464
${TenantId},
6565

66-
[Parameter(Mandatory)]
66+
[Parameter(ParameterSetName='ListExpanded', Mandatory)]
6767
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Body')]
6868
[System.String]
6969
# user principal id of the user
7070
${UserPrincipal},
7171

72+
[Parameter(ParameterSetName='ListViaJsonFilePath', Mandatory)]
73+
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Body')]
74+
[System.String]
75+
# Path of Json file supplied to the List operation
76+
${JsonFilePath},
77+
78+
[Parameter(ParameterSetName='ListViaJsonString', Mandatory)]
79+
[Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Category('Body')]
80+
[System.String]
81+
# Json string supplied to the List operation
82+
${JsonString},
83+
7284
[Parameter()]
7385
[Alias('AzureRMContext', 'AzureCredential')]
7486
[ValidateNotNull()]
@@ -125,6 +137,15 @@ begin {
125137
$PSBoundParameters['OutBuffer'] = 1
126138
}
127139
$parameterSet = $PSCmdlet.ParameterSetName
140+
141+
$testPlayback = $false
142+
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
143+
144+
$context = Get-AzContext
145+
if (-not $context -and -not $testPlayback) {
146+
Write-Error "No Azure login detected. Please run 'Connect-AzAccount' to log in."
147+
exit
148+
}
128149

129150
if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
130151
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $PSVersionTable.PSVersion.ToString()
@@ -145,10 +166,10 @@ begin {
145166

146167
$mapping = @{
147168
ListExpanded = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitorLinkableEnv_ListExpanded';
169+
ListViaJsonFilePath = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitorLinkableEnv_ListViaJsonFilePath';
170+
ListViaJsonString = 'Az.DynatraceObservability.private\Get-AzDynatraceMonitorLinkableEnv_ListViaJsonString';
148171
}
149-
if (('ListExpanded') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId')) {
150-
$testPlayback = $false
151-
$PSBoundParameters['HttpPipelinePrepend'] | Foreach-Object { if ($_) { $testPlayback = $testPlayback -or ('Microsoft.Azure.PowerShell.Cmdlets.DynatraceObservability.Runtime.PipelineMock' -eq $_.Target.GetType().FullName -and 'Playback' -eq $_.Target.Mode) } }
172+
if (('ListExpanded', 'ListViaJsonFilePath', 'ListViaJsonString') -contains $parameterSet -and -not $PSBoundParameters.ContainsKey('SubscriptionId') ) {
152173
if ($testPlayback) {
153174
$PSBoundParameters['SubscriptionId'] = . (Join-Path $PSScriptRoot '..' 'utils' 'Get-SubscriptionIdTestSafe.ps1')
154175
} else {
@@ -162,6 +183,9 @@ begin {
162183
[Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PromptedPreviewMessageCmdlets.Enqueue($MyInvocation.MyCommand.Name)
163184
}
164185
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
186+
if ($wrappedCmd -eq $null) {
187+
$wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Function)
188+
}
165189
$scriptCmd = {& $wrappedCmd @PSBoundParameters}
166190
$steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
167191
$steppablePipeline.Begin($PSCmdlet)

0 commit comments

Comments
 (0)