diff --git a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts index 6e107e7e50bf..e36bb5ab9e7c 100644 --- a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts +++ b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts @@ -37,14 +37,14 @@ export class AppPlatformManagementClientContext extends msRestAzure.AzureService if (!options) { options = {}; } - if (!options.userAgent) { + if(!options.userAgent) { const defaultUserAgent = msRestAzure.getDefaultUserAgentValue(); options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`; } super(credentials, options); - this.apiVersion = '2020-11-01-preview'; + this.apiVersion = '2021-03-03-preview'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; @@ -52,10 +52,10 @@ export class AppPlatformManagementClientContext extends msRestAzure.AzureService this.credentials = credentials; this.subscriptionId = subscriptionId; - if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) { + if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) { this.acceptLanguage = options.acceptLanguage; } - if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { + if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout; } } diff --git a/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts index 99e4dea19713..7cb0773a5265 100644 --- a/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts @@ -41,6 +41,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ResourceUploadDefinition, ServiceResource, Sku, diff --git a/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts index 30588e309be2..0aa1b3bbbab0 100644 --- a/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts @@ -39,6 +39,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts b/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts index 74a82eb8d30a..3b740bcec230 100644 --- a/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts @@ -39,6 +39,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts b/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts index a4f7578092d0..18bb69bc5d64 100644 --- a/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts @@ -40,6 +40,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts index 02fcb4f36e3d..8476060c205e 100644 --- a/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts @@ -39,6 +39,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts index 7414c396b7b1..7ea0a455de8a 100644 --- a/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts @@ -40,6 +40,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/index.ts b/sdk/appplatform/arm-appplatform/src/models/index.ts index 221fe440bc9f..aa189052b0b2 100644 --- a/sdk/appplatform/arm-appplatform/src/models/index.ts +++ b/sdk/appplatform/arm-appplatform/src/models/index.ts @@ -120,11 +120,11 @@ export interface ClusterResourceProperties { */ export interface Sku { /** - * Name of the Sku + * Name of the Sku. Default value: 'S0'. */ name?: string; /** - * Tier of the Sku + * Tier of the Sku. Default value: 'Standard'. */ tier?: string; /** @@ -417,7 +417,7 @@ export interface MonitoringSettingProperties { error?: ErrorModel; /** * Indicates whether enable the trace functionality, which will be deprecated since api version - * 2020-11-01-preview. Please leverage appInsightsInstrumentationKey to indicate if + * 2021-03-03-preview. Please leverage appInsightsInstrumentationKey to indicate if * monitoringSettings enabled or not */ traceEnabled?: boolean; @@ -546,10 +546,6 @@ export interface AppResourceProperties { * Indicate if only https is allowed. */ httpsOnly?: boolean; - /** - * Indicate if end to end TLS is enabled. - */ - enableEndToEndTLS?: boolean; /** * Date time when the resource is created * **NOTE: This property will not be serialized. It can only be populated by the server.** @@ -563,6 +559,10 @@ export interface AppResourceProperties { * Persistent disk settings */ persistentDisk?: PersistentDisk; + /** + * Indicate if end to end TLS is enabled. + */ + enableEndToEndTLS?: boolean; } /** @@ -822,20 +822,40 @@ export interface UserSourceInfo { artifactSelector?: string; } +/** + * Deployment resource request payload + */ +export interface ResourceRequest { + /** + * Required CPU, 1c can be represent by 1 or 1000m, basic tier should be 500m or 1, standard tier + * should be 500m or the value in range (1, 4). + */ + cpu?: string; + /** + * Required Memory size, 1GB can be represent by 1Gi or 1024Mi, basic tier should be 500m or the + * value in range (1, 2), standard tier should be 500m or the value in range (1, 8). + */ + memory?: string; +} + /** * Deployment settings payload */ export interface DeploymentSettings { /** - * Required CPU, basic tier should be 1, standard tier should be in range (1, 4). Default value: - * 1. + * Required CPU, basic tier should be 1, standard tier should be in range (1, 4), it will be + * deprecated since api version 2021-03-03-preview. Default value: 1. */ cpu?: number; /** * Required Memory size in GB, basic tier should be in range (1, 2), standard tier should be in - * range (1, 8). Default value: 1. + * range (1, 8), it will be deprecated since api version 2021-03-03-preview. Default value: 1. */ memoryInGB?: number; + /** + * The request of quantity for cpu and memory size. + */ + resourceRequest?: ResourceRequest; /** * JVM parameter */ diff --git a/sdk/appplatform/arm-appplatform/src/models/mappers.ts b/sdk/appplatform/arm-appplatform/src/models/mappers.ts index d5aea74885fa..a80e8adb6c48 100644 --- a/sdk/appplatform/arm-appplatform/src/models/mappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/mappers.ts @@ -196,12 +196,14 @@ export const Sku: msRest.CompositeMapper = { modelProperties: { name: { serializedName: "name", + defaultValue: 'S0', type: { name: "String" } }, tier: { serializedName: "tier", + defaultValue: 'Standard', type: { name: "String" } @@ -910,12 +912,6 @@ export const AppResourceProperties: msRest.CompositeMapper = { name: "Boolean" } }, - enableEndToEndTLS: { - serializedName: "enableEndToEndTLS", - type: { - name: "Boolean" - } - }, createdTime: { readOnly: true, serializedName: "createdTime", @@ -936,6 +932,12 @@ export const AppResourceProperties: msRest.CompositeMapper = { name: "Composite", className: "PersistentDisk" } + }, + enableEndToEndTLS: { + serializedName: "enableEndToEndTLS", + type: { + name: "Boolean" + } } } } @@ -1354,6 +1356,28 @@ export const UserSourceInfo: msRest.CompositeMapper = { } }; +export const ResourceRequest: msRest.CompositeMapper = { + serializedName: "ResourceRequest", + type: { + name: "Composite", + className: "ResourceRequest", + modelProperties: { + cpu: { + serializedName: "cpu", + type: { + name: "String" + } + }, + memory: { + serializedName: "memory", + type: { + name: "String" + } + } + } + } +}; + export const DeploymentSettings: msRest.CompositeMapper = { serializedName: "DeploymentSettings", type: { @@ -1374,6 +1398,13 @@ export const DeploymentSettings: msRest.CompositeMapper = { name: "Number" } }, + resourceRequest: { + serializedName: "resourceRequest", + type: { + name: "Composite", + className: "ResourceRequest" + } + }, jvmOptions: { serializedName: "jvmOptions", type: { diff --git a/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts index 0463b1feac36..58f199ee0a90 100644 --- a/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts @@ -38,6 +38,7 @@ export { ProxyResource, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, Sku, TemporaryDisk, diff --git a/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts b/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts index de115949d99c..1951e38889c1 100644 --- a/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts @@ -41,6 +41,7 @@ export { RegenerateTestKeyRequestPayload, RequiredTraffic, Resource, + ResourceRequest, ServiceResource, ServiceResourceList, Sku,