diff --git a/sdk/containerservice/arm-containerservice/CHANGELOG.md b/sdk/containerservice/arm-containerservice/CHANGELOG.md index 5a0651a07ec4..0da58c66672d 100644 --- a/sdk/containerservice/arm-containerservice/CHANGELOG.md +++ b/sdk/containerservice/arm-containerservice/CHANGELOG.md @@ -1,5 +1,49 @@ # Release History +## 19.4.0 (2023-08-28) + +**Features** + + - Added operation ManagedClusters.getMeshRevisionProfile + - Added operation ManagedClusters.getMeshUpgradeProfile + - Added operation ManagedClusters.listMeshRevisionProfiles + - Added operation ManagedClusters.listMeshUpgradeProfiles + - Added Interface CompatibleVersions + - Added Interface IstioCertificateAuthority + - Added Interface IstioComponents + - Added Interface IstioEgressGateway + - Added Interface IstioIngressGateway + - Added Interface IstioPluginCertificateAuthority + - Added Interface IstioServiceMesh + - Added Interface ManagedClustersGetMeshRevisionProfileOptionalParams + - Added Interface ManagedClustersGetMeshUpgradeProfileOptionalParams + - Added Interface ManagedClustersListMeshRevisionProfilesNextOptionalParams + - Added Interface ManagedClustersListMeshRevisionProfilesOptionalParams + - Added Interface ManagedClustersListMeshUpgradeProfilesNextOptionalParams + - Added Interface ManagedClustersListMeshUpgradeProfilesOptionalParams + - Added Interface MeshRevision + - Added Interface MeshRevisionProfile + - Added Interface MeshRevisionProfileList + - Added Interface MeshRevisionProfileProperties + - Added Interface MeshUpgradeProfile + - Added Interface MeshUpgradeProfileList + - Added Interface MeshUpgradeProfileProperties + - Added Interface ProxyResource + - Added Interface ServiceMeshProfile + - Added Type Alias IstioIngressGatewayMode + - Added Type Alias ManagedClustersGetMeshRevisionProfileResponse + - Added Type Alias ManagedClustersGetMeshUpgradeProfileResponse + - Added Type Alias ManagedClustersListMeshRevisionProfilesNextResponse + - Added Type Alias ManagedClustersListMeshRevisionProfilesResponse + - Added Type Alias ManagedClustersListMeshUpgradeProfilesNextResponse + - Added Type Alias ManagedClustersListMeshUpgradeProfilesResponse + - Added Type Alias ServiceMeshMode + - Interface ManagedCluster has a new optional parameter resourceUID + - Interface ManagedCluster has a new optional parameter serviceMeshProfile + - Added Enum KnownIstioIngressGatewayMode + - Added Enum KnownServiceMeshMode + + ## 19.3.0 (2023-08-21) **Features** diff --git a/sdk/containerservice/arm-containerservice/_meta.json b/sdk/containerservice/arm-containerservice/_meta.json index b8367cc7d200..1a3b8275243e 100644 --- a/sdk/containerservice/arm-containerservice/_meta.json +++ b/sdk/containerservice/arm-containerservice/_meta.json @@ -1,8 +1,8 @@ { - "commit": "5bcbf0ec9a42be239bf89f3f8c4586dc2dc68d0c", + "commit": "76508fd7da79f583b17f7875c6d9c90718237593", "readme": "specification/containerservice/resource-manager/Microsoft.ContainerService/aks/readme.md", - "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\containerservice\\resource-manager\\Microsoft.ContainerService\\aks\\readme.md --use=@autorest/typescript@6.0.8 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/containerservice/resource-manager/Microsoft.ContainerService/aks/readme.md --use=@autorest/typescript@^6.0.4", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.0", - "use": "@autorest/typescript@6.0.8" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.2", + "use": "@autorest/typescript@^6.0.4" } \ No newline at end of file diff --git a/sdk/containerservice/arm-containerservice/package.json b/sdk/containerservice/arm-containerservice/package.json index dde0c9d0d0f2..ccf80b84a881 100644 --- a/sdk/containerservice/arm-containerservice/package.json +++ b/sdk/containerservice/arm-containerservice/package.json @@ -3,7 +3,7 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ContainerServiceClient.", - "version": "19.3.0", + "version": "19.4.0", "engines": { "node": ">=14.0.0" }, @@ -112,13 +112,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerservice/arm-containerservice", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-containerservice?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerservice/arm-containerservice" +} \ No newline at end of file diff --git a/sdk/containerservice/arm-containerservice/review/arm-containerservice.api.md b/sdk/containerservice/arm-containerservice/review/arm-containerservice.api.md index d6adff191b50..f8036e050376 100644 --- a/sdk/containerservice/arm-containerservice/review/arm-containerservice.api.md +++ b/sdk/containerservice/arm-containerservice/review/arm-containerservice.api.md @@ -244,6 +244,12 @@ export interface ClusterUpgradeSettings { // @public export type Code = string; +// @public +export interface CompatibleVersions { + name?: string; + versions?: string[]; +} + // @public export type ConnectionStatus = string; @@ -392,6 +398,50 @@ export type GPUInstanceProfile = string; // @public export type IpFamily = string; +// @public +export interface IstioCertificateAuthority { + plugin?: IstioPluginCertificateAuthority; +} + +// @public +export interface IstioComponents { + egressGateways?: IstioEgressGateway[]; + ingressGateways?: IstioIngressGateway[]; +} + +// @public +export interface IstioEgressGateway { + enabled: boolean; + nodeSelector?: { + [propertyName: string]: string; + }; +} + +// @public +export interface IstioIngressGateway { + enabled: boolean; + mode: IstioIngressGatewayMode; +} + +// @public +export type IstioIngressGatewayMode = string; + +// @public +export interface IstioPluginCertificateAuthority { + certChainObjectName?: string; + certObjectName?: string; + keyObjectName?: string; + keyVaultId?: string; + rootCertObjectName?: string; +} + +// @public +export interface IstioServiceMesh { + certificateAuthority?: IstioCertificateAuthority; + components?: IstioComponents; + revisions?: string[]; +} + // @public export type KeyVaultNetworkAccessTypes = string; @@ -463,6 +513,12 @@ export enum KnownIpFamily { IPv6 = "IPv6" } +// @public +export enum KnownIstioIngressGatewayMode { + External = "External", + Internal = "Internal" +} + // @public export enum KnownKeyVaultNetworkAccessTypes { Private = "Private", @@ -615,6 +671,12 @@ export enum KnownScaleSetPriority { Spot = "Spot" } +// @public +export enum KnownServiceMeshMode { + Disabled = "Disabled", + Istio = "Istio" +} + // @public export enum KnownSnapshotType { NodePool = "NodePool" @@ -818,7 +880,9 @@ export interface ManagedCluster extends TrackedResource { privateLinkResources?: PrivateLinkResource[]; readonly provisioningState?: string; publicNetworkAccess?: PublicNetworkAccess; + readonly resourceUID?: string; securityProfile?: ManagedClusterSecurityProfile; + serviceMeshProfile?: ServiceMeshProfile; servicePrincipalProfile?: ManagedClusterServicePrincipalProfile; sku?: ManagedClusterSKU; storageProfile?: ManagedClusterStorageProfile; @@ -1125,6 +1189,8 @@ export interface ManagedClusters { get(resourceGroupName: string, resourceName: string, options?: ManagedClustersGetOptionalParams): Promise; getAccessProfile(resourceGroupName: string, resourceName: string, roleName: string, options?: ManagedClustersGetAccessProfileOptionalParams): Promise; getCommandResult(resourceGroupName: string, resourceName: string, commandId: string, options?: ManagedClustersGetCommandResultOptionalParams): Promise; + getMeshRevisionProfile(location: string, mode: string, options?: ManagedClustersGetMeshRevisionProfileOptionalParams): Promise; + getMeshUpgradeProfile(resourceGroupName: string, resourceName: string, mode: string, options?: ManagedClustersGetMeshUpgradeProfileOptionalParams): Promise; getOSOptions(location: string, options?: ManagedClustersGetOSOptionsOptionalParams): Promise; getUpgradeProfile(resourceGroupName: string, resourceName: string, options?: ManagedClustersGetUpgradeProfileOptionalParams): Promise; list(options?: ManagedClustersListOptionalParams): PagedAsyncIterableIterator; @@ -1133,6 +1199,8 @@ export interface ManagedClusters { listClusterMonitoringUserCredentials(resourceGroupName: string, resourceName: string, options?: ManagedClustersListClusterMonitoringUserCredentialsOptionalParams): Promise; listClusterUserCredentials(resourceGroupName: string, resourceName: string, options?: ManagedClustersListClusterUserCredentialsOptionalParams): Promise; listKubernetesVersions(location: string, options?: ManagedClustersListKubernetesVersionsOptionalParams): Promise; + listMeshRevisionProfiles(location: string, options?: ManagedClustersListMeshRevisionProfilesOptionalParams): PagedAsyncIterableIterator; + listMeshUpgradeProfiles(resourceGroupName: string, resourceName: string, options?: ManagedClustersListMeshUpgradeProfilesOptionalParams): PagedAsyncIterableIterator; listOutboundNetworkDependenciesEndpoints(resourceGroupName: string, resourceName: string, options?: ManagedClustersListOutboundNetworkDependenciesEndpointsOptionalParams): PagedAsyncIterableIterator; } @@ -1229,6 +1297,20 @@ export interface ManagedClustersGetCommandResultOptionalParams extends coreClien // @public export type ManagedClustersGetCommandResultResponse = RunCommandResult; +// @public +export interface ManagedClustersGetMeshRevisionProfileOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersGetMeshRevisionProfileResponse = MeshRevisionProfile; + +// @public +export interface ManagedClustersGetMeshUpgradeProfileOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersGetMeshUpgradeProfileResponse = MeshUpgradeProfile; + // @public export interface ManagedClustersGetOptionalParams extends coreClient.OperationOptions { } @@ -1309,6 +1391,34 @@ export interface ManagedClustersListKubernetesVersionsOptionalParams extends cor // @public export type ManagedClustersListKubernetesVersionsResponse = KubernetesVersionListResult; +// @public +export interface ManagedClustersListMeshRevisionProfilesNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersListMeshRevisionProfilesNextResponse = MeshRevisionProfileList; + +// @public +export interface ManagedClustersListMeshRevisionProfilesOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersListMeshRevisionProfilesResponse = MeshRevisionProfileList; + +// @public +export interface ManagedClustersListMeshUpgradeProfilesNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersListMeshUpgradeProfilesNextResponse = MeshUpgradeProfileList; + +// @public +export interface ManagedClustersListMeshUpgradeProfilesOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type ManagedClustersListMeshUpgradeProfilesResponse = MeshUpgradeProfileList; + // @public export interface ManagedClustersListNextOptionalParams extends coreClient.OperationOptions { } @@ -1507,6 +1617,45 @@ export interface ManagedServiceIdentityUserAssignedIdentitiesValue { readonly principalId?: string; } +// @public +export interface MeshRevision { + compatibleWith?: CompatibleVersions[]; + revision?: string; + upgrades?: string[]; +} + +// @public +export interface MeshRevisionProfile extends ProxyResource { + properties?: MeshRevisionProfileProperties; +} + +// @public +export interface MeshRevisionProfileList { + readonly nextLink?: string; + value?: MeshRevisionProfile[]; +} + +// @public +export interface MeshRevisionProfileProperties { + // (undocumented) + meshRevisions?: MeshRevision[]; +} + +// @public +export interface MeshUpgradeProfile extends ProxyResource { + properties?: MeshUpgradeProfileProperties; +} + +// @public +export interface MeshUpgradeProfileList { + readonly nextLink?: string; + value?: MeshUpgradeProfile[]; +} + +// @public +export interface MeshUpgradeProfileProperties extends MeshRevision { +} + // @public export type NetworkDataplane = string; @@ -1687,6 +1836,10 @@ export interface PrivateLinkServiceConnectionState { status?: ConnectionStatus; } +// @public +export interface ProxyResource extends Resource { +} + // @public export type PublicNetworkAccess = string; @@ -1760,6 +1913,15 @@ export interface Schedule { weekly?: WeeklySchedule; } +// @public +export type ServiceMeshMode = string; + +// @public +export interface ServiceMeshProfile { + istio?: IstioServiceMesh; + mode: ServiceMeshMode; +} + // @public export interface Snapshot extends TrackedResource { creationData?: CreationData; diff --git a/sdk/containerservice/arm-containerservice/src/containerServiceClient.ts b/sdk/containerservice/arm-containerservice/src/containerServiceClient.ts index ca5491b72ec2..d20685aa4259 100644 --- a/sdk/containerservice/arm-containerservice/src/containerServiceClient.ts +++ b/sdk/containerservice/arm-containerservice/src/containerServiceClient.ts @@ -68,7 +68,7 @@ export class ContainerServiceClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-containerservice/19.3.0`; + const packageDetails = `azsdk-js-arm-containerservice/19.4.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -121,7 +121,7 @@ export class ContainerServiceClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2023-07-01"; + this.apiVersion = options.apiVersion || "2023-08-01"; this.operations = new OperationsImpl(this); this.managedClusters = new ManagedClustersImpl(this); this.maintenanceConfigurations = new MaintenanceConfigurationsImpl(this); diff --git a/sdk/containerservice/arm-containerservice/src/models/index.ts b/sdk/containerservice/arm-containerservice/src/models/index.ts index 8d79b8cf21d1..03010fa39ddf 100644 --- a/sdk/containerservice/arm-containerservice/src/models/index.ts +++ b/sdk/containerservice/arm-containerservice/src/models/index.ts @@ -911,6 +911,68 @@ export interface ManagedClusterAzureMonitorProfileKubeStateMetrics { metricAnnotationsAllowList?: string; } +/** Service mesh profile for a managed cluster. */ +export interface ServiceMeshProfile { + /** Mode of the service mesh. */ + mode: ServiceMeshMode; + /** Istio service mesh configuration. */ + istio?: IstioServiceMesh; +} + +/** Istio service mesh configuration. */ +export interface IstioServiceMesh { + /** Istio components configuration. */ + components?: IstioComponents; + /** Istio Service Mesh Certificate Authority (CA) configuration. For now, we only support plugin certificates as described here https://aka.ms/asm-plugin-ca */ + certificateAuthority?: IstioCertificateAuthority; + /** The list of revisions of the Istio control plane. When an upgrade is not in progress, this holds one value. When canary upgrade is in progress, this can only hold two consecutive values. For more information, see: https://learn.microsoft.com/en-us/azure/aks/istio-upgrade */ + revisions?: string[]; +} + +/** Istio components configuration. */ +export interface IstioComponents { + /** Istio ingress gateways. */ + ingressGateways?: IstioIngressGateway[]; + /** Istio egress gateways. */ + egressGateways?: IstioEgressGateway[]; +} + +/** Istio ingress gateway configuration. For now, we support up to one external ingress gateway named `aks-istio-ingressgateway-external` and one internal ingress gateway named `aks-istio-ingressgateway-internal`. */ +export interface IstioIngressGateway { + /** Mode of an ingress gateway. */ + mode: IstioIngressGatewayMode; + /** Whether to enable the ingress gateway. */ + enabled: boolean; +} + +/** Istio egress gateway configuration. */ +export interface IstioEgressGateway { + /** Whether to enable the egress gateway. */ + enabled: boolean; + /** NodeSelector for scheduling the egress gateway. */ + nodeSelector?: { [propertyName: string]: string }; +} + +/** Istio Service Mesh Certificate Authority (CA) configuration. For now, we only support plugin certificates as described here https://aka.ms/asm-plugin-ca */ +export interface IstioCertificateAuthority { + /** Plugin certificates information for Service Mesh. */ + plugin?: IstioPluginCertificateAuthority; +} + +/** Plugin certificates information for Service Mesh. */ +export interface IstioPluginCertificateAuthority { + /** The resource ID of the Key Vault. */ + keyVaultId?: string; + /** Intermediate certificate object name in Azure Key Vault. */ + certObjectName?: string; + /** Intermediate certificate private key object name in Azure Key Vault. */ + keyObjectName?: string; + /** Root certificate object name in Azure Key Vault. */ + rootCertObjectName?: string; + /** Certificate chain object name in Azure Key Vault. */ + certChainObjectName?: string; +} + /** Common fields that are returned in the response for all Azure Resource Manager resources */ export interface Resource { /** @@ -1364,6 +1426,51 @@ export interface SnapshotListResult { readonly nextLink?: string; } +/** Holds an array of MeshRevisionsProfiles */ +export interface MeshRevisionProfileList { + /** Array of service mesh add-on revision profiles for all supported mesh modes. */ + value?: MeshRevisionProfile[]; + /** + * The URL to get the next set of mesh revision profile. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Mesh revision profile properties for a mesh */ +export interface MeshRevisionProfileProperties { + meshRevisions?: MeshRevision[]; +} + +/** Holds information on upgrades and compatibility for given major.minor mesh release. */ +export interface MeshRevision { + /** The revision of the mesh release. */ + revision?: string; + /** List of revisions available for upgrade of a specific mesh revision */ + upgrades?: string[]; + /** List of items this revision of service mesh is compatible with, and their associated versions. */ + compatibleWith?: CompatibleVersions[]; +} + +/** Version information about a product/service that is compatible with a service mesh revision. */ +export interface CompatibleVersions { + /** The product/service name. */ + name?: string; + /** Product/service versions compatible with a service mesh add-on revision. */ + versions?: string[]; +} + +/** Holds an array of MeshUpgradeProfiles */ +export interface MeshUpgradeProfileList { + /** Array of supported service mesh add-on upgrade profiles. */ + value?: MeshUpgradeProfile[]; + /** + * The URL to get the next set of mesh upgrade profile. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + /** Profile for the container service agent pool. */ export interface ManagedClusterAgentPoolProfile extends ManagedClusterAgentPoolProfileProperties { @@ -1383,6 +1490,9 @@ export interface TrackedResource extends Resource { location: string; } +/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ +export interface ProxyResource extends Resource {} + /** See [planned maintenance](https://docs.microsoft.com/azure/aks/planned-maintenance) for more information about planned maintenance. */ export interface MaintenanceConfiguration extends SubResource { /** @@ -1493,6 +1603,9 @@ export interface AgentPool extends SubResource { hostGroupID?: string; } +/** Mesh upgrade profile properties for a major.minor release. */ +export interface MeshUpgradeProfileProperties extends MeshRevision {} + /** Managed cluster. */ export interface ManagedCluster extends TrackedResource { /** The managed cluster SKU. */ @@ -1596,6 +1709,13 @@ export interface ManagedCluster extends TrackedResource { workloadAutoScalerProfile?: ManagedClusterWorkloadAutoScalerProfile; /** Azure Monitor addon profiles for monitoring the managed cluster. */ azureMonitorProfile?: ManagedClusterAzureMonitorProfile; + /** Service mesh profile for a managed cluster. */ + serviceMeshProfile?: ServiceMeshProfile; + /** + * The resourceUID uniquely identifies ManagedClusters that reuse ARM ResourceIds (i.e: create, delete, create sequence) + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly resourceUID?: string; } /** Managed cluster Access Profile. */ @@ -1642,6 +1762,18 @@ export interface Snapshot extends TrackedResource { readonly enableFips?: boolean; } +/** Mesh revision profile for a mesh. */ +export interface MeshRevisionProfile extends ProxyResource { + /** Mesh revision profile properties for a mesh */ + properties?: MeshRevisionProfileProperties; +} + +/** Upgrade profile for given mesh. */ +export interface MeshUpgradeProfile extends ProxyResource { + /** Mesh upgrade profile properties for a major.minor release. */ + properties?: MeshUpgradeProfileProperties; +} + /** Defines headers for ManagedClusters_delete operation. */ export interface ManagedClustersDeleteHeaders { /** URL to query for status of the operation. */ @@ -2335,6 +2467,42 @@ export enum KnownPublicNetworkAccess { */ export type PublicNetworkAccess = string; +/** Known values of {@link ServiceMeshMode} that the service accepts. */ +export enum KnownServiceMeshMode { + /** Istio deployed as an AKS addon. */ + Istio = "Istio", + /** Mesh is disabled. */ + Disabled = "Disabled" +} + +/** + * Defines values for ServiceMeshMode. \ + * {@link KnownServiceMeshMode} can be used interchangeably with ServiceMeshMode, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Istio**: Istio deployed as an AKS addon. \ + * **Disabled**: Mesh is disabled. + */ +export type ServiceMeshMode = string; + +/** Known values of {@link IstioIngressGatewayMode} that the service accepts. */ +export enum KnownIstioIngressGatewayMode { + /** The ingress gateway is assigned a public IP address and is publicly accessible. */ + External = "External", + /** The ingress gateway is assigned an internal IP address and cannot is accessed publicly. */ + Internal = "Internal" +} + +/** + * Defines values for IstioIngressGatewayMode. \ + * {@link KnownIstioIngressGatewayMode} can be used interchangeably with IstioIngressGatewayMode, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **External**: The ingress gateway is assigned a public IP address and is publicly accessible. \ + * **Internal**: The ingress gateway is assigned an internal IP address and cannot is accessed publicly. + */ +export type IstioIngressGatewayMode = string; + /** Known values of {@link CreatedByType} that the service accepts. */ export enum KnownCreatedByType { /** User */ @@ -2736,6 +2904,34 @@ export interface ManagedClustersListOutboundNetworkDependenciesEndpointsOptional /** Contains response data for the listOutboundNetworkDependenciesEndpoints operation. */ export type ManagedClustersListOutboundNetworkDependenciesEndpointsResponse = OutboundEnvironmentEndpointCollection; +/** Optional parameters. */ +export interface ManagedClustersListMeshRevisionProfilesOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listMeshRevisionProfiles operation. */ +export type ManagedClustersListMeshRevisionProfilesResponse = MeshRevisionProfileList; + +/** Optional parameters. */ +export interface ManagedClustersGetMeshRevisionProfileOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getMeshRevisionProfile operation. */ +export type ManagedClustersGetMeshRevisionProfileResponse = MeshRevisionProfile; + +/** Optional parameters. */ +export interface ManagedClustersListMeshUpgradeProfilesOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listMeshUpgradeProfiles operation. */ +export type ManagedClustersListMeshUpgradeProfilesResponse = MeshUpgradeProfileList; + +/** Optional parameters. */ +export interface ManagedClustersGetMeshUpgradeProfileOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the getMeshUpgradeProfile operation. */ +export type ManagedClustersGetMeshUpgradeProfileResponse = MeshUpgradeProfile; + /** Optional parameters. */ export interface ManagedClustersListNextOptionalParams extends coreClient.OperationOptions {} @@ -2757,6 +2953,20 @@ export interface ManagedClustersListOutboundNetworkDependenciesEndpointsNextOpti /** Contains response data for the listOutboundNetworkDependenciesEndpointsNext operation. */ export type ManagedClustersListOutboundNetworkDependenciesEndpointsNextResponse = OutboundEnvironmentEndpointCollection; +/** Optional parameters. */ +export interface ManagedClustersListMeshRevisionProfilesNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listMeshRevisionProfilesNext operation. */ +export type ManagedClustersListMeshRevisionProfilesNextResponse = MeshRevisionProfileList; + +/** Optional parameters. */ +export interface ManagedClustersListMeshUpgradeProfilesNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listMeshUpgradeProfilesNext operation. */ +export type ManagedClustersListMeshUpgradeProfilesNextResponse = MeshUpgradeProfileList; + /** Optional parameters. */ export interface MaintenanceConfigurationsListByManagedClusterOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/containerservice/arm-containerservice/src/models/mappers.ts b/sdk/containerservice/arm-containerservice/src/models/mappers.ts index 6764d5061399..1b675866c9e4 100644 --- a/sdk/containerservice/arm-containerservice/src/models/mappers.ts +++ b/sdk/containerservice/arm-containerservice/src/models/mappers.ts @@ -2618,6 +2618,201 @@ export const ManagedClusterAzureMonitorProfileKubeStateMetrics: coreClient.Compo } }; +export const ServiceMeshProfile: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ServiceMeshProfile", + modelProperties: { + mode: { + serializedName: "mode", + required: true, + type: { + name: "String" + } + }, + istio: { + serializedName: "istio", + type: { + name: "Composite", + className: "IstioServiceMesh" + } + } + } + } +}; + +export const IstioServiceMesh: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioServiceMesh", + modelProperties: { + components: { + serializedName: "components", + type: { + name: "Composite", + className: "IstioComponents" + } + }, + certificateAuthority: { + serializedName: "certificateAuthority", + type: { + name: "Composite", + className: "IstioCertificateAuthority" + } + }, + revisions: { + constraints: { + MaxItems: 2, + UniqueItems: true + }, + serializedName: "revisions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const IstioComponents: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioComponents", + modelProperties: { + ingressGateways: { + serializedName: "ingressGateways", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IstioIngressGateway" + } + } + } + }, + egressGateways: { + serializedName: "egressGateways", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IstioEgressGateway" + } + } + } + } + } + } +}; + +export const IstioIngressGateway: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioIngressGateway", + modelProperties: { + mode: { + serializedName: "mode", + required: true, + type: { + name: "String" + } + }, + enabled: { + serializedName: "enabled", + required: true, + type: { + name: "Boolean" + } + } + } + } +}; + +export const IstioEgressGateway: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioEgressGateway", + modelProperties: { + enabled: { + serializedName: "enabled", + required: true, + type: { + name: "Boolean" + } + }, + nodeSelector: { + serializedName: "nodeSelector", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + } + } + } +}; + +export const IstioCertificateAuthority: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioCertificateAuthority", + modelProperties: { + plugin: { + serializedName: "plugin", + type: { + name: "Composite", + className: "IstioPluginCertificateAuthority" + } + } + } + } +}; + +export const IstioPluginCertificateAuthority: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IstioPluginCertificateAuthority", + modelProperties: { + keyVaultId: { + serializedName: "keyVaultId", + type: { + name: "String" + } + }, + certObjectName: { + serializedName: "certObjectName", + type: { + name: "String" + } + }, + keyObjectName: { + serializedName: "keyObjectName", + type: { + name: "String" + } + }, + rootCertObjectName: { + serializedName: "rootCertObjectName", + type: { + name: "String" + } + }, + certChainObjectName: { + serializedName: "certChainObjectName", + type: { + name: "String" + } + } + } + } +}; + export const Resource: coreClient.CompositeMapper = { type: { name: "Composite", @@ -3761,6 +3956,147 @@ export const SnapshotListResult: coreClient.CompositeMapper = { } }; +export const MeshRevisionProfileList: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshRevisionProfileList", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MeshRevisionProfile" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + +export const MeshRevisionProfileProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshRevisionProfileProperties", + modelProperties: { + meshRevisions: { + serializedName: "meshRevisions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MeshRevision" + } + } + } + } + } + } +}; + +export const MeshRevision: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshRevision", + modelProperties: { + revision: { + serializedName: "revision", + type: { + name: "String" + } + }, + upgrades: { + serializedName: "upgrades", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + compatibleWith: { + serializedName: "compatibleWith", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "CompatibleVersions" + } + } + } + } + } + } +}; + +export const CompatibleVersions: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "CompatibleVersions", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + versions: { + serializedName: "versions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const MeshUpgradeProfileList: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshUpgradeProfileList", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MeshUpgradeProfile" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + export const ManagedClusterAgentPoolProfile: coreClient.CompositeMapper = { type: { name: "Composite", @@ -3815,6 +4151,16 @@ export const TrackedResource: coreClient.CompositeMapper = { } }; +export const ProxyResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ProxyResource", + modelProperties: { + ...Resource.type.modelProperties + } + } +}; + export const MaintenanceConfiguration: coreClient.CompositeMapper = { type: { name: "Composite", @@ -4147,6 +4493,16 @@ export const AgentPool: coreClient.CompositeMapper = { } }; +export const MeshUpgradeProfileProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshUpgradeProfileProperties", + modelProperties: { + ...MeshRevision.type.modelProperties + } + } +}; + export const ManagedCluster: coreClient.CompositeMapper = { type: { name: "Composite", @@ -4436,6 +4792,20 @@ export const ManagedCluster: coreClient.CompositeMapper = { name: "Composite", className: "ManagedClusterAzureMonitorProfile" } + }, + serviceMeshProfile: { + serializedName: "properties.serviceMeshProfile", + type: { + name: "Composite", + className: "ServiceMeshProfile" + } + }, + resourceUID: { + serializedName: "properties.resourceUID", + readOnly: true, + type: { + name: "String" + } } } } @@ -4524,6 +4894,40 @@ export const Snapshot: coreClient.CompositeMapper = { } }; +export const MeshRevisionProfile: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshRevisionProfile", + modelProperties: { + ...ProxyResource.type.modelProperties, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "MeshRevisionProfileProperties" + } + } + } + } +}; + +export const MeshUpgradeProfile: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MeshUpgradeProfile", + modelProperties: { + ...ProxyResource.type.modelProperties, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "MeshUpgradeProfileProperties" + } + } + } + } +}; + export const ManagedClustersDeleteHeaders: coreClient.CompositeMapper = { type: { name: "Composite", diff --git a/sdk/containerservice/arm-containerservice/src/models/parameters.ts b/sdk/containerservice/arm-containerservice/src/models/parameters.ts index 1454ac7a0824..172a28f14085 100644 --- a/sdk/containerservice/arm-containerservice/src/models/parameters.ts +++ b/sdk/containerservice/arm-containerservice/src/models/parameters.ts @@ -51,7 +51,7 @@ export const $host: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2023-07-01", + defaultValue: "2023-08-01", isConstant: true, serializedName: "api-version", type: { @@ -210,6 +210,24 @@ export const commandId: OperationURLParameter = { } }; +export const mode: OperationURLParameter = { + parameterPath: "mode", + mapper: { + constraints: { + Pattern: new RegExp( + "^[a-zA-Z0-9]$|^[a-zA-Z0-9][-_a-zA-Z0-9]{0,61}[a-zA-Z0-9]$" + ), + MaxLength: 24, + MinLength: 1 + }, + serializedName: "mode", + required: true, + type: { + name: "String" + } + } +}; + export const nextLink: OperationURLParameter = { parameterPath: "nextLink", mapper: { diff --git a/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts b/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts index c36e830011c9..fd44c23e28d5 100644 --- a/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts +++ b/sdk/containerservice/arm-containerservice/src/operations/managedClusters.ts @@ -31,6 +31,14 @@ import { ManagedClustersListOutboundNetworkDependenciesEndpointsNextOptionalParams, ManagedClustersListOutboundNetworkDependenciesEndpointsOptionalParams, ManagedClustersListOutboundNetworkDependenciesEndpointsResponse, + MeshRevisionProfile, + ManagedClustersListMeshRevisionProfilesNextOptionalParams, + ManagedClustersListMeshRevisionProfilesOptionalParams, + ManagedClustersListMeshRevisionProfilesResponse, + MeshUpgradeProfile, + ManagedClustersListMeshUpgradeProfilesNextOptionalParams, + ManagedClustersListMeshUpgradeProfilesOptionalParams, + ManagedClustersListMeshUpgradeProfilesResponse, ManagedClustersGetOSOptionsOptionalParams, ManagedClustersGetOSOptionsResponse, ManagedClustersListKubernetesVersionsOptionalParams, @@ -73,9 +81,15 @@ import { ManagedClustersRunCommandResponse, ManagedClustersGetCommandResultOptionalParams, ManagedClustersGetCommandResultResponse, + ManagedClustersGetMeshRevisionProfileOptionalParams, + ManagedClustersGetMeshRevisionProfileResponse, + ManagedClustersGetMeshUpgradeProfileOptionalParams, + ManagedClustersGetMeshUpgradeProfileResponse, ManagedClustersListNextResponse, ManagedClustersListByResourceGroupNextResponse, - ManagedClustersListOutboundNetworkDependenciesEndpointsNextResponse + ManagedClustersListOutboundNetworkDependenciesEndpointsNextResponse, + ManagedClustersListMeshRevisionProfilesNextResponse, + ManagedClustersListMeshUpgradeProfilesNextResponse } from "../models"; /// @@ -299,6 +313,160 @@ export class ManagedClustersImpl implements ManagedClusters { } } + /** + * Contains extra metadata on each revision, including supported revisions, cluster compatibility and + * available upgrades + * @param location The name of Azure region. + * @param options The options parameters. + */ + public listMeshRevisionProfiles( + location: string, + options?: ManagedClustersListMeshRevisionProfilesOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listMeshRevisionProfilesPagingAll(location, options); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listMeshRevisionProfilesPagingPage( + location, + options, + settings + ); + } + }; + } + + private async *listMeshRevisionProfilesPagingPage( + location: string, + options?: ManagedClustersListMeshRevisionProfilesOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: ManagedClustersListMeshRevisionProfilesResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listMeshRevisionProfiles(location, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listMeshRevisionProfilesNext( + location, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listMeshRevisionProfilesPagingAll( + location: string, + options?: ManagedClustersListMeshRevisionProfilesOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listMeshRevisionProfilesPagingPage( + location, + options + )) { + yield* page; + } + } + + /** + * Lists available upgrades for all service meshes in a specific cluster. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param options The options parameters. + */ + public listMeshUpgradeProfiles( + resourceGroupName: string, + resourceName: string, + options?: ManagedClustersListMeshUpgradeProfilesOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listMeshUpgradeProfilesPagingAll( + resourceGroupName, + resourceName, + options + ); + return { + next() { + return iter.next(); + }, + [Symbol.asyncIterator]() { + return this; + }, + byPage: (settings?: PageSettings) => { + if (settings?.maxPageSize) { + throw new Error("maxPageSize is not supported by this operation."); + } + return this.listMeshUpgradeProfilesPagingPage( + resourceGroupName, + resourceName, + options, + settings + ); + } + }; + } + + private async *listMeshUpgradeProfilesPagingPage( + resourceGroupName: string, + resourceName: string, + options?: ManagedClustersListMeshUpgradeProfilesOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: ManagedClustersListMeshUpgradeProfilesResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._listMeshUpgradeProfiles( + resourceGroupName, + resourceName, + options + ); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listMeshUpgradeProfilesNext( + resourceGroupName, + resourceName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listMeshUpgradeProfilesPagingAll( + resourceGroupName: string, + resourceName: string, + options?: ManagedClustersListMeshUpgradeProfilesOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listMeshUpgradeProfilesPagingPage( + resourceGroupName, + resourceName, + options + )) { + yield* page; + } + } + /** * Gets supported OS options in the specified subscription. * @param location The name of Azure region. @@ -1529,6 +1697,76 @@ export class ManagedClustersImpl implements ManagedClusters { ); } + /** + * Contains extra metadata on each revision, including supported revisions, cluster compatibility and + * available upgrades + * @param location The name of Azure region. + * @param options The options parameters. + */ + private _listMeshRevisionProfiles( + location: string, + options?: ManagedClustersListMeshRevisionProfilesOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { location, options }, + listMeshRevisionProfilesOperationSpec + ); + } + + /** + * Contains extra metadata on the revision, including supported revisions, cluster compatibility and + * available upgrades + * @param location The name of Azure region. + * @param mode The mode of the mesh. + * @param options The options parameters. + */ + getMeshRevisionProfile( + location: string, + mode: string, + options?: ManagedClustersGetMeshRevisionProfileOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { location, mode, options }, + getMeshRevisionProfileOperationSpec + ); + } + + /** + * Lists available upgrades for all service meshes in a specific cluster. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param options The options parameters. + */ + private _listMeshUpgradeProfiles( + resourceGroupName: string, + resourceName: string, + options?: ManagedClustersListMeshUpgradeProfilesOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, options }, + listMeshUpgradeProfilesOperationSpec + ); + } + + /** + * Gets available upgrades for a service mesh in a cluster. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param mode The mode of the mesh. + * @param options The options parameters. + */ + getMeshUpgradeProfile( + resourceGroupName: string, + resourceName: string, + mode: string, + options?: ManagedClustersGetMeshUpgradeProfileOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, mode, options }, + getMeshUpgradeProfileOperationSpec + ); + } + /** * ListNext * @param nextLink The nextLink from the previous successful call to the List method. @@ -1582,6 +1820,44 @@ export class ManagedClustersImpl implements ManagedClusters { listOutboundNetworkDependenciesEndpointsNextOperationSpec ); } + + /** + * ListMeshRevisionProfilesNext + * @param location The name of Azure region. + * @param nextLink The nextLink from the previous successful call to the ListMeshRevisionProfiles + * method. + * @param options The options parameters. + */ + private _listMeshRevisionProfilesNext( + location: string, + nextLink: string, + options?: ManagedClustersListMeshRevisionProfilesNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { location, nextLink, options }, + listMeshRevisionProfilesNextOperationSpec + ); + } + + /** + * ListMeshUpgradeProfilesNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param nextLink The nextLink from the previous successful call to the ListMeshUpgradeProfiles + * method. + * @param options The options parameters. + */ + private _listMeshUpgradeProfilesNext( + resourceGroupName: string, + resourceName: string, + nextLink: string, + options?: ManagedClustersListMeshUpgradeProfilesNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, nextLink, options }, + listMeshUpgradeProfilesNextOperationSpec + ); + } } // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); @@ -2190,6 +2466,94 @@ const listOutboundNetworkDependenciesEndpointsOperationSpec: coreClient.Operatio headerParameters: [Parameters.accept], serializer }; +const listMeshRevisionProfilesOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerService/locations/{location}/meshRevisionProfiles", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshRevisionProfileList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.location + ], + headerParameters: [Parameters.accept], + serializer +}; +const getMeshRevisionProfileOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerService/locations/{location}/meshRevisionProfiles/{mode}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshRevisionProfile + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.location, + Parameters.mode + ], + headerParameters: [Parameters.accept], + serializer +}; +const listMeshUpgradeProfilesOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/meshUpgradeProfiles", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshUpgradeProfileList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getMeshUpgradeProfileOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/managedClusters/{resourceName}/meshUpgradeProfiles/{mode}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshUpgradeProfile + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.mode + ], + headerParameters: [Parameters.accept], + serializer +}; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", @@ -2250,3 +2614,44 @@ const listOutboundNetworkDependenciesEndpointsNextOperationSpec: coreClient.Oper headerParameters: [Parameters.accept], serializer }; +const listMeshRevisionProfilesNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshRevisionProfileList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.location, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; +const listMeshUpgradeProfilesNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.MeshUpgradeProfileList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.nextLink + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/containerservice/arm-containerservice/src/operationsInterfaces/managedClusters.ts b/sdk/containerservice/arm-containerservice/src/operationsInterfaces/managedClusters.ts index f051e5544730..3422935154e2 100644 --- a/sdk/containerservice/arm-containerservice/src/operationsInterfaces/managedClusters.ts +++ b/sdk/containerservice/arm-containerservice/src/operationsInterfaces/managedClusters.ts @@ -14,6 +14,10 @@ import { ManagedClustersListByResourceGroupOptionalParams, OutboundEnvironmentEndpoint, ManagedClustersListOutboundNetworkDependenciesEndpointsOptionalParams, + MeshRevisionProfile, + ManagedClustersListMeshRevisionProfilesOptionalParams, + MeshUpgradeProfile, + ManagedClustersListMeshUpgradeProfilesOptionalParams, ManagedClustersGetOSOptionsOptionalParams, ManagedClustersGetOSOptionsResponse, ManagedClustersListKubernetesVersionsOptionalParams, @@ -55,7 +59,11 @@ import { ManagedClustersRunCommandOptionalParams, ManagedClustersRunCommandResponse, ManagedClustersGetCommandResultOptionalParams, - ManagedClustersGetCommandResultResponse + ManagedClustersGetCommandResultResponse, + ManagedClustersGetMeshRevisionProfileOptionalParams, + ManagedClustersGetMeshRevisionProfileResponse, + ManagedClustersGetMeshUpgradeProfileOptionalParams, + ManagedClustersGetMeshUpgradeProfileResponse } from "../models"; /// @@ -89,6 +97,27 @@ export interface ManagedClusters { resourceName: string, options?: ManagedClustersListOutboundNetworkDependenciesEndpointsOptionalParams ): PagedAsyncIterableIterator; + /** + * Contains extra metadata on each revision, including supported revisions, cluster compatibility and + * available upgrades + * @param location The name of Azure region. + * @param options The options parameters. + */ + listMeshRevisionProfiles( + location: string, + options?: ManagedClustersListMeshRevisionProfilesOptionalParams + ): PagedAsyncIterableIterator; + /** + * Lists available upgrades for all service meshes in a specific cluster. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param options The options parameters. + */ + listMeshUpgradeProfiles( + resourceGroupName: string, + resourceName: string, + options?: ManagedClustersListMeshUpgradeProfilesOptionalParams + ): PagedAsyncIterableIterator; /** * Gets supported OS options in the specified subscription. * @param location The name of Azure region. @@ -522,4 +551,29 @@ export interface ManagedClusters { commandId: string, options?: ManagedClustersGetCommandResultOptionalParams ): Promise; + /** + * Contains extra metadata on the revision, including supported revisions, cluster compatibility and + * available upgrades + * @param location The name of Azure region. + * @param mode The mode of the mesh. + * @param options The options parameters. + */ + getMeshRevisionProfile( + location: string, + mode: string, + options?: ManagedClustersGetMeshRevisionProfileOptionalParams + ): Promise; + /** + * Gets available upgrades for a service mesh in a cluster. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the managed cluster resource. + * @param mode The mode of the mesh. + * @param options The options parameters. + */ + getMeshUpgradeProfile( + resourceGroupName: string, + resourceName: string, + mode: string, + options?: ManagedClustersGetMeshUpgradeProfileOptionalParams + ): Promise; } diff --git a/sdk/containerservice/arm-containerservice/test/sampleTest.ts b/sdk/containerservice/arm-containerservice/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/containerservice/arm-containerservice/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id" +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function(this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function() { + await recorder.stop(); + }); + + it("sample test", async function() { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/containerservice/arm-containerservice/tsconfig.json b/sdk/containerservice/arm-containerservice/tsconfig.json index 5bad5556bbfd..3e6ae96443f3 100644 --- a/sdk/containerservice/arm-containerservice/tsconfig.json +++ b/sdk/containerservice/arm-containerservice/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-containerservice": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"