Skip to content

Commit ae031c0

Browse files
authored
[AKS] bump SDK-based API version to 2023-02-01 and support PodSubnetID (#21367)
* bump version to 2023-02-01 * fix test case * update changelog * support podSubnetID * update help md and changelog * remove line of bumping version in changelog
1 parent 184550d commit ae031c0

File tree

101 files changed

+24698
-23026
lines changed

Some content is hidden

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

101 files changed

+24698
-23026
lines changed

src/Aks/Aks.Sdk/Generated/AgentPoolsOperations.cs

Lines changed: 354 additions & 7 deletions
Large diffs are not rendered by default.

src/Aks/Aks.Sdk/Generated/AgentPoolsOperationsExtensions.cs

Lines changed: 136 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,64 @@ namespace Microsoft.Azure.Management.ContainerService
2121
/// </summary>
2222
public static partial class AgentPoolsOperationsExtensions
2323
{
24+
/// <summary>
25+
/// Aborts last operation running on agent pool.
26+
/// </summary>
27+
/// <remarks>
28+
/// Aborts the currently running operation on the agent pool. The Agent Pool
29+
/// will be moved to a Canceling state and eventually to a Canceled state when
30+
/// cancellation finishes. If the operation completes before cancellation can
31+
/// take place, a 409 error code is returned.
32+
/// </remarks>
33+
/// <param name='operations'>
34+
/// The operations group for this extension method.
35+
/// </param>
36+
/// <param name='resourceGroupName'>
37+
/// The name of the resource group. The name is case insensitive.
38+
/// </param>
39+
/// <param name='resourceName'>
40+
/// The name of the managed cluster resource.
41+
/// </param>
42+
/// <param name='agentPoolName'>
43+
/// The name of the agent pool.
44+
/// </param>
45+
public static AgentPoolsAbortLatestOperationHeaders AbortLatestOperation(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
46+
{
47+
return operations.AbortLatestOperationAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
48+
}
49+
50+
/// <summary>
51+
/// Aborts last operation running on agent pool.
52+
/// </summary>
53+
/// <remarks>
54+
/// Aborts the currently running operation on the agent pool. The Agent Pool
55+
/// will be moved to a Canceling state and eventually to a Canceled state when
56+
/// cancellation finishes. If the operation completes before cancellation can
57+
/// take place, a 409 error code is returned.
58+
/// </remarks>
59+
/// <param name='operations'>
60+
/// The operations group for this extension method.
61+
/// </param>
62+
/// <param name='resourceGroupName'>
63+
/// The name of the resource group. The name is case insensitive.
64+
/// </param>
65+
/// <param name='resourceName'>
66+
/// The name of the managed cluster resource.
67+
/// </param>
68+
/// <param name='agentPoolName'>
69+
/// The name of the agent pool.
70+
/// </param>
71+
/// <param name='cancellationToken'>
72+
/// The cancellation token.
73+
/// </param>
74+
public static async Task<AgentPoolsAbortLatestOperationHeaders> AbortLatestOperationAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
75+
{
76+
using (var _result = await operations.AbortLatestOperationWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false))
77+
{
78+
return _result.Headers;
79+
}
80+
}
81+
2482
/// <summary>
2583
/// Gets a list of agent pools in the specified managed cluster.
2684
/// </summary>
@@ -174,9 +232,9 @@ public static AgentPool CreateOrUpdate(this IAgentPoolsOperations operations, st
174232
/// <param name='agentPoolName'>
175233
/// The name of the agent pool.
176234
/// </param>
177-
public static void Delete(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
235+
public static AgentPoolsDeleteHeaders Delete(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
178236
{
179-
operations.DeleteAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
237+
return operations.DeleteAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
180238
}
181239

182240
/// <summary>
@@ -197,9 +255,12 @@ public static void Delete(this IAgentPoolsOperations operations, string resource
197255
/// <param name='cancellationToken'>
198256
/// The cancellation token.
199257
/// </param>
200-
public static async Task DeleteAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
258+
public static async Task<AgentPoolsDeleteHeaders> DeleteAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
201259
{
202-
(await operations.DeleteWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false)).Dispose();
260+
using (var _result = await operations.DeleteWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false))
261+
{
262+
return _result.Headers;
263+
}
203264
}
204265

205266
/// <summary>
@@ -253,7 +314,7 @@ public static AgentPoolUpgradeProfile GetUpgradeProfile(this IAgentPoolsOperatio
253314
/// </summary>
254315
/// <remarks>
255316
/// See [supported Kubernetes
256-
/// versions](https://learn.microsoft.com/azure/aks/supported-kubernetes-versions)
317+
/// versions](https://docs.microsoft.com/azure/aks/supported-kubernetes-versions)
257318
/// for more details about the version lifecycle.
258319
/// </remarks>
259320
/// <param name='operations'>
@@ -275,7 +336,7 @@ public static AgentPoolAvailableVersions GetAvailableAgentPoolVersions(this IAge
275336
/// </summary>
276337
/// <remarks>
277338
/// See [supported Kubernetes
278-
/// versions](https://learn.microsoft.com/azure/aks/supported-kubernetes-versions)
339+
/// versions](https://docs.microsoft.com/azure/aks/supported-kubernetes-versions)
279340
/// for more details about the version lifecycle.
280341
/// </remarks>
281342
/// <param name='operations'>
@@ -305,7 +366,7 @@ public static AgentPoolAvailableVersions GetAvailableAgentPoolVersions(this IAge
305366
/// Upgrading the node image version of an agent pool applies the newest OS and
306367
/// runtime updates to the nodes. AKS provides one new image per week with the
307368
/// latest updates. For more details on node image versions, see:
308-
/// https://learn.microsoft.com/azure/aks/node-image-upgrade
369+
/// https://docs.microsoft.com/azure/aks/node-image-upgrade
309370
/// </remarks>
310371
/// <param name='operations'>
311372
/// The operations group for this extension method.
@@ -331,7 +392,7 @@ public static AgentPool UpgradeNodeImageVersion(this IAgentPoolsOperations opera
331392
/// Upgrading the node image version of an agent pool applies the newest OS and
332393
/// runtime updates to the nodes. AKS provides one new image per week with the
333394
/// latest updates. For more details on node image versions, see:
334-
/// https://learn.microsoft.com/azure/aks/node-image-upgrade
395+
/// https://docs.microsoft.com/azure/aks/node-image-upgrade
335396
/// </remarks>
336397
/// <param name='operations'>
337398
/// The operations group for this extension method.
@@ -356,6 +417,64 @@ public static AgentPool UpgradeNodeImageVersion(this IAgentPoolsOperations opera
356417
}
357418
}
358419

420+
/// <summary>
421+
/// Aborts last operation running on agent pool.
422+
/// </summary>
423+
/// <remarks>
424+
/// Aborts the currently running operation on the agent pool. The Agent Pool
425+
/// will be moved to a Canceling state and eventually to a Canceled state when
426+
/// cancellation finishes. If the operation completes before cancellation can
427+
/// take place, a 409 error code is returned.
428+
/// </remarks>
429+
/// <param name='operations'>
430+
/// The operations group for this extension method.
431+
/// </param>
432+
/// <param name='resourceGroupName'>
433+
/// The name of the resource group. The name is case insensitive.
434+
/// </param>
435+
/// <param name='resourceName'>
436+
/// The name of the managed cluster resource.
437+
/// </param>
438+
/// <param name='agentPoolName'>
439+
/// The name of the agent pool.
440+
/// </param>
441+
public static AgentPoolsAbortLatestOperationHeaders BeginAbortLatestOperation(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
442+
{
443+
return operations.BeginAbortLatestOperationAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
444+
}
445+
446+
/// <summary>
447+
/// Aborts last operation running on agent pool.
448+
/// </summary>
449+
/// <remarks>
450+
/// Aborts the currently running operation on the agent pool. The Agent Pool
451+
/// will be moved to a Canceling state and eventually to a Canceled state when
452+
/// cancellation finishes. If the operation completes before cancellation can
453+
/// take place, a 409 error code is returned.
454+
/// </remarks>
455+
/// <param name='operations'>
456+
/// The operations group for this extension method.
457+
/// </param>
458+
/// <param name='resourceGroupName'>
459+
/// The name of the resource group. The name is case insensitive.
460+
/// </param>
461+
/// <param name='resourceName'>
462+
/// The name of the managed cluster resource.
463+
/// </param>
464+
/// <param name='agentPoolName'>
465+
/// The name of the agent pool.
466+
/// </param>
467+
/// <param name='cancellationToken'>
468+
/// The cancellation token.
469+
/// </param>
470+
public static async Task<AgentPoolsAbortLatestOperationHeaders> BeginAbortLatestOperationAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
471+
{
472+
using (var _result = await operations.BeginAbortLatestOperationWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false))
473+
{
474+
return _result.Headers;
475+
}
476+
}
477+
359478
/// <summary>
360479
/// Creates or updates an agent pool in the specified managed cluster.
361480
/// </summary>
@@ -423,9 +542,9 @@ public static AgentPool BeginCreateOrUpdate(this IAgentPoolsOperations operation
423542
/// <param name='agentPoolName'>
424543
/// The name of the agent pool.
425544
/// </param>
426-
public static void BeginDelete(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
545+
public static AgentPoolsDeleteHeaders BeginDelete(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName)
427546
{
428-
operations.BeginDeleteAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
547+
return operations.BeginDeleteAsync(resourceGroupName, resourceName, agentPoolName).GetAwaiter().GetResult();
429548
}
430549

431550
/// <summary>
@@ -446,9 +565,12 @@ public static void BeginDelete(this IAgentPoolsOperations operations, string res
446565
/// <param name='cancellationToken'>
447566
/// The cancellation token.
448567
/// </param>
449-
public static async Task BeginDeleteAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
568+
public static async Task<AgentPoolsDeleteHeaders> BeginDeleteAsync(this IAgentPoolsOperations operations, string resourceGroupName, string resourceName, string agentPoolName, CancellationToken cancellationToken = default(CancellationToken))
450569
{
451-
(await operations.BeginDeleteWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false)).Dispose();
570+
using (var _result = await operations.BeginDeleteWithHttpMessagesAsync(resourceGroupName, resourceName, agentPoolName, null, cancellationToken).ConfigureAwait(false))
571+
{
572+
return _result.Headers;
573+
}
452574
}
453575

454576
/// <summary>
@@ -458,7 +580,7 @@ public static void BeginDelete(this IAgentPoolsOperations operations, string res
458580
/// Upgrading the node image version of an agent pool applies the newest OS and
459581
/// runtime updates to the nodes. AKS provides one new image per week with the
460582
/// latest updates. For more details on node image versions, see:
461-
/// https://learn.microsoft.com/azure/aks/node-image-upgrade
583+
/// https://docs.microsoft.com/azure/aks/node-image-upgrade
462584
/// </remarks>
463585
/// <param name='operations'>
464586
/// The operations group for this extension method.
@@ -484,7 +606,7 @@ public static AgentPool BeginUpgradeNodeImageVersion(this IAgentPoolsOperations
484606
/// Upgrading the node image version of an agent pool applies the newest OS and
485607
/// runtime updates to the nodes. AKS provides one new image per week with the
486608
/// latest updates. For more details on node image versions, see:
487-
/// https://learn.microsoft.com/azure/aks/node-image-upgrade
609+
/// https://docs.microsoft.com/azure/aks/node-image-upgrade
488610
/// </remarks>
489611
/// <param name='operations'>
490612
/// The operations group for this extension method.

src/Aks/Aks.Sdk/Generated/ContainerServiceClient.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ private void Initialize()
364364
ResolvePrivateLinkServiceId = new ResolvePrivateLinkServiceIdOperations(this);
365365
Snapshots = new SnapshotsOperations(this);
366366
BaseUri = new System.Uri("https://management.azure.com");
367-
ApiVersion = "2022-09-01";
367+
ApiVersion = "2023-02-01";
368368
AcceptLanguage = "en-US";
369369
LongRunningOperationRetryTimeout = 30;
370370
GenerateClientRequestId = true;

0 commit comments

Comments
 (0)