diff --git a/sdk/appplatform/arm-appplatform/package.json b/sdk/appplatform/arm-appplatform/package.json index 5858db62b3c0..7d88def0ce81 100644 --- a/sdk/appplatform/arm-appplatform/package.json +++ b/sdk/appplatform/arm-appplatform/package.json @@ -27,7 +27,7 @@ "rollup-plugin-sourcemaps": "^0.4.2", "uglify-js": "^3.6.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/feature/v4/sdk/appplatform/arm-appplatform", + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/appplatform/arm-appplatform", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" diff --git a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClient.ts b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClient.ts index a942c7ed14c8..c4a7a39dd76e 100644 --- a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClient.ts +++ b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClient.ts @@ -22,6 +22,7 @@ class AppPlatformManagementClient extends AppPlatformManagementClientContext { monitoringSettings: operations.MonitoringSettings; apps: operations.Apps; bindings: operations.Bindings; + storages: operations.Storages; certificates: operations.Certificates; customDomains: operations.CustomDomains; deployments: operations.Deployments; @@ -48,6 +49,7 @@ class AppPlatformManagementClient extends AppPlatformManagementClientContext { this.monitoringSettings = new operations.MonitoringSettings(this); this.apps = new operations.Apps(this); this.bindings = new operations.Bindings(this); + this.storages = new operations.Storages(this); this.certificates = new operations.Certificates(this); this.customDomains = new operations.CustomDomains(this); this.deployments = new operations.Deployments(this); diff --git a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts index 27e67f0731fd..1e574e07917f 100644 --- a/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts +++ b/sdk/appplatform/arm-appplatform/src/appPlatformManagementClientContext.ts @@ -50,7 +50,7 @@ export class AppPlatformManagementClientContext extends msRestAzure.AzureService super(credentials, options); - this.apiVersion = '2021-06-01-preview'; + this.apiVersion = '2021-09-01-preview'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; diff --git a/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts index c1543243c627..ea401d1f31d3 100644 --- a/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/appsMappers.ts @@ -7,10 +7,12 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceCollection, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -22,18 +24,24 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, CustomDomainValidatePayload, CustomDomainValidateResult, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -47,6 +55,10 @@ export { ResourceUploadDefinition, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts index a8fef206e095..ab0c7e9ef491 100644 --- a/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/bindingsMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceCollection, @@ -22,16 +24,22 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -44,6 +52,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts b/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts index f0d9c604020b..856d401cf48d 100644 --- a/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/certificatesMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -22,16 +24,22 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -44,6 +52,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts b/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts index 4fbb71a816ed..7cf80efbb36c 100644 --- a/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/configServersMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -23,16 +25,22 @@ export { ConfigServerSettings, ConfigServerSettingsErrorRecord, ConfigServerSettingsValidateResult, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -45,6 +53,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts index 66d675938524..296439b02737 100644 --- a/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/customDomainsMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -21,17 +23,23 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, CustomDomainResourceCollection, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -44,6 +52,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts index 3da0223f88d1..bfa4bd1433e1 100644 --- a/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/deploymentsMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -21,17 +23,24 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceCollection, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, + DiagnosticParameters, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, LogFileUrlResponse, ManagedIdentityProperties, MonitoringSettingProperties, @@ -45,6 +54,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/index.ts b/sdk/appplatform/arm-appplatform/src/models/index.ts index 542f5caec2d9..87858cdfb34d 100644 --- a/sdk/appplatform/arm-appplatform/src/models/index.ts +++ b/sdk/appplatform/arm-appplatform/src/models/index.ts @@ -113,6 +113,11 @@ export interface ClusterResourceProperties { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly serviceId?: string; + /** + * Power state of the Service. Possible values include: 'Running', 'Stopped' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly powerState?: PowerState; } /** @@ -491,7 +496,7 @@ export interface TemporaryDisk { */ sizeInGB?: number; /** - * Mount path of the temporary disk + * Mount path of the temporary disk. Default value: '/tmp'. */ mountPath?: string; } @@ -515,6 +520,62 @@ export interface PersistentDisk { mountPath?: string; } +/** + * Contains the possible cases for CustomPersistentDiskProperties. + */ +export type CustomPersistentDiskPropertiesUnion = CustomPersistentDiskProperties | AzureFileVolume; + +/** + * Custom persistent disk resource payload. + */ +export interface CustomPersistentDiskProperties { + /** + * Polymorphic Discriminator + */ + type: "CustomPersistentDiskProperties"; + /** + * The mount path of the persistent disk. + */ + mountPath: string; + /** + * Indicates whether the persistent disk is a readOnly one. + */ + readOnly?: boolean; + /** + * These are the mount options for a persistent disk. + */ + mountOptions?: string[]; +} + +/** + * Custom persistent disk resource payload. + */ +export interface CustomPersistentDiskResource { + /** + * Properties of the custom persistent disk resource payload. + */ + customPersistentDiskProperties?: CustomPersistentDiskPropertiesUnion; + /** + * The resource id of Azure Spring Cloud Storage resource. + */ + storageId: string; +} + +/** + * Loaded certificate payload + */ +export interface LoadedCertificate { + /** + * Resource Id of loaded certificate + */ + resourceId: string; + /** + * Indicate whether the certificate will be loaded into default trust store, only work for Java + * runtime. Default value: false. + */ + loadTrustStore?: boolean; +} + /** * App resource properties payload */ @@ -543,7 +604,7 @@ export interface AppResourceProperties { */ fqdn?: string; /** - * Indicate if only https is allowed. + * Indicate if only https is allowed. Default value: false. */ httpsOnly?: boolean; /** @@ -560,9 +621,17 @@ export interface AppResourceProperties { */ persistentDisk?: PersistentDisk; /** - * Indicate if end to end TLS is enabled. + * List of custom persistent disks + */ + customPersistentDisks?: CustomPersistentDiskResource[]; + /** + * Indicate if end to end TLS is enabled. Default value: false. */ enableEndToEndTLS?: boolean; + /** + * Collection of loaded certificates + */ + loadedCertificates?: LoadedCertificate[]; } /** @@ -650,15 +719,109 @@ export interface BindingResource extends ProxyResource { properties?: BindingResourceProperties; } +/** + * Contains the possible cases for CertificateProperties. + */ +export type CertificatePropertiesUnion = CertificateProperties | KeyVaultCertificateProperties | ContentCertificateProperties; + /** * Certificate resource payload. */ export interface CertificateProperties { + /** + * Polymorphic Discriminator + */ + type: "CertificateProperties"; /** * The thumbprint of certificate. * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly thumbprint?: string; + /** + * The issuer of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly issuer?: string; + /** + * The issue date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly issuedDate?: string; + /** + * The expiration date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly expirationDate?: string; + /** + * The activate date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly activateDate?: string; + /** + * The subject name of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly subjectName?: string; + /** + * The domain list of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly dnsNames?: string[]; +} + +/** + * Certificate resource payload. + */ +export interface CertificateResource extends ProxyResource { + /** + * Properties of the certificate resource payload. + */ + properties?: CertificatePropertiesUnion; +} + +/** + * Properties of certificate imported from key vault. + */ +export interface KeyVaultCertificateProperties { + /** + * Polymorphic Discriminator + */ + type: "KeyVaultCertificate"; + /** + * The thumbprint of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly thumbprint?: string; + /** + * The issuer of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly issuer?: string; + /** + * The issue date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly issuedDate?: string; + /** + * The expiration date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly expirationDate?: string; + /** + * The activate date of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly activateDate?: string; + /** + * The subject name of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly subjectName?: string; + /** + * The domain list of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly dnsNames?: string[]; /** * The vault uri of user key vault. */ @@ -671,6 +834,25 @@ export interface CertificateProperties { * The certificate version of key vault. */ certVersion?: string; + /** + * Optional. If set to true, it will not import private key from key vault. Default value: false. + */ + excludePrivateKey?: boolean; +} + +/** + * Properties of certificate imported from key vault. + */ +export interface ContentCertificateProperties { + /** + * Polymorphic Discriminator + */ + type: "ContentCertificate"; + /** + * The thumbprint of certificate. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly thumbprint?: string; /** * The issuer of certificate. * **NOTE: This property will not be serialized. It can only be populated by the server.** @@ -701,16 +883,115 @@ export interface CertificateProperties { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly dnsNames?: string[]; + /** + * The content of uploaded certificate. + */ + content: string; } /** - * Certificate resource payload. + * Contains the possible cases for StorageProperties. */ -export interface CertificateResource extends ProxyResource { +export type StoragePropertiesUnion = StorageProperties | StorageAccount; + +/** + * Storage resource payload. + */ +export interface StorageProperties { /** - * Properties of the certificate resource payload. + * Polymorphic Discriminator + */ + storageType: "StorageProperties"; +} + +/** + * Metadata pertaining to creation and last modification of the resource. + */ +export interface SystemData { + /** + * The identity that created the resource. + */ + createdBy?: string; + /** + * The type of identity that created the resource. Possible values include: 'User', + * 'Application', 'ManagedIdentity', 'Key' + */ + createdByType?: CreatedByType; + /** + * The timestamp of resource creation (UTC). + */ + createdAt?: Date; + /** + * The identity that last modified the resource. */ - properties?: CertificateProperties; + lastModifiedBy?: string; + /** + * The type of identity that last modified the resource. Possible values include: 'User', + * 'Application', 'ManagedIdentity', 'Key' + */ + lastModifiedByType?: CreatedByType; + /** + * The timestamp of resource last modification (UTC) + */ + lastModifiedAt?: Date; +} + +/** + * Storage resource payload. + */ +export interface StorageResource extends ProxyResource { + /** + * Properties of the storage resource payload. + */ + properties?: StoragePropertiesUnion; + /** + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly systemData?: SystemData; +} + +/** + * storage resource of type Azure Storage Account. + */ +export interface StorageAccount { + /** + * Polymorphic Discriminator + */ + storageType: "StorageAccount"; + /** + * The account name of the Azure Storage Account. + */ + accountName: string; + /** + * The account key of the Azure Storage Account. + */ + accountKey: string; +} + +/** + * The properties of the Azure File volume. Azure File shares are mounted as volumes. + */ +export interface AzureFileVolume { + /** + * Polymorphic Discriminator + */ + type: "AzureFileVolume"; + /** + * The mount path of the persistent disk. + */ + mountPath: string; + /** + * Indicates whether the persistent disk is a readOnly one. + */ + readOnly?: boolean; + /** + * These are the mount options for a persistent disk. + */ + mountOptions?: string[]; + /** + * The share name of the Azure File share. + */ + shareName: string; } /** @@ -885,19 +1166,29 @@ export interface ResourceRequests { memory?: string; } +/** + * Container liveness and readiness probe settings + */ +export interface DeploymentSettingsContainerProbeSettings { + /** + * Indicates whether disable the liveness and readiness probe + */ + disableProbe?: boolean; +} + /** * Deployment settings payload */ export interface DeploymentSettings { /** * Required CPU. This should be 1 for Basic tier, and in range [1, 4] for Standard tier. This is - * deprecated starting from API version 2021-06-01-preview. Please use the resourceRequests field + * deprecated starting from API version 2021-09-01-preview. Please use the resourceRequests field * to set the CPU size. Default value: 1. */ cpu?: number; /** * Required Memory size in GB. This should be in range [1, 2] for Basic tier, and in range [1, 8] - * for Standard tier. This is deprecated starting from API version 2021-06-01-preview. Please use + * for Standard tier. This is deprecated starting from API version 2021-09-01-preview. Please use * the resourceRequests field to set the the memory size. Default value: 1. */ memoryInGB?: number; @@ -920,9 +1211,14 @@ export interface DeploymentSettings { */ environmentVariables?: { [propertyName: string]: string }; /** - * Runtime version. Possible values include: 'Java_8', 'Java_11', 'NetCore_31' + * Runtime version. Possible values include: 'Java_8', 'Java_11', 'NetCore_31'. Default value: + * 'Java_8'. */ runtimeVersion?: RuntimeVersion; + /** + * Container liveness and readiness probe settings + */ + containerProbeSettings?: DeploymentSettingsContainerProbeSettings; } /** @@ -1026,6 +1322,24 @@ export interface LogFileUrlResponse { url: string; } +/** + * Diagnostic parameters of diagnostic operations + */ +export interface DiagnosticParameters { + /** + * App instance name + */ + appInstance?: string; + /** + * Your target file path in your own BYOS + */ + filePath?: string; + /** + * Duration of your JFR. 1 min can be represented by 1m or 60s. + */ + duration?: string; +} + /** * Operation display payload */ @@ -1130,6 +1444,10 @@ export interface MetricSpecification { * Dimensions of the metric */ dimensions?: MetricDimension[]; + /** + * Name of the MDM namespace. Optional. + */ + sourceMdmNamespace?: string; } /** @@ -1452,6 +1770,18 @@ export interface BindingResourceCollection extends Array { nextLink?: string; } +/** + * @interface + * Collection compose of storage resources list and a possible link for next page. + * @extends Array + */ +export interface StorageResourceCollection extends Array { + /** + * The link to next page of storage list. + */ + nextLink?: string; +} + /** * @interface * Collection compose of certificate resources list and a possible link for next page. @@ -1532,6 +1862,14 @@ export type ProvisioningState = 'Creating' | 'Updating' | 'Deleting' | 'Deleted' */ export type TrafficDirection = 'Inbound' | 'Outbound'; +/** + * Defines values for PowerState. + * Possible values include: 'Running', 'Stopped' + * @readonly + * @enum {string} + */ +export type PowerState = 'Running' | 'Stopped'; + /** * Defines values for ManagedIdentityType. * Possible values include: 'None', 'SystemAssigned', 'UserAssigned', 'SystemAssigned,UserAssigned' @@ -1572,6 +1910,14 @@ export type TestKeyType = 'Primary' | 'Secondary'; */ export type AppResourceProvisioningState = 'Succeeded' | 'Failed' | 'Creating' | 'Updating'; +/** + * Defines values for CreatedByType. + * Possible values include: 'User', 'Application', 'ManagedIdentity', 'Key' + * @readonly + * @enum {string} + */ +export type CreatedByType = 'User' | 'Application' | 'ManagedIdentity' | 'Key'; + /** * Defines values for UserSourceType. * Possible values include: 'Jar', 'NetCoreZip', 'Source', 'Container' @@ -2465,6 +2811,106 @@ export type BindingsListNextResponse = BindingResourceCollection & { }; }; +/** + * Contains response data for the get operation. + */ +export type StoragesGetResponse = StorageResource & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageResource; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type StoragesCreateOrUpdateResponse = StorageResource & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageResource; + }; +}; + +/** + * Contains response data for the list operation. + */ +export type StoragesListResponse = StorageResourceCollection & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageResourceCollection; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type StoragesBeginCreateOrUpdateResponse = StorageResource & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageResource; + }; +}; + +/** + * Contains response data for the listNext operation. + */ +export type StoragesListNextResponse = StorageResourceCollection & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageResourceCollection; + }; +}; + /** * Contains response data for the get operation. */ diff --git a/sdk/appplatform/arm-appplatform/src/models/mappers.ts b/sdk/appplatform/arm-appplatform/src/models/mappers.ts index c80ead76b135..a5ad7e07ec7b 100644 --- a/sdk/appplatform/arm-appplatform/src/models/mappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/mappers.ts @@ -183,6 +183,13 @@ export const ClusterResourceProperties: msRest.CompositeMapper = { type: { name: "String" } + }, + powerState: { + readOnly: true, + serializedName: "powerState", + type: { + name: "String" + } } } } @@ -823,6 +830,7 @@ export const TemporaryDisk: msRest.CompositeMapper = { }, mountPath: { serializedName: "mountPath", + defaultValue: '/tmp', type: { name: "String" } @@ -868,6 +876,100 @@ export const PersistentDisk: msRest.CompositeMapper = { } }; +export const CustomPersistentDiskProperties: msRest.CompositeMapper = { + serializedName: "CustomPersistentDiskProperties", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "type", + clientName: "type" + }, + uberParent: "CustomPersistentDiskProperties", + className: "CustomPersistentDiskProperties", + modelProperties: { + mountPath: { + required: true, + serializedName: "mountPath", + type: { + name: "String" + } + }, + readOnly: { + serializedName: "readOnly", + type: { + name: "Boolean" + } + }, + mountOptions: { + serializedName: "mountOptions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + type: { + required: true, + serializedName: "type", + type: { + name: "String" + } + } + } + } +}; + +export const CustomPersistentDiskResource: msRest.CompositeMapper = { + serializedName: "CustomPersistentDiskResource", + type: { + name: "Composite", + className: "CustomPersistentDiskResource", + modelProperties: { + customPersistentDiskProperties: { + serializedName: "customPersistentDiskProperties", + type: { + name: "Composite", + className: "CustomPersistentDiskProperties" + } + }, + storageId: { + required: true, + serializedName: "storageId", + type: { + name: "String" + } + } + } + } +}; + +export const LoadedCertificate: msRest.CompositeMapper = { + serializedName: "LoadedCertificate", + type: { + name: "Composite", + className: "LoadedCertificate", + modelProperties: { + resourceId: { + required: true, + serializedName: "resourceId", + type: { + name: "String" + } + }, + loadTrustStore: { + serializedName: "loadTrustStore", + defaultValue: false, + type: { + name: "Boolean" + } + } + } + } +}; + export const AppResourceProperties: msRest.CompositeMapper = { serializedName: "AppResourceProperties", type: { @@ -908,6 +1010,7 @@ export const AppResourceProperties: msRest.CompositeMapper = { }, httpsOnly: { serializedName: "httpsOnly", + defaultValue: false, type: { name: "Boolean" } @@ -933,11 +1036,36 @@ export const AppResourceProperties: msRest.CompositeMapper = { className: "PersistentDisk" } }, + customPersistentDisks: { + serializedName: "customPersistentDisks", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "CustomPersistentDiskResource" + } + } + } + }, enableEndToEndTLS: { serializedName: "enableEndToEndTLS", + defaultValue: false, type: { name: "Boolean" } + }, + loadedCertificates: { + serializedName: "loadedCertificates", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "LoadedCertificate" + } + } + } } } } @@ -1086,6 +1214,11 @@ export const CertificateProperties: msRest.CompositeMapper = { serializedName: "CertificateProperties", type: { name: "Composite", + polymorphicDiscriminator: { + serializedName: "type", + clientName: "type" + }, + uberParent: "CertificateProperties", className: "CertificateProperties", modelProperties: { thumbprint: { @@ -1095,26 +1228,6 @@ export const CertificateProperties: msRest.CompositeMapper = { name: "String" } }, - vaultUri: { - required: true, - serializedName: "vaultUri", - type: { - name: "String" - } - }, - keyVaultCertName: { - required: true, - serializedName: "keyVaultCertName", - type: { - name: "String" - } - }, - certVersion: { - serializedName: "certVersion", - type: { - name: "String" - } - }, issuer: { readOnly: true, serializedName: "issuer", @@ -1161,6 +1274,13 @@ export const CertificateProperties: msRest.CompositeMapper = { } } } + }, + type: { + required: true, + serializedName: "type", + type: { + name: "String" + } } } } @@ -1184,6 +1304,207 @@ export const CertificateResource: msRest.CompositeMapper = { } }; +export const KeyVaultCertificateProperties: msRest.CompositeMapper = { + serializedName: "KeyVaultCertificate", + type: { + name: "Composite", + polymorphicDiscriminator: CertificateProperties.type.polymorphicDiscriminator, + uberParent: "CertificateProperties", + className: "KeyVaultCertificateProperties", + modelProperties: { + ...CertificateProperties.type.modelProperties, + vaultUri: { + required: true, + serializedName: "vaultUri", + type: { + name: "String" + } + }, + keyVaultCertName: { + required: true, + serializedName: "keyVaultCertName", + type: { + name: "String" + } + }, + certVersion: { + serializedName: "certVersion", + type: { + name: "String" + } + }, + excludePrivateKey: { + serializedName: "excludePrivateKey", + defaultValue: false, + type: { + name: "Boolean" + } + } + } + } +}; + +export const ContentCertificateProperties: msRest.CompositeMapper = { + serializedName: "ContentCertificate", + type: { + name: "Composite", + polymorphicDiscriminator: CertificateProperties.type.polymorphicDiscriminator, + uberParent: "CertificateProperties", + className: "ContentCertificateProperties", + modelProperties: { + ...CertificateProperties.type.modelProperties, + content: { + required: true, + serializedName: "content", + type: { + name: "String" + } + } + } + } +}; + +export const StorageProperties: msRest.CompositeMapper = { + serializedName: "StorageProperties", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "storageType", + clientName: "storageType" + }, + uberParent: "StorageProperties", + className: "StorageProperties", + modelProperties: { + storageType: { + required: true, + serializedName: "storageType", + type: { + name: "String" + } + } + } + } +}; + +export const SystemData: msRest.CompositeMapper = { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String" + } + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String" + } + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime" + } + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String" + } + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String" + } + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime" + } + } + } + } +}; + +export const StorageResource: msRest.CompositeMapper = { + serializedName: "StorageResource", + type: { + name: "Composite", + className: "StorageResource", + modelProperties: { + ...ProxyResource.type.modelProperties, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "StorageProperties" + } + }, + systemData: { + readOnly: true, + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + } + } + } +}; + +export const StorageAccount: msRest.CompositeMapper = { + serializedName: "StorageAccount", + type: { + name: "Composite", + polymorphicDiscriminator: StorageProperties.type.polymorphicDiscriminator, + uberParent: "StorageProperties", + className: "StorageAccount", + modelProperties: { + ...StorageProperties.type.modelProperties, + accountName: { + required: true, + serializedName: "accountName", + type: { + name: "String" + } + }, + accountKey: { + required: true, + serializedName: "accountKey", + type: { + name: "String" + } + } + } + } +}; + +export const AzureFileVolume: msRest.CompositeMapper = { + serializedName: "AzureFileVolume", + type: { + name: "Composite", + polymorphicDiscriminator: CustomPersistentDiskProperties.type.polymorphicDiscriminator, + uberParent: "CustomPersistentDiskProperties", + className: "AzureFileVolume", + modelProperties: { + ...CustomPersistentDiskProperties.type.modelProperties, + shareName: { + required: true, + serializedName: "shareName", + type: { + name: "String" + } + } + } + } +}; + export const NameAvailabilityParameters: msRest.CompositeMapper = { serializedName: "NameAvailabilityParameters", type: { @@ -1458,6 +1779,22 @@ export const ResourceRequests: msRest.CompositeMapper = { } }; +export const DeploymentSettingsContainerProbeSettings: msRest.CompositeMapper = { + serializedName: "DeploymentSettings_containerProbeSettings", + type: { + name: "Composite", + className: "DeploymentSettingsContainerProbeSettings", + modelProperties: { + disableProbe: { + serializedName: "disableProbe", + type: { + name: "Boolean" + } + } + } + } +}; + export const DeploymentSettings: msRest.CompositeMapper = { serializedName: "DeploymentSettings", type: { @@ -1510,9 +1847,17 @@ export const DeploymentSettings: msRest.CompositeMapper = { }, runtimeVersion: { serializedName: "runtimeVersion", + defaultValue: 'Java_8', type: { name: "String" } + }, + containerProbeSettings: { + serializedName: "containerProbeSettings", + type: { + name: "Composite", + className: "DeploymentSettingsContainerProbeSettings" + } } } } @@ -1677,6 +2022,34 @@ export const LogFileUrlResponse: msRest.CompositeMapper = { } }; +export const DiagnosticParameters: msRest.CompositeMapper = { + serializedName: "DiagnosticParameters", + type: { + name: "Composite", + className: "DiagnosticParameters", + modelProperties: { + appInstance: { + serializedName: "appInstance", + type: { + name: "String" + } + }, + filePath: { + serializedName: "filePath", + type: { + name: "String" + } + }, + duration: { + serializedName: "duration", + type: { + name: "String" + } + } + } + } +}; + export const OperationDisplay: msRest.CompositeMapper = { serializedName: "OperationDisplay", type: { @@ -1848,6 +2221,12 @@ export const MetricSpecification: msRest.CompositeMapper = { } } } + }, + sourceMdmNamespace: { + serializedName: "sourceMdmNamespace", + type: { + name: "String" + } } } } @@ -2352,6 +2731,34 @@ export const BindingResourceCollection: msRest.CompositeMapper = { } }; +export const StorageResourceCollection: msRest.CompositeMapper = { + serializedName: "StorageResourceCollection", + type: { + name: "Composite", + className: "StorageResourceCollection", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StorageResource" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + export const CertificateResourceCollection: msRest.CompositeMapper = { serializedName: "CertificateResourceCollection", type: { @@ -2491,3 +2898,14 @@ export const ResourceSkuCollection: msRest.CompositeMapper = { } } }; + +export const discriminators = { + 'CustomPersistentDiskProperties' : CustomPersistentDiskProperties, + 'CertificateProperties' : CertificateProperties, + 'CertificateProperties.KeyVaultCertificate' : KeyVaultCertificateProperties, + 'CertificateProperties.ContentCertificate' : ContentCertificateProperties, + 'StorageProperties' : StorageProperties, + 'StorageProperties.StorageAccount' : StorageAccount, + 'CustomPersistentDiskProperties.AzureFileVolume' : AzureFileVolume + +}; diff --git a/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts index b827ef84ea79..7dd219f43f29 100644 --- a/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/monitoringSettingsMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -21,16 +23,22 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -43,6 +51,10 @@ export { ResourceRequests, ServiceResource, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TrackedResource, UserSourceInfo diff --git a/sdk/appplatform/arm-appplatform/src/models/operationsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/operationsMappers.ts index 218ea3c39ef1..a6b0df4854c7 100644 --- a/sdk/appplatform/arm-appplatform/src/models/operationsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/operationsMappers.ts @@ -7,6 +7,7 @@ */ export { + discriminators, AvailableOperations, CloudError, LogSpecification, diff --git a/sdk/appplatform/arm-appplatform/src/models/parameters.ts b/sdk/appplatform/arm-appplatform/src/models/parameters.ts index 8ac2710fcff9..da9faba30bdb 100644 --- a/sdk/appplatform/arm-appplatform/src/models/parameters.ts +++ b/sdk/appplatform/arm-appplatform/src/models/parameters.ts @@ -123,6 +123,16 @@ export const serviceName: msRest.OperationURLParameter = { } } }; +export const storageName: msRest.OperationURLParameter = { + parameterPath: "storageName", + mapper: { + required: true, + serializedName: "storageName", + type: { + name: "String" + } + } +}; export const subscriptionId: msRest.OperationURLParameter = { parameterPath: "subscriptionId", mapper: { diff --git a/sdk/appplatform/arm-appplatform/src/models/runtimeVersionsMappers.ts b/sdk/appplatform/arm-appplatform/src/models/runtimeVersionsMappers.ts index 04e9ae59bded..5faadea60b5f 100644 --- a/sdk/appplatform/arm-appplatform/src/models/runtimeVersionsMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/runtimeVersionsMappers.ts @@ -7,6 +7,7 @@ */ export { + discriminators, AvailableRuntimeVersions, CloudError, SupportedRuntimeVersion diff --git a/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts b/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts index 58194934685e..9a976e0d19dd 100644 --- a/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/servicesMappers.ts @@ -7,9 +7,11 @@ */ export { + discriminators, ApplicationInsightsAgentVersions, AppResource, AppResourceProperties, + AzureFileVolume, BaseResource, BindingResource, BindingResourceProperties, @@ -21,16 +23,22 @@ export { ConfigServerProperties, ConfigServerResource, ConfigServerSettings, + ContentCertificateProperties, CustomContainer, CustomDomainProperties, CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, DeploymentInstance, DeploymentResource, DeploymentResourceProperties, DeploymentSettings, + DeploymentSettingsContainerProbeSettings, ErrorModel, GitPatternRepository, ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, ManagedIdentityProperties, MonitoringSettingProperties, MonitoringSettingResource, @@ -47,6 +55,10 @@ export { ServiceResource, ServiceResourceList, Sku, + StorageAccount, + StorageProperties, + StorageResource, + SystemData, TemporaryDisk, TestKeys, TrackedResource, diff --git a/sdk/appplatform/arm-appplatform/src/models/skusMappers.ts b/sdk/appplatform/arm-appplatform/src/models/skusMappers.ts index a5cf0046a0ab..d7cbe88c62a8 100644 --- a/sdk/appplatform/arm-appplatform/src/models/skusMappers.ts +++ b/sdk/appplatform/arm-appplatform/src/models/skusMappers.ts @@ -7,6 +7,7 @@ */ export { + discriminators, CloudError, ResourceSku, ResourceSkuCapabilities, diff --git a/sdk/appplatform/arm-appplatform/src/models/storagesMappers.ts b/sdk/appplatform/arm-appplatform/src/models/storagesMappers.ts new file mode 100644 index 000000000000..6a5dceb21b20 --- /dev/null +++ b/sdk/appplatform/arm-appplatform/src/models/storagesMappers.ts @@ -0,0 +1,62 @@ +/* + * 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. + */ + +export { + discriminators, + ApplicationInsightsAgentVersions, + AppResource, + AppResourceProperties, + AzureFileVolume, + BaseResource, + BindingResource, + BindingResourceProperties, + CertificateProperties, + CertificateResource, + CloudError, + ClusterResourceProperties, + ConfigServerGitProperty, + ConfigServerProperties, + ConfigServerResource, + ConfigServerSettings, + ContentCertificateProperties, + CustomContainer, + CustomDomainProperties, + CustomDomainResource, + CustomPersistentDiskProperties, + CustomPersistentDiskResource, + DeploymentInstance, + DeploymentResource, + DeploymentResourceProperties, + DeploymentSettings, + DeploymentSettingsContainerProbeSettings, + ErrorModel, + GitPatternRepository, + ImageRegistryCredential, + KeyVaultCertificateProperties, + LoadedCertificate, + ManagedIdentityProperties, + MonitoringSettingProperties, + MonitoringSettingResource, + NetworkProfile, + NetworkProfileOutboundIPs, + PersistentDisk, + ProxyResource, + RequiredTraffic, + Resource, + ResourceRequests, + ServiceResource, + Sku, + StorageAccount, + StorageProperties, + StorageResource, + StorageResourceCollection, + SystemData, + TemporaryDisk, + TrackedResource, + UserSourceInfo +} from "../models/mappers"; diff --git a/sdk/appplatform/arm-appplatform/src/operations/deployments.ts b/sdk/appplatform/arm-appplatform/src/operations/deployments.ts index 5d43a943cda6..9f44d1bed977 100644 --- a/sdk/appplatform/arm-appplatform/src/operations/deployments.ts +++ b/sdk/appplatform/arm-appplatform/src/operations/deployments.ts @@ -278,6 +278,54 @@ export class Deployments { callback) as Promise; } + /** + * Generate Heap Dump + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + generateHeapDump(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginGenerateHeapDump(resourceGroupName,serviceName,appName,deploymentName,diagnosticParameters,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Generate Thread Dump + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + generateThreadDump(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginGenerateThreadDump(resourceGroupName,serviceName,appName,deploymentName,diagnosticParameters,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Start JFR + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + startJFR(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginStartJFR(resourceGroupName,serviceName,appName,deploymentName,diagnosticParameters,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + /** * Create a new Deployment or update an exiting Deployment. * @param resourceGroupName The name of the resource group that contains the resource. You can @@ -420,6 +468,81 @@ export class Deployments { options); } + /** + * Generate Heap Dump + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + beginGenerateHeapDump(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + appName, + deploymentName, + diagnosticParameters, + options + }, + beginGenerateHeapDumpOperationSpec, + options); + } + + /** + * Generate Thread Dump + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + beginGenerateThreadDump(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + appName, + deploymentName, + diagnosticParameters, + options + }, + beginGenerateThreadDumpOperationSpec, + options); + } + + /** + * Start JFR + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param appName The name of the App resource. + * @param deploymentName The name of the Deployment resource. + * @param diagnosticParameters Parameters for the diagnostic operation + * @param [options] The optional parameters + * @returns Promise + */ + beginStartJFR(resourceGroupName: string, serviceName: string, appName: string, deploymentName: string, diagnosticParameters: Models.DiagnosticParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + appName, + deploymentName, + diagnosticParameters, + options + }, + beginStartJFROperationSpec, + options); + } + /** * Handles requests to list all resources in an App. * @param nextPageLink The NextLink from the previous successful call to List operation. @@ -769,6 +892,105 @@ const beginRestartOperationSpec: msRest.OperationSpec = { serializer }; +const beginGenerateHeapDumpOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/apps/{appName}/deployments/{deploymentName}/generateHeapDump", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.appName, + Parameters.deploymentName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "diagnosticParameters", + mapper: { + ...Mappers.DiagnosticParameters, + required: true + } + }, + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginGenerateThreadDumpOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/apps/{appName}/deployments/{deploymentName}/generateThreadDump", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.appName, + Parameters.deploymentName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "diagnosticParameters", + mapper: { + ...Mappers.DiagnosticParameters, + required: true + } + }, + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginStartJFROperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/apps/{appName}/deployments/{deploymentName}/StartJFR", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.appName, + Parameters.deploymentName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "diagnosticParameters", + mapper: { + ...Mappers.DiagnosticParameters, + required: true + } + }, + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + const listNextOperationSpec: msRest.OperationSpec = { httpMethod: "GET", baseUrl: "https://management.azure.com", diff --git a/sdk/appplatform/arm-appplatform/src/operations/index.ts b/sdk/appplatform/arm-appplatform/src/operations/index.ts index b5ee450cb213..a145ac447489 100644 --- a/sdk/appplatform/arm-appplatform/src/operations/index.ts +++ b/sdk/appplatform/arm-appplatform/src/operations/index.ts @@ -12,6 +12,7 @@ export * from "./configServers"; export * from "./monitoringSettings"; export * from "./apps"; export * from "./bindings"; +export * from "./storages"; export * from "./certificates"; export * from "./customDomains"; export * from "./deployments"; diff --git a/sdk/appplatform/arm-appplatform/src/operations/services.ts b/sdk/appplatform/arm-appplatform/src/operations/services.ts index cb76d116d019..39f3a8bf0e68 100644 --- a/sdk/appplatform/arm-appplatform/src/operations/services.ts +++ b/sdk/appplatform/arm-appplatform/src/operations/services.ts @@ -246,6 +246,32 @@ export class Services { callback) as Promise; } + /** + * Stop a Service. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param [options] The optional parameters + * @returns Promise + */ + stop(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginStop(resourceGroupName,serviceName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Start a Service. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param [options] The optional parameters + * @returns Promise + */ + start(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginStart(resourceGroupName,serviceName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + /** * Checks that the resource name is valid and is not already in use. * @param location the region @@ -394,6 +420,44 @@ export class Services { options); } + /** + * Stop a Service. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param [options] The optional parameters + * @returns Promise + */ + beginStop(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + options + }, + beginStopOperationSpec, + options); + } + + /** + * Start a Service. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param [options] The optional parameters + * @returns Promise + */ + beginStart(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + options + }, + beginStartOperationSpec, + options); + } + /** * Handles requests to list all resources in a subscription. * @param nextPageLink The NextLink from the previous successful call to List operation. @@ -758,6 +822,56 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { serializer }; +const beginStopOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/stop", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 202: {}, + 404: {}, + 409: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginStartOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/start", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 202: {}, + 404: {}, + 409: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + const listBySubscriptionNextOperationSpec: msRest.OperationSpec = { httpMethod: "GET", baseUrl: "https://management.azure.com", diff --git a/sdk/appplatform/arm-appplatform/src/operations/storages.ts b/sdk/appplatform/arm-appplatform/src/operations/storages.ts new file mode 100644 index 000000000000..672c1be19702 --- /dev/null +++ b/sdk/appplatform/arm-appplatform/src/operations/storages.ts @@ -0,0 +1,345 @@ +/* + * 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 * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/storagesMappers"; +import * as Parameters from "../models/parameters"; +import { AppPlatformManagementClientContext } from "../appPlatformManagementClientContext"; + +/** Class representing a Storages. */ +export class Storages { + private readonly client: AppPlatformManagementClientContext; + + /** + * Create a Storages. + * @param {AppPlatformManagementClientContext} client Reference to the service client. + */ + constructor(client: AppPlatformManagementClientContext) { + this.client = client; + } + + /** + * Get the storage resource. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, serviceName: string, storageName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param callback The callback + */ + get(resourceGroupName: string, serviceName: string, storageName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, serviceName: string, storageName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, serviceName: string, storageName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + serviceName, + storageName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Create or update storage resource. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param storageResource Parameters for the create or update operation + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(resourceGroupName: string, serviceName: string, storageName: string, storageResource: Models.StorageResource, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(resourceGroupName,serviceName,storageName,storageResource,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Delete the storage resource. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, serviceName: string, storageName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,serviceName,storageName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * List all the storages of one Azure Spring Cloud instance. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param callback The callback + */ + list(resourceGroupName: string, serviceName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, serviceName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + serviceName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Create or update storage resource. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param storageResource Parameters for the create or update operation + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(resourceGroupName: string, serviceName: string, storageName: string, storageResource: Models.StorageResource, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + storageName, + storageResource, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Delete the storage resource. + * @param resourceGroupName The name of the resource group that contains the resource. You can + * obtain this value from the Azure Resource Manager API or the portal. + * @param serviceName The name of the Service resource. + * @param storageName The name of the storage resource. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, serviceName: string, storageName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + serviceName, + storageName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * List all the storages of one Azure Spring Cloud instance. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/storages/{storageName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.storageName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageResource + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/storages", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageResourceCollection + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/storages/{storageName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.storageName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "storageResource", + mapper: { + ...Mappers.StorageResource, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.StorageResource + }, + 201: { + bodyMapper: Mappers.StorageResource + }, + 202: { + bodyMapper: Mappers.StorageResource + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/storages/{storageName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.storageName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageResourceCollection + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +};