Skip to content

Commit 5fc34b0

Browse files
Migrate Fleet from generation to main (#24430)
* Move Fleet to main * Update ChangeLog.md * Update ChangeLog.md --------- Co-authored-by: Vincent Dai <[email protected]>
1 parent ba82fa9 commit 5fc34b0

File tree

132 files changed

+2017
-238
lines changed

Some content is hidden

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

132 files changed

+2017
-238
lines changed

src/Fleet/Fleet.Autorest/Az.Fleet.psm1

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -47,37 +47,41 @@
4747

4848
# Ask for the shared functionality table
4949
$VTable = Register-AzModule
50-
50+
5151
# Tweaks the pipeline on module load
5252
$instance.OnModuleLoad = $VTable.OnModuleLoad
5353

5454
# Following two delegates are added for telemetry
5555
$instance.GetTelemetryId = $VTable.GetTelemetryId
5656
$instance.Telemetry = $VTable.Telemetry
57-
57+
58+
# Delegate to sanitize the output object
59+
$instance.SanitizeOutput = $VTable.SanitizerHandler
60+
61+
# Delegate to get the telemetry info
62+
$instance.GetTelemetryInfo = $VTable.GetTelemetryInfo
5863

5964
# Tweaks the pipeline per call
6065
$instance.OnNewRequest = $VTable.OnNewRequest
61-
66+
6267
# Gets shared parameter values
6368
$instance.GetParameterValue = $VTable.GetParameterValue
64-
69+
6570
# Allows shared module to listen to events from this module
6671
$instance.EventListener = $VTable.EventListener
67-
72+
6873
# Gets shared argument completers
6974
$instance.ArgumentCompleter = $VTable.ArgumentCompleter
70-
75+
7176
# The name of the currently selected Azure profile
7277
$instance.ProfileName = $VTable.ProfileName
7378

74-
7579
# Load the custom module
7680
$customModulePath = Join-Path $PSScriptRoot './custom/Az.Fleet.custom.psm1'
7781
if(Test-Path $customModulePath) {
7882
$null = Import-Module -Name $customModulePath
7983
}
80-
84+
8185
# Export nothing to clear implicit exports
8286
Export-ModuleMember
8387

@@ -97,12 +101,12 @@
97101
# Load the last folder if no profile is selected
98102
$profileDirectory = $directories | Select-Object -Last 1
99103
}
100-
104+
101105
if($profileDirectory) {
102106
Write-Information "Loaded Azure profile '$($profileDirectory.Name)' for module '$($instance.Name)'"
103107
$exportsPath = $profileDirectory.FullName
104108
}
105-
109+
106110
if($exportsPath) {
107111
Get-ChildItem -Path $exportsPath -Recurse -Include '*.ps1' -File | ForEach-Object { . $_.FullName }
108112
$cmdletNames = Get-ScriptCmdlet -ScriptFolder $exportsPath

src/Fleet/Fleet.Autorest/README.md

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
This directory contains the PowerShell module for the Fleet service.
44

55
---
6-
76
## Info
87
- Modifiable: yes
98
- Generated: all
@@ -38,6 +37,8 @@ require:
3837
title: Fleet
3938
module-version: 0.1.0
4039
subject-prefix: $(service-name)
40+
disable-transform-identity-type: true
41+
flatten-userassignedidentity: false
4142

4243
directive:
4344
# # # Following is two common directive which are normally required in all the RPs
@@ -56,6 +57,23 @@ directive:
5657
- from: swagger-document
5758
where: $.definitions.UpdateRun
5859
transform: $['required'] = ['properties']
60+
- from: swagger-document
61+
where: $.definitions.FleetUpdateStrategy.properties.properties.x-ms-mutability
62+
transform: >-
63+
return [
64+
"read",
65+
"update",
66+
"create"
67+
]
68+
- from: swagger-document
69+
where: $.definitions.UpdateRun.properties.properties
70+
transform: $['x-ms-mutability'] = ["read", "update", "create"]
71+
- from: swagger-document
72+
where: $.definitions.ManagedClusterUpdate.properties.nodeImageSelection
73+
transform: $['x-ms-mutability'] = ["read", "update", "create"]
74+
- from: swagger-document
75+
where: $.definitions.NodeImageSelection.properties.type
76+
transform: $['x-ms-mutability'] = ["read", "update", "create"]
5977
# Hide set cmdlet
6078
- where:
6179
verb: Set

src/Fleet/Fleet.Autorest/exports/Get-AzFleet.ps1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ param(
7676
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
7777
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
7878
# Identity Parameter
79-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
8079
${InputObject},
8180

8281
[Parameter()]

src/Fleet/Fleet.Autorest/exports/Get-AzFleetMember.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,12 @@ param(
9292
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
9393
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
9494
# Identity Parameter
95-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
9695
${InputObject},
9796

9897
[Parameter(ParameterSetName='GetViaIdentityFleet', Mandatory, ValueFromPipeline)]
9998
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
10099
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
101100
# Identity Parameter
102-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
103101
${FleetInputObject},
104102

105103
[Parameter()]

src/Fleet/Fleet.Autorest/exports/Get-AzFleetUpdateRun.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,14 +92,12 @@ param(
9292
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
9393
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
9494
# Identity Parameter
95-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
9695
${InputObject},
9796

9897
[Parameter(ParameterSetName='GetViaIdentityFleet', Mandatory, ValueFromPipeline)]
9998
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
10099
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
101100
# Identity Parameter
102-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
103101
${FleetInputObject},
104102

105103
[Parameter()]

src/Fleet/Fleet.Autorest/exports/Get-AzFleetUpdateStrategy.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,14 +91,12 @@ param(
9191
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
9292
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
9393
# Identity Parameter
94-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
9594
${InputObject},
9695

9796
[Parameter(ParameterSetName='GetViaIdentityFleet', Mandatory, ValueFromPipeline)]
9897
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
9998
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
10099
# Identity Parameter
101-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
102100
${FleetInputObject},
103101

104102
[Parameter()]

src/Fleet/Fleet.Autorest/exports/New-AzFleet.ps1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ param(
7777
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
7878
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
7979
# Identity Parameter
80-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
8180
${InputObject},
8281

8382
[Parameter()]

src/Fleet/Fleet.Autorest/exports/New-AzFleetMember.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -95,14 +95,12 @@ param(
9595
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
9696
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
9797
# Identity Parameter
98-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
9998
${InputObject},
10099

101100
[Parameter(ParameterSetName='CreateViaIdentityFleetExpanded', Mandatory, ValueFromPipeline)]
102101
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
103102
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
104103
# Identity Parameter
105-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
106104
${FleetInputObject},
107105

108106
[Parameter()]

src/Fleet/Fleet.Autorest/exports/New-AzFleetUpdateRun.ps1

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,14 +101,12 @@ param(
101101
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
102102
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
103103
# Identity Parameter
104-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
105104
${InputObject},
106105

107106
[Parameter(ParameterSetName='CreateViaIdentityFleetExpanded', Mandatory, ValueFromPipeline)]
108107
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
109108
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
110109
# Identity Parameter
111-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
112110
${FleetInputObject},
113111

114112
[Parameter()]
@@ -149,7 +147,6 @@ param(
149147
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IUpdateStage[]]
150148
# The list of stages that compose this update run.
151149
# Min size: 1.
152-
# To construct, see NOTES section for STRATEGYSTAGE properties and create a hash table.
153150
${StrategyStage},
154151

155152
[Parameter(ParameterSetName='CreateExpanded')]

src/Fleet/Fleet.Autorest/exports/New-AzFleetUpdateStageObject.ps1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ param(
6363
# Defines the groups to be executed in parallel in this stage.
6464
# Duplicate groups are not allowed.
6565
# Min size: 1.
66-
# To construct, see NOTES section for GROUP properties and create a hash table.
6766
${Group}
6867
)
6968

src/Fleet/Fleet.Autorest/exports/New-AzFleetUpdateStrategy.ps1

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,14 +105,12 @@ param(
105105
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
106106
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
107107
# Identity Parameter
108-
# To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
109108
${InputObject},
110109

111110
[Parameter(ParameterSetName='CreateViaIdentityFleetExpanded', Mandatory, ValueFromPipeline)]
112111
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Category('Path')]
113112
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IFleetIdentity]
114113
# Identity Parameter
115-
# To construct, see NOTES section for FLEETINPUTOBJECT properties and create a hash table.
116114
${FleetInputObject},
117115

118116
[Parameter()]
@@ -135,7 +133,6 @@ param(
135133
[Microsoft.Azure.PowerShell.Cmdlets.Fleet.Models.IUpdateStage[]]
136134
# The list of stages that compose this update run.
137135
# Min size: 1.
138-
# To construct, see NOTES section for STRATEGYSTAGE properties and create a hash table.
139136
${StrategyStage},
140137

141138
[Parameter(ParameterSetName='CreateViaJsonFilePath', Mandatory)]

0 commit comments

Comments
 (0)