From 02a2fe6e69790a199a45f5ff4a8b915530e9d69c Mon Sep 17 00:00:00 2001 From: colawwj Date: Wed, 26 Aug 2020 15:07:37 +0800 Subject: [PATCH 1/3] release arm-netapp --- sdk/netapp/arm-netapp/package.json | 2 +- .../arm-netapp/src/azureNetAppFilesManagementClientContext.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sdk/netapp/arm-netapp/package.json b/sdk/netapp/arm-netapp/package.json index 1ad2335d20ab..adfd2e4f6662 100644 --- a/sdk/netapp/arm-netapp/package.json +++ b/sdk/netapp/arm-netapp/package.json @@ -2,7 +2,7 @@ "name": "@azure/arm-netapp", "author": "Microsoft Corporation", "description": "AzureNetAppFilesManagementClient Library with typescript type definitions for node.js and browser.", - "version": "11.0.0", + "version": "11.1.0", "dependencies": { "@azure/ms-rest-azure-js": "^2.0.1", "@azure/ms-rest-js": "^2.0.4", diff --git a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts index 7f4e6a994076..5acc8057033a 100644 --- a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts +++ b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts @@ -13,7 +13,7 @@ import * as msRest from "@azure/ms-rest-js"; import * as msRestAzure from "@azure/ms-rest-azure-js"; const packageName = "@azure/arm-netapp"; -const packageVersion = "11.0.0"; +const packageVersion = "11.1.0"; export class AzureNetAppFilesManagementClientContext extends msRestAzure.AzureServiceClient { credentials: msRest.ServiceClientCredentials; From b58255aa1fb6d3f0bed13bcd1b8bf90338cc59cb Mon Sep 17 00:00:00 2001 From: SDK Automation Date: Tue, 25 Aug 2020 07:18:08 +0000 Subject: [PATCH 2/3] Generated from efcb7ecf4722c919d5528c53671b124046badcdb update netapp readme.java.md --- .../src/azureNetAppFilesManagementClient.ts | 10 + ...azureNetAppFilesManagementClientContext.ts | 2 +- .../src/models/accountBackupsMappers.ts | 37 + .../arm-netapp/src/models/accountsMappers.ts | 9 + .../src/models/backupPoliciesMappers.ts | 38 + .../arm-netapp/src/models/backupsMappers.ts | 37 + sdk/netapp/arm-netapp/src/models/index.ts | 1638 ++++++++++++++--- sdk/netapp/arm-netapp/src/models/mappers.ts | 1395 +++++++++++++- .../src/models/netAppResourceMappers.ts | 3 +- .../arm-netapp/src/models/parameters.ts | 32 +- .../arm-netapp/src/models/poolsMappers.ts | 9 + .../src/models/snapshotPoliciesMappers.ts | 39 + .../arm-netapp/src/models/snapshotsMappers.ts | 9 + .../arm-netapp/src/models/vaultsMappers.ts | 37 + .../arm-netapp/src/models/volumesMappers.ts | 11 + .../src/operations/accountBackups.ts | 213 +++ .../src/operations/backupPolicies.ts | 362 ++++ .../arm-netapp/src/operations/backups.ts | 416 +++++ sdk/netapp/arm-netapp/src/operations/index.ts | 5 + .../src/operations/netAppResource.ts | 101 +- .../src/operations/snapshotPolicies.ts | 421 +++++ .../arm-netapp/src/operations/vaults.ts | 88 + .../arm-netapp/src/operations/volumes.ts | 153 +- 23 files changed, 4744 insertions(+), 321 deletions(-) create mode 100644 sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts create mode 100644 sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts create mode 100644 sdk/netapp/arm-netapp/src/models/backupsMappers.ts create mode 100644 sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts create mode 100644 sdk/netapp/arm-netapp/src/models/vaultsMappers.ts create mode 100644 sdk/netapp/arm-netapp/src/operations/accountBackups.ts create mode 100644 sdk/netapp/arm-netapp/src/operations/backupPolicies.ts create mode 100644 sdk/netapp/arm-netapp/src/operations/backups.ts create mode 100644 sdk/netapp/arm-netapp/src/operations/snapshotPolicies.ts create mode 100644 sdk/netapp/arm-netapp/src/operations/vaults.ts diff --git a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts index 16c0f6bd13d3..d824db98d0a1 100644 --- a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts +++ b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts @@ -23,6 +23,11 @@ class AzureNetAppFilesManagementClient extends AzureNetAppFilesManagementClientC pools: operations.Pools; volumes: operations.Volumes; snapshots: operations.Snapshots; + snapshotPolicies: operations.SnapshotPolicies; + accountBackups: operations.AccountBackups; + backups: operations.Backups; + backupPolicies: operations.BackupPolicies; + vaults: operations.Vaults; /** * Initializes a new instance of the AzureNetAppFilesManagementClient class. @@ -39,6 +44,11 @@ class AzureNetAppFilesManagementClient extends AzureNetAppFilesManagementClientC this.pools = new operations.Pools(this); this.volumes = new operations.Volumes(this); this.snapshots = new operations.Snapshots(this); + this.snapshotPolicies = new operations.SnapshotPolicies(this); + this.accountBackups = new operations.AccountBackups(this); + this.backups = new operations.Backups(this); + this.backupPolicies = new operations.BackupPolicies(this); + this.vaults = new operations.Vaults(this); } } diff --git a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts index 5acc8057033a..c57afcf826fc 100644 --- a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts +++ b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts @@ -45,7 +45,7 @@ export class AzureNetAppFilesManagementClientContext extends msRestAzure.AzureSe super(credentials, options); - this.apiVersion = '2020-02-01'; + this.apiVersion = '2020-06-01'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; diff --git a/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts b/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts new file mode 100644 index 000000000000..c42db7ed363e --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, + BackupsList, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + ExportPolicyRule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ReplicationObject, + Snapshot, + SnapshotPolicy, + Vault, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/accountsMappers.ts b/sdk/netapp/arm-netapp/src/models/accountsMappers.ts index 166b245eda8f..05b554d9792f 100644 --- a/sdk/netapp/arm-netapp/src/models/accountsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/accountsMappers.ts @@ -8,6 +8,10 @@ export { ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, BaseResource, CapacityPool, CapacityPoolPatch, @@ -19,8 +23,13 @@ export { NetAppAccountPatch, ReplicationObject, Snapshot, + SnapshotPolicy, + Vault, Volume, + VolumeBackupProperties, + VolumeBackups, VolumePatch, + VolumePatchPropertiesDataProtection, VolumePatchPropertiesExportPolicy, VolumePropertiesDataProtection, VolumePropertiesExportPolicy, diff --git a/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts b/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts new file mode 100644 index 000000000000..3e373e2acbb5 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts @@ -0,0 +1,38 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + ActiveDirectory, + Backup, + BackupPatch, + BackupPoliciesList, + BackupPolicy, + BackupPolicyDetails, + BackupPolicyPatch, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + ExportPolicyRule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ReplicationObject, + Snapshot, + SnapshotPolicy, + Vault, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/backupsMappers.ts b/sdk/netapp/arm-netapp/src/models/backupsMappers.ts new file mode 100644 index 000000000000..c42db7ed363e --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/backupsMappers.ts @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, + BackupsList, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + ExportPolicyRule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ReplicationObject, + Snapshot, + SnapshotPolicy, + Vault, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/index.ts b/sdk/netapp/arm-netapp/src/models/index.ts index 800a72d540e3..f77d7aa6894f 100644 --- a/sdk/netapp/arm-netapp/src/models/index.ts +++ b/sdk/netapp/arm-netapp/src/models/index.ts @@ -122,9 +122,9 @@ export interface Operation { } /** - * Information regarding availability of a resource name. + * Information regarding availability of a resource. */ -export interface ResourceNameAvailability { +export interface CheckAvailabilityResponse { /** * true indicates name is valid and available. false indicates the name * is invalid, unavailable, or both. @@ -166,6 +166,27 @@ export interface ResourceNameAvailabilityRequest { resourceGroup: string; } +/** + * Quota availability request content. + */ +export interface QuotaAvailabilityRequest { + /** + * Name of the resource to verify. + */ + name: string; + /** + * Resource type used for verification. Possible values include: + * 'Microsoft.NetApp/netAppAccounts', 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + */ + type: CheckQuotaNameResourceTypes; + /** + * Resource group name. + */ + resourceGroup: string; +} + /** * Active Directory */ @@ -179,7 +200,7 @@ export interface ActiveDirectory { */ username?: string; /** - * Plain text password of Active Directory domain administrator + * Plain text password of Active Directory domain administrator, value is masked in the response */ password?: string; /** @@ -191,9 +212,16 @@ export interface ActiveDirectory { */ dns?: string; /** - * Status of the Active Directory + * Status of the Active Directory. Possible values include: 'Created', 'InUse', 'Deleted', + * 'Error', 'Updating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly status?: ActiveDirectoryStatus; + /** + * Any details in regards to the Status of the Active Directory + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - status?: string; + readonly statusDetails?: string; /** * NetBIOS name of the SMB server. This name will be registered as a computer account in the AD * and used to mount volumes @@ -212,6 +240,22 @@ export interface ActiveDirectory { * usernames without domain specifier */ backupOperators?: string[]; + /** + * kdc server IP addresses for the active directory machine. This optional parameter is used only + * while creating kerberos volume. + */ + kdcIP?: string; + /** + * Name of the active directory machine. This optional parameter is used only while creating + * kerberos volume + */ + adName?: string; + /** + * When LDAP over SSL/TLS is enabled, the LDAP client is required to have base64 encoded Active + * Directory Certificate Service's self-signed root CA certificate, this optional parameter is + * used only for dual protocol with LDAP user-mapping volumes. + */ + serverRootCACertificate?: string; } /** @@ -337,6 +381,21 @@ export interface CapacityPool extends BaseResource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly provisioningState?: string; + /** + * Total throughput of pool in Mibps + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalThroughputMibps?: number; + /** + * Utilized throughput of pool in Mibps + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly utilizedThroughputMibps?: number; + /** + * qosType. The qos type of the pool. Possible values include: 'Auto', 'Manual'. Default value: + * 'Auto'. + */ + qosType?: QosType; } /** @@ -372,10 +431,10 @@ export interface CapacityPoolPatch extends BaseResource { */ size?: number; /** - * serviceLevel. The service level of the file system. Possible values include: 'Standard', - * 'Premium', 'Ultra'. Default value: 'Premium'. + * qosType. The qos type of the pool. Possible values include: 'Auto', 'Manual'. Default value: + * 'Auto'. */ - serviceLevel?: ServiceLevel; + qosType?: QosType; } /** @@ -394,6 +453,36 @@ export interface ExportPolicyRule { * Read and write access */ unixReadWrite?: boolean; + /** + * Kerberos5 Read only access. To be use with swagger version 2020-05-01 or later. Default value: + * false. + */ + kerberos5ReadOnly?: boolean; + /** + * Kerberos5 Read and write access. To be use with swagger version 2020-05-01 or later. Default + * value: false. + */ + kerberos5ReadWrite?: boolean; + /** + * Kerberos5i Read only access. To be use with swagger version 2020-05-01 or later. Default + * value: false. + */ + kerberos5iReadOnly?: boolean; + /** + * Kerberos5i Read and write access. To be use with swagger version 2020-05-01 or later. Default + * value: false. + */ + kerberos5iReadWrite?: boolean; + /** + * Kerberos5p Read only access. To be use with swagger version 2020-05-01 or later. Default + * value: false. + */ + kerberos5pReadOnly?: boolean; + /** + * Kerberos5p Read and write access. To be use with swagger version 2020-05-01 or later. Default + * value: false. + */ + kerberos5pReadWrite?: boolean; /** * Allows CIFS protocol */ @@ -411,6 +500,10 @@ export interface ExportPolicyRule { * and host names */ allowedClients?: string; + /** + * Has root access to volume. Default value: true. + */ + hasRootAccess?: boolean; } /** @@ -443,29 +536,31 @@ export interface MountTargetProperties { */ readonly ipAddress?: string; /** - * subnet. The subnet - */ - subnet?: string; - /** - * startIp. The start of IPv4 address range to use when creating a new mount target + * smbServerFQDN. The SMB server's Fully Qualified Domain Name, FQDN */ - startIp?: string; + smbServerFqdn?: string; +} + +/** + * Volume Backup Properties + */ +export interface VolumeBackupProperties { /** - * endIp. The end of IPv4 address range to use when creating a new mount target + * Backup Policy Resource ID */ - endIp?: string; + backupPolicyId?: string; /** - * gateway. The gateway of the IPv4 address range to use when creating a new mount target + * Policy Enforced */ - gateway?: string; + policyEnforced?: boolean; /** - * netmask. The netmask of the IPv4 address range to use when creating a new mount target + * Vault Resource ID */ - netmask?: string; + vaultId?: string; /** - * smbServerFQDN. The SMB server's Fully Qualified Domain Name, FQDN + * Backup Enabled */ - smbServerFqdn?: string; + backupEnabled?: boolean; } /** @@ -510,6 +605,10 @@ export interface VolumeSnapshotProperties { * @summary DataProtection */ export interface VolumePropertiesDataProtection { + /** + * Backup. Backup Properties + */ + backup?: VolumeBackupProperties; /** * Replication. Replication properties */ @@ -585,6 +684,10 @@ export interface Volume extends BaseResource { * Snapshot ID. UUID v4 or resource identifier used to identify the Snapshot. */ snapshotId?: string; + /** + * Backup ID. UUID v4 or resource identifier used to identify the Backup. + */ + backupId?: string; /** * Baremetal Tenant ID. Unique Baremetal Tenant Identifier. * **NOTE: This property will not be serialized. It can only be populated by the server.** @@ -617,6 +720,19 @@ export interface Volume extends BaseResource { * access to each of the volume's snapshots (default to true). */ snapshotDirectoryVisible?: boolean; + /** + * Describe if a volume is KerberosEnabled. To be use with swagger version 2020-05-01 or later. + * Default value: false. + */ + kerberosEnabled?: boolean; + /** + * The security style of volume. Possible values include: 'ntfs', 'unix' + */ + securityStyle?: SecurityStyle; + /** + * Maximum throughput in Mibps that can be achieved by this volume. + */ + throughputMibps?: number; } /** @@ -656,6 +772,17 @@ export interface VolumePatchPropertiesExportPolicy { rules?: ExportPolicyRule[]; } +/** + * DataProtection type volumes include an object containing details of the replication + * @summary DataProtection + */ +export interface VolumePatchPropertiesDataProtection { + /** + * Backup. Backup Properties + */ + backup?: VolumeBackupProperties; +} + /** * Volume patch resource */ @@ -698,6 +825,15 @@ export interface VolumePatch extends BaseResource { * exportPolicy. Set of export policy rules */ exportPolicy?: VolumePatchPropertiesExportPolicy; + /** + * Maximum throughput in Mibps that can be achieved by this volume. + */ + throughputMibps?: number; + /** + * DataProtection. DataProtection type volumes include an object containing details of the + * replication + */ + dataProtection?: VolumePatchPropertiesDataProtection; } /** @@ -741,26 +877,6 @@ export interface MountTarget { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly ipAddress?: string; - /** - * subnet. The subnet - */ - subnet?: string; - /** - * startIp. The start of IPv4 address range to use when creating a new mount target - */ - startIp?: string; - /** - * endIp. The end of IPv4 address range to use when creating a new mount target - */ - endIp?: string; - /** - * gateway. The gateway of the IPv4 address range to use when creating a new mount target - */ - gateway?: string; - /** - * netmask. The netmask of the IPv4 address range to use when creating a new mount target - */ - netmask?: string; /** * smbServerFQDN. The SMB server's Fully Qualified Domain Name, FQDN */ @@ -808,176 +924,1262 @@ export interface Snapshot extends BaseResource { } /** - * revert a volume to the snapshot + * Snapshot policy information */ -export interface VolumeRevert { +export interface SnapshotPolicy extends BaseResource { /** - * Resource id of the snapshot + * Resource location */ - snapshotId?: string; + location: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * hourlySchedule. Schedule for hourly snapshots + */ + hourlySchedule?: any; + /** + * dailySchedule. Schedule for daily snapshots + */ + dailySchedule?: any; + /** + * weeklySchedule. Schedule for weekly snapshots + */ + weeklySchedule?: any; + /** + * monthlySchedule. Schedule for monthly snapshots + */ + monthlySchedule?: any; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; } /** - * Authorize request + * Snapshot policy properties */ -export interface AuthorizeRequest { +export interface SnapshotPolicyDetails { /** - * Resource id of the remote volume + * Resource location */ - remoteVolumeResourceId?: string; + location?: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * hourlySchedule. Schedule for hourly snapshots + */ + hourlySchedule?: any; + /** + * dailySchedule. Schedule for daily snapshots + */ + dailySchedule?: any; + /** + * weeklySchedule. Schedule for weekly snapshots + */ + weeklySchedule?: any; + /** + * monthlySchedule. Schedule for monthly snapshots + */ + monthlySchedule?: any; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; } /** - * Optional Parameters. + * Snapshot policy Details for create and update */ -export interface VolumesRevertOptionalParams extends msRest.RequestOptionsBase { +export interface SnapshotPolicyPatch { /** - * Resource id of the snapshot + * Resource location */ - snapshotId?: string; + location?: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * hourlySchedule. Schedule for hourly snapshots + */ + hourlySchedule?: any; + /** + * dailySchedule. Schedule for daily snapshots + */ + dailySchedule?: any; + /** + * weeklySchedule. Schedule for weekly snapshots + */ + weeklySchedule?: any; + /** + * monthlySchedule. Schedule for monthly snapshots + */ + monthlySchedule?: any; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; } /** - * Optional Parameters. + * Volumes associated with snapshot policy */ -export interface VolumesAuthorizeReplicationOptionalParams extends msRest.RequestOptionsBase { +export interface SnapshotPolicyVolumeList { /** - * Resource id of the remote volume + * List of volumes */ - remoteVolumeResourceId?: string; + value?: any[]; } /** - * Optional Parameters. + * Hourly Schedule properties */ -export interface VolumesBeginRevertOptionalParams extends msRest.RequestOptionsBase { +export interface HourlySchedule { /** - * Resource id of the snapshot + * Hourly snapshot count to keep */ - snapshotId?: string; + snapshotsToKeep?: number; + /** + * Indicates which minute snapshot should be taken + */ + minute?: number; + /** + * Resource size in bytes, current storage usage for the volume in bytes + */ + usedBytes?: number; } /** - * Optional Parameters. + * Daily Schedule properties */ -export interface VolumesBeginAuthorizeReplicationOptionalParams extends msRest.RequestOptionsBase { +export interface DailySchedule { /** - * Resource id of the remote volume + * Daily snapshot count to keep */ - remoteVolumeResourceId?: string; + snapshotsToKeep?: number; + /** + * Indicates which hour in UTC timezone a snapshot should be taken + */ + hour?: number; + /** + * Indicates which minute snapshot should be taken + */ + minute?: number; + /** + * Resource size in bytes, current storage usage for the volume in bytes + */ + usedBytes?: number; } /** - * An interface representing AzureNetAppFilesManagementClientOptions. + * Weekly Schedule properties, make a snapshot every week at a specific day or days */ -export interface AzureNetAppFilesManagementClientOptions extends AzureServiceClientOptions { - baseUri?: string; +export interface WeeklySchedule { + /** + * Weekly snapshot count to keep + */ + snapshotsToKeep?: number; + /** + * Indicates which weekdays snapshot should be taken, accepts a comma separated list of week day + * names in english + */ + day?: string; + /** + * Indicates which hour in UTC timezone a snapshot should be taken + */ + hour?: number; + /** + * Indicates which minute snapshot should be taken + */ + minute?: number; + /** + * Resource size in bytes, current storage usage for the volume in bytes + */ + usedBytes?: number; } /** - * @interface - * Result of the request to list Cloud Volume operations. It contains a list of operations and a - * URL link to get the next set of results. - * @extends Array + * Monthly Schedule properties */ -export interface OperationListResult extends Array { +export interface MonthlySchedule { + /** + * Monthly snapshot count to keep + */ + snapshotsToKeep?: number; + /** + * Indicates which days of the month snapshot should be taken. A comma delimited string. + */ + daysOfMonth?: string; + /** + * Indicates which hour in UTC timezone a snapshot should be taken + */ + hour?: number; + /** + * Indicates which minute snapshot should be taken + */ + minute?: number; + /** + * Resource size in bytes, current storage usage for the volume in bytes + */ + usedBytes?: number; } /** - * @interface - * List of NetApp account resources - * @extends Array + * revert a volume to the snapshot */ -export interface NetAppAccountList extends Array { +export interface VolumeRevert { + /** + * Resource id of the snapshot + */ + snapshotId?: string; +} + +/** + * Authorize request + */ +export interface AuthorizeRequest { + /** + * Resource id of the remote volume + */ + remoteVolumeResourceId?: string; +} + +/** + * Break replication request + */ +export interface BreakReplicationRequest { + /** + * If replication is in status transferring and you want to force break the replication, set to + * true + */ + forceBreakReplication?: boolean; +} + +/** + * Pool change request + */ +export interface PoolChangeRequest { + /** + * Resource id of the pool to move volume to + */ + newPoolResourceId: string; +} + +/** + * Backup of a Volume + */ +export interface Backup extends BaseResource { + /** + * Resource location + */ + location: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * name. The creation date of the backup + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly creationDate?: Date; + /** + * Azure lifecycle management + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Size of backup + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly size?: number; + /** + * Label for backup + */ + label?: string; + /** + * Type of backup adhoc or scheduled + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly backupType?: string; +} + +/** + * Backup patch + */ +export interface BackupPatch extends BaseResource { + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * name. The creation date of the backup + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly creationDate?: Date; + /** + * Azure lifecycle management + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Size of backup + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly size?: number; + /** + * Label for backup + */ + label?: string; + /** + * Type of backup adhoc or scheduled + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly backupType?: string; +} + +/** + * Volume details using the backup policy + */ +export interface VolumeBackups { + /** + * Volume name + */ + volumeName?: string; + /** + * Total count of backups for volume + */ + backupsCount?: number; + /** + * Policy enabled + */ + policyEnabled?: boolean; +} + +/** + * Backup policy information + */ +export interface BackupPolicy extends BaseResource { + /** + * Resource location + */ + location: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * Name of backup policy + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name1?: string; + /** + * Azure lifecycle management + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Daily backups count to keep + */ + dailyBackupsToKeep?: number; + /** + * Weekly backups count to keep + */ + weeklyBackupsToKeep?: number; + /** + * Monthly backups count to keep + */ + monthlyBackupsToKeep?: number; + /** + * Yearly backups count to keep + */ + yearlyBackupsToKeep?: number; + /** + * Volumes using current backup policy + */ + volumesAssigned?: number; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; + /** + * A list of volumes assigned to this policy + */ + volumeBackups?: VolumeBackups[]; +} + +/** + * Backup policy properties + */ +export interface BackupPolicyDetails extends BaseResource { + /** + * Resource location + */ + location?: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * Name of backup policy + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name1?: string; + /** + * Azure lifecycle management + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Daily backups count to keep + */ + dailyBackupsToKeep?: number; + /** + * Weekly backups count to keep + */ + weeklyBackupsToKeep?: number; + /** + * Monthly backups count to keep + */ + monthlyBackupsToKeep?: number; + /** + * Yearly backups count to keep + */ + yearlyBackupsToKeep?: number; + /** + * Volumes using current backup policy + */ + volumesAssigned?: number; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; + /** + * A list of volumes assigned to this policy + */ + volumeBackups?: VolumeBackups[]; +} + +/** + * Backup policy Details for create and update + */ +export interface BackupPolicyPatch { + /** + * Resource location + */ + location?: string; + /** + * Name of backup policy + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Azure lifecycle management + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Daily backups count to keep + */ + dailyBackupsToKeep?: number; + /** + * Weekly backups count to keep + */ + weeklyBackupsToKeep?: number; + /** + * Monthly backups count to keep + */ + monthlyBackupsToKeep?: number; + /** + * Yearly backups count to keep + */ + yearlyBackupsToKeep?: number; + /** + * Volumes using current backup policy + */ + volumesAssigned?: number; + /** + * The property to decide policy is enabled or not + */ + enabled?: boolean; + /** + * A list of volumes assigned to this policy + */ + volumeBackups?: VolumeBackups[]; +} + +/** + * Vault information + */ +export interface Vault extends BaseResource { + /** + * Resource location + */ + location: string; + /** + * Resource Id + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * Resource name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * Resource type + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Vault Name + */ + vaultName?: string; } /** - * @interface - * List of capacity pool resources - * @extends Array + * Optional Parameters. + */ +export interface VolumesRevertOptionalParams extends msRest.RequestOptionsBase { + /** + * Resource id of the snapshot + */ + snapshotId?: string; +} + +/** + * Optional Parameters. + */ +export interface VolumesBreakReplicationOptionalParams extends msRest.RequestOptionsBase { + /** + * If replication is in status transferring and you want to force break the replication, set to + * true + */ + forceBreakReplication?: boolean; +} + +/** + * Optional Parameters. + */ +export interface VolumesAuthorizeReplicationOptionalParams extends msRest.RequestOptionsBase { + /** + * Resource id of the remote volume + */ + remoteVolumeResourceId?: string; +} + +/** + * Optional Parameters. + */ +export interface VolumesBeginRevertOptionalParams extends msRest.RequestOptionsBase { + /** + * Resource id of the snapshot + */ + snapshotId?: string; +} + +/** + * Optional Parameters. + */ +export interface VolumesBeginBreakReplicationOptionalParams extends msRest.RequestOptionsBase { + /** + * If replication is in status transferring and you want to force break the replication, set to + * true + */ + forceBreakReplication?: boolean; +} + +/** + * Optional Parameters. + */ +export interface VolumesBeginAuthorizeReplicationOptionalParams extends msRest.RequestOptionsBase { + /** + * Resource id of the remote volume + */ + remoteVolumeResourceId?: string; +} + +/** + * Optional Parameters. + */ +export interface BackupsCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * Label for backup + */ + label?: string; +} + +/** + * Optional Parameters. + */ +export interface BackupsUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * Resource tags + */ + tags?: { [propertyName: string]: string }; + /** + * Label for backup + */ + label?: string; +} + +/** + * Optional Parameters. + */ +export interface BackupsBeginCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * Label for backup + */ + label?: string; +} + +/** + * An interface representing AzureNetAppFilesManagementClientOptions. + */ +export interface AzureNetAppFilesManagementClientOptions extends AzureServiceClientOptions { + baseUri?: string; +} + +/** + * @interface + * Result of the request to list Cloud Volume operations. It contains a list of operations and a + * URL link to get the next set of results. + * @extends Array + */ +export interface OperationListResult extends Array { +} + +/** + * @interface + * List of NetApp account resources + * @extends Array + */ +export interface NetAppAccountList extends Array { +} + +/** + * @interface + * List of capacity pool resources + * @extends Array + */ +export interface CapacityPoolList extends Array { +} + +/** + * @interface + * List of volume resources + * @extends Array + */ +export interface VolumeList extends Array { +} + +/** + * @interface + * List of Snapshots + * @extends Array + */ +export interface SnapshotsList extends Array { +} + +/** + * @interface + * List of Snapshot Policies + * @extends Array + */ +export interface SnapshotPoliciesList extends Array { +} + +/** + * @interface + * List of Backups + * @extends Array + */ +export interface BackupsList extends Array { +} + +/** + * @interface + * List of Backup Policies + * @extends Array + */ +export interface BackupPoliciesList extends Array { +} + +/** + * @interface + * List of Vaults + * @extends Array + */ +export interface VaultList extends Array { +} + +/** + * Defines values for InAvailabilityReasonType. + * Possible values include: 'Invalid', 'AlreadyExists' + * @readonly + * @enum {string} + */ +export type InAvailabilityReasonType = 'Invalid' | 'AlreadyExists'; + +/** + * Defines values for CheckNameResourceTypes. + * Possible values include: 'Microsoft.NetApp/netAppAccounts', + * 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + * @readonly + * @enum {string} + */ +export type CheckNameResourceTypes = 'Microsoft.NetApp/netAppAccounts' | 'Microsoft.NetApp/netAppAccounts/capacityPools' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots'; + +/** + * Defines values for CheckQuotaNameResourceTypes. + * Possible values include: 'Microsoft.NetApp/netAppAccounts', + * 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + * @readonly + * @enum {string} + */ +export type CheckQuotaNameResourceTypes = 'Microsoft.NetApp/netAppAccounts' | 'Microsoft.NetApp/netAppAccounts/capacityPools' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots'; + +/** + * Defines values for ActiveDirectoryStatus. + * Possible values include: 'Created', 'InUse', 'Deleted', 'Error', 'Updating' + * @readonly + * @enum {string} + */ +export type ActiveDirectoryStatus = 'Created' | 'InUse' | 'Deleted' | 'Error' | 'Updating'; + +/** + * Defines values for ServiceLevel. + * Possible values include: 'Standard', 'Premium', 'Ultra' + * @readonly + * @enum {string} + */ +export type ServiceLevel = 'Standard' | 'Premium' | 'Ultra'; + +/** + * Defines values for QosType. + * Possible values include: 'Auto', 'Manual' + * @readonly + * @enum {string} + */ +export type QosType = 'Auto' | 'Manual'; + +/** + * Defines values for EndpointType. + * Possible values include: 'src', 'dst' + * @readonly + * @enum {string} + */ +export type EndpointType = 'src' | 'dst'; + +/** + * Defines values for ReplicationSchedule. + * Possible values include: '_10minutely', 'hourly', 'daily', 'weekly', 'monthly' + * @readonly + * @enum {string} + */ +export type ReplicationSchedule = '_10minutely' | 'hourly' | 'daily' | 'weekly' | 'monthly'; + +/** + * Defines values for SecurityStyle. + * Possible values include: 'ntfs', 'unix' + * @readonly + * @enum {string} + */ +export type SecurityStyle = 'ntfs' | 'unix'; + +/** + * Defines values for RelationshipStatus. + * Possible values include: 'Idle', 'Transferring' + * @readonly + * @enum {string} + */ +export type RelationshipStatus = 'Idle' | 'Transferring'; + +/** + * Defines values for MirrorState. + * Possible values include: 'Uninitialized', 'Mirrored', 'Broken' + * @readonly + * @enum {string} + */ +export type MirrorState = 'Uninitialized' | 'Mirrored' | 'Broken'; + +/** + * Contains response data for the list operation. + */ +export type OperationsListResponse = OperationListResult & { + /** + * 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: OperationListResult; + }; +}; + +/** + * Contains response data for the checkNameAvailability operation. + */ +export type NetAppResourceCheckNameAvailabilityResponse = CheckAvailabilityResponse & { + /** + * 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: CheckAvailabilityResponse; + }; +}; + +/** + * Contains response data for the checkFilePathAvailability operation. + */ +export type NetAppResourceCheckFilePathAvailabilityResponse = CheckAvailabilityResponse & { + /** + * 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: CheckAvailabilityResponse; + }; +}; + +/** + * Contains response data for the checkQuotaAvailability operation. + */ +export type NetAppResourceCheckQuotaAvailabilityResponse = CheckAvailabilityResponse & { + /** + * 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: CheckAvailabilityResponse; + }; +}; + +/** + * Contains response data for the list operation. + */ +export type AccountsListResponse = NetAppAccountList & { + /** + * 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: NetAppAccountList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type AccountsGetResponse = NetAppAccount & { + /** + * 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: NetAppAccount; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type AccountsCreateOrUpdateResponse = NetAppAccount & { + /** + * 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: NetAppAccount; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type AccountsUpdateResponse = NetAppAccount & { + /** + * 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: NetAppAccount; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type AccountsBeginCreateOrUpdateResponse = NetAppAccount & { + /** + * 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: NetAppAccount; + }; +}; + +/** + * Contains response data for the beginUpdate operation. + */ +export type AccountsBeginUpdateResponse = NetAppAccount & { + /** + * 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: NetAppAccount; + }; +}; + +/** + * Contains response data for the list operation. + */ +export type PoolsListResponse = CapacityPoolList & { + /** + * 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: CapacityPoolList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type PoolsGetResponse = CapacityPool & { + /** + * 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: CapacityPool; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type PoolsCreateOrUpdateResponse = CapacityPool & { + /** + * 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: CapacityPool; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type PoolsUpdateResponse = CapacityPool & { + /** + * 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: CapacityPool; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. */ -export interface CapacityPoolList extends Array { -} +export type PoolsBeginCreateOrUpdateResponse = CapacityPool & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * @interface - * List of volume resources - * @extends Array - */ -export interface VolumeList extends Array { -} + /** + * The response body as parsed JSON or XML + */ + parsedBody: CapacityPool; + }; +}; /** - * @interface - * List of Snapshots - * @extends Array + * Contains response data for the beginUpdate operation. */ -export interface SnapshotsList extends Array { -} +export type PoolsBeginUpdateResponse = CapacityPool & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for InAvailabilityReasonType. - * Possible values include: 'Invalid', 'AlreadyExists' - * @readonly - * @enum {string} - */ -export type InAvailabilityReasonType = 'Invalid' | 'AlreadyExists'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: CapacityPool; + }; +}; /** - * Defines values for CheckNameResourceTypes. - * Possible values include: 'Microsoft.NetApp/netAppAccounts', - * 'Microsoft.NetApp/netAppAccounts/capacityPools', - * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', - * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' - * @readonly - * @enum {string} + * Contains response data for the list operation. */ -export type CheckNameResourceTypes = 'Microsoft.NetApp/netAppAccounts' | 'Microsoft.NetApp/netAppAccounts/capacityPools' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots'; +export type VolumesListResponse = VolumeList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for ServiceLevel. - * Possible values include: 'Standard', 'Premium', 'Ultra' - * @readonly - * @enum {string} - */ -export type ServiceLevel = 'Standard' | 'Premium' | 'Ultra'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: VolumeList; + }; +}; /** - * Defines values for EndpointType. - * Possible values include: 'src', 'dst' - * @readonly - * @enum {string} + * Contains response data for the get operation. */ -export type EndpointType = 'src' | 'dst'; +export type VolumesGetResponse = Volume & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for ReplicationSchedule. - * Possible values include: '_10minutely', 'hourly', 'daily', 'weekly', 'monthly' - * @readonly - * @enum {string} - */ -export type ReplicationSchedule = '_10minutely' | 'hourly' | 'daily' | 'weekly' | 'monthly'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: Volume; + }; +}; /** - * Defines values for RelationshipStatus. - * Possible values include: 'Idle', 'Transferring' - * @readonly - * @enum {string} + * Contains response data for the createOrUpdate operation. */ -export type RelationshipStatus = 'Idle' | 'Transferring'; +export type VolumesCreateOrUpdateResponse = Volume & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for MirrorState. - * Possible values include: 'Uninitialized', 'Mirrored', 'Broken' - * @readonly - * @enum {string} - */ -export type MirrorState = 'Uninitialized' | 'Mirrored' | 'Broken'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: Volume; + }; +}; /** - * Contains response data for the list operation. + * Contains response data for the update operation. */ -export type OperationsListResponse = OperationListResult & { +export type VolumesUpdateResponse = Volume & { /** * The underlying HTTP response. */ @@ -990,14 +2192,14 @@ export type OperationsListResponse = OperationListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OperationListResult; + parsedBody: Volume; }; }; /** - * Contains response data for the checkNameAvailability operation. + * Contains response data for the replicationStatusMethod operation. */ -export type NetAppResourceCheckNameAvailabilityResponse = ResourceNameAvailability & { +export type VolumesReplicationStatusMethodResponse = ReplicationStatus & { /** * The underlying HTTP response. */ @@ -1010,14 +2212,14 @@ export type NetAppResourceCheckNameAvailabilityResponse = ResourceNameAvailabili /** * The response body as parsed JSON or XML */ - parsedBody: ResourceNameAvailability; + parsedBody: ReplicationStatus; }; }; /** - * Contains response data for the checkFilePathAvailability operation. + * Contains response data for the beginCreateOrUpdate operation. */ -export type NetAppResourceCheckFilePathAvailabilityResponse = ResourceNameAvailability & { +export type VolumesBeginCreateOrUpdateResponse = Volume & { /** * The underlying HTTP response. */ @@ -1030,14 +2232,14 @@ export type NetAppResourceCheckFilePathAvailabilityResponse = ResourceNameAvaila /** * The response body as parsed JSON or XML */ - parsedBody: ResourceNameAvailability; + parsedBody: Volume; }; }; /** - * Contains response data for the list operation. + * Contains response data for the beginUpdate operation. */ -export type AccountsListResponse = NetAppAccountList & { +export type VolumesBeginUpdateResponse = Volume & { /** * The underlying HTTP response. */ @@ -1050,14 +2252,14 @@ export type AccountsListResponse = NetAppAccountList & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccountList; + parsedBody: Volume; }; }; /** - * Contains response data for the get operation. + * Contains response data for the list operation. */ -export type AccountsGetResponse = NetAppAccount & { +export type SnapshotsListResponse = SnapshotsList & { /** * The underlying HTTP response. */ @@ -1070,14 +2272,14 @@ export type AccountsGetResponse = NetAppAccount & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccount; + parsedBody: SnapshotsList; }; }; /** - * Contains response data for the createOrUpdate operation. + * Contains response data for the get operation. */ -export type AccountsCreateOrUpdateResponse = NetAppAccount & { +export type SnapshotsGetResponse = Snapshot & { /** * The underlying HTTP response. */ @@ -1090,14 +2292,14 @@ export type AccountsCreateOrUpdateResponse = NetAppAccount & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccount; + parsedBody: Snapshot; }; }; /** - * Contains response data for the update operation. + * Contains response data for the create operation. */ -export type AccountsUpdateResponse = NetAppAccount & { +export type SnapshotsCreateResponse = Snapshot & { /** * The underlying HTTP response. */ @@ -1110,14 +2312,14 @@ export type AccountsUpdateResponse = NetAppAccount & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccount; + parsedBody: Snapshot; }; }; /** - * Contains response data for the beginCreateOrUpdate operation. + * Contains response data for the update operation. */ -export type AccountsBeginCreateOrUpdateResponse = NetAppAccount & { +export type SnapshotsUpdateResponse = Snapshot & { /** * The underlying HTTP response. */ @@ -1130,14 +2332,14 @@ export type AccountsBeginCreateOrUpdateResponse = NetAppAccount & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccount; + parsedBody: Snapshot; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the beginCreate operation. */ -export type AccountsBeginUpdateResponse = NetAppAccount & { +export type SnapshotsBeginCreateResponse = Snapshot & { /** * The underlying HTTP response. */ @@ -1150,14 +2352,14 @@ export type AccountsBeginUpdateResponse = NetAppAccount & { /** * The response body as parsed JSON or XML */ - parsedBody: NetAppAccount; + parsedBody: Snapshot; }; }; /** - * Contains response data for the list operation. + * Contains response data for the beginUpdate operation. */ -export type PoolsListResponse = CapacityPoolList & { +export type SnapshotsBeginUpdateResponse = Snapshot & { /** * The underlying HTTP response. */ @@ -1170,14 +2372,14 @@ export type PoolsListResponse = CapacityPoolList & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPoolList; + parsedBody: Snapshot; }; }; /** - * Contains response data for the get operation. + * Contains response data for the list operation. */ -export type PoolsGetResponse = CapacityPool & { +export type SnapshotPoliciesListResponse = SnapshotPoliciesList & { /** * The underlying HTTP response. */ @@ -1190,14 +2392,14 @@ export type PoolsGetResponse = CapacityPool & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPool; + parsedBody: SnapshotPoliciesList; }; }; /** - * Contains response data for the createOrUpdate operation. + * Contains response data for the get operation. */ -export type PoolsCreateOrUpdateResponse = CapacityPool & { +export type SnapshotPoliciesGetResponse = SnapshotPolicy & { /** * The underlying HTTP response. */ @@ -1210,14 +2412,14 @@ export type PoolsCreateOrUpdateResponse = CapacityPool & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPool; + parsedBody: SnapshotPolicy; }; }; /** - * Contains response data for the update operation. + * Contains response data for the create operation. */ -export type PoolsUpdateResponse = CapacityPool & { +export type SnapshotPoliciesCreateResponse = SnapshotPolicy & { /** * The underlying HTTP response. */ @@ -1230,14 +2432,14 @@ export type PoolsUpdateResponse = CapacityPool & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPool; + parsedBody: SnapshotPolicy; }; }; /** - * Contains response data for the beginCreateOrUpdate operation. + * Contains response data for the update operation. */ -export type PoolsBeginCreateOrUpdateResponse = CapacityPool & { +export type SnapshotPoliciesUpdateResponse = SnapshotPolicy & { /** * The underlying HTTP response. */ @@ -1250,14 +2452,14 @@ export type PoolsBeginCreateOrUpdateResponse = CapacityPool & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPool; + parsedBody: SnapshotPolicy; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the listVolumes operation. */ -export type PoolsBeginUpdateResponse = CapacityPool & { +export type SnapshotPoliciesListVolumesResponse = SnapshotPolicyVolumeList & { /** * The underlying HTTP response. */ @@ -1270,14 +2472,14 @@ export type PoolsBeginUpdateResponse = CapacityPool & { /** * The response body as parsed JSON or XML */ - parsedBody: CapacityPool; + parsedBody: SnapshotPolicyVolumeList; }; }; /** * Contains response data for the list operation. */ -export type VolumesListResponse = VolumeList & { +export type AccountBackupsListResponse = BackupsList & { /** * The underlying HTTP response. */ @@ -1290,14 +2492,14 @@ export type VolumesListResponse = VolumeList & { /** * The response body as parsed JSON or XML */ - parsedBody: VolumeList; + parsedBody: BackupsList; }; }; /** * Contains response data for the get operation. */ -export type VolumesGetResponse = Volume & { +export type AccountBackupsGetResponse = Backup & { /** * The underlying HTTP response. */ @@ -1310,14 +2512,14 @@ export type VolumesGetResponse = Volume & { /** * The response body as parsed JSON or XML */ - parsedBody: Volume; + parsedBody: Backup; }; }; /** - * Contains response data for the createOrUpdate operation. + * Contains response data for the list operation. */ -export type VolumesCreateOrUpdateResponse = Volume & { +export type BackupsListResponse = BackupsList & { /** * The underlying HTTP response. */ @@ -1330,14 +2532,14 @@ export type VolumesCreateOrUpdateResponse = Volume & { /** * The response body as parsed JSON or XML */ - parsedBody: Volume; + parsedBody: BackupsList; }; }; /** - * Contains response data for the update operation. + * Contains response data for the get operation. */ -export type VolumesUpdateResponse = Volume & { +export type BackupsGetResponse = Backup & { /** * The underlying HTTP response. */ @@ -1350,14 +2552,14 @@ export type VolumesUpdateResponse = Volume & { /** * The response body as parsed JSON or XML */ - parsedBody: Volume; + parsedBody: Backup; }; }; /** - * Contains response data for the replicationStatusMethod operation. + * Contains response data for the create operation. */ -export type VolumesReplicationStatusMethodResponse = ReplicationStatus & { +export type BackupsCreateResponse = Backup & { /** * The underlying HTTP response. */ @@ -1370,14 +2572,14 @@ export type VolumesReplicationStatusMethodResponse = ReplicationStatus & { /** * The response body as parsed JSON or XML */ - parsedBody: ReplicationStatus; + parsedBody: Backup; }; }; /** - * Contains response data for the beginCreateOrUpdate operation. + * Contains response data for the update operation. */ -export type VolumesBeginCreateOrUpdateResponse = Volume & { +export type BackupsUpdateResponse = Backup & { /** * The underlying HTTP response. */ @@ -1390,14 +2592,14 @@ export type VolumesBeginCreateOrUpdateResponse = Volume & { /** * The response body as parsed JSON or XML */ - parsedBody: Volume; + parsedBody: Backup; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the beginCreate operation. */ -export type VolumesBeginUpdateResponse = Volume & { +export type BackupsBeginCreateResponse = Backup & { /** * The underlying HTTP response. */ @@ -1410,14 +2612,14 @@ export type VolumesBeginUpdateResponse = Volume & { /** * The response body as parsed JSON or XML */ - parsedBody: Volume; + parsedBody: Backup; }; }; /** * Contains response data for the list operation. */ -export type SnapshotsListResponse = SnapshotsList & { +export type BackupPoliciesListResponse = BackupPoliciesList & { /** * The underlying HTTP response. */ @@ -1430,14 +2632,14 @@ export type SnapshotsListResponse = SnapshotsList & { /** * The response body as parsed JSON or XML */ - parsedBody: SnapshotsList; + parsedBody: BackupPoliciesList; }; }; /** * Contains response data for the get operation. */ -export type SnapshotsGetResponse = Snapshot & { +export type BackupPoliciesGetResponse = BackupPolicy & { /** * The underlying HTTP response. */ @@ -1450,14 +2652,14 @@ export type SnapshotsGetResponse = Snapshot & { /** * The response body as parsed JSON or XML */ - parsedBody: Snapshot; + parsedBody: BackupPolicy; }; }; /** * Contains response data for the create operation. */ -export type SnapshotsCreateResponse = Snapshot & { +export type BackupPoliciesCreateResponse = BackupPolicy & { /** * The underlying HTTP response. */ @@ -1470,14 +2672,14 @@ export type SnapshotsCreateResponse = Snapshot & { /** * The response body as parsed JSON or XML */ - parsedBody: Snapshot; + parsedBody: BackupPolicy; }; }; /** * Contains response data for the update operation. */ -export type SnapshotsUpdateResponse = Snapshot & { +export type BackupPoliciesUpdateResponse = BackupPolicy & { /** * The underlying HTTP response. */ @@ -1490,14 +2692,14 @@ export type SnapshotsUpdateResponse = Snapshot & { /** * The response body as parsed JSON or XML */ - parsedBody: Snapshot; + parsedBody: BackupPolicy; }; }; /** * Contains response data for the beginCreate operation. */ -export type SnapshotsBeginCreateResponse = Snapshot & { +export type BackupPoliciesBeginCreateResponse = BackupPolicy & { /** * The underlying HTTP response. */ @@ -1510,14 +2712,14 @@ export type SnapshotsBeginCreateResponse = Snapshot & { /** * The response body as parsed JSON or XML */ - parsedBody: Snapshot; + parsedBody: BackupPolicy; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the list operation. */ -export type SnapshotsBeginUpdateResponse = Snapshot & { +export type VaultsListResponse = VaultList & { /** * The underlying HTTP response. */ @@ -1530,6 +2732,6 @@ export type SnapshotsBeginUpdateResponse = Snapshot & { /** * The response body as parsed JSON or XML */ - parsedBody: Snapshot; + parsedBody: VaultList; }; }; diff --git a/sdk/netapp/arm-netapp/src/models/mappers.ts b/sdk/netapp/arm-netapp/src/models/mappers.ts index 05077ee421b7..b6b0550e71f3 100644 --- a/sdk/netapp/arm-netapp/src/models/mappers.ts +++ b/sdk/netapp/arm-netapp/src/models/mappers.ts @@ -196,11 +196,11 @@ export const Operation: msRest.CompositeMapper = { } }; -export const ResourceNameAvailability: msRest.CompositeMapper = { - serializedName: "ResourceNameAvailability", +export const CheckAvailabilityResponse: msRest.CompositeMapper = { + serializedName: "CheckAvailabilityResponse", type: { name: "Composite", - className: "ResourceNameAvailability", + className: "CheckAvailabilityResponse", modelProperties: { isAvailable: { serializedName: "isAvailable", @@ -255,6 +255,37 @@ export const ResourceNameAvailabilityRequest: msRest.CompositeMapper = { } }; +export const QuotaAvailabilityRequest: msRest.CompositeMapper = { + serializedName: "QuotaAvailabilityRequest", + type: { + name: "Composite", + className: "QuotaAvailabilityRequest", + modelProperties: { + name: { + required: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + required: true, + serializedName: "type", + type: { + name: "String" + } + }, + resourceGroup: { + required: true, + serializedName: "resourceGroup", + type: { + name: "String" + } + } + } + } +}; + export const ActiveDirectory: msRest.CompositeMapper = { serializedName: "activeDirectory", type: { @@ -287,16 +318,27 @@ export const ActiveDirectory: msRest.CompositeMapper = { }, dns: { serializedName: "dns", + constraints: { + Pattern: /^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)((, ?)(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))*$/ + }, type: { name: "String" } }, status: { + readOnly: true, serializedName: "status", type: { name: "String" } }, + statusDetails: { + readOnly: true, + serializedName: "statusDetails", + type: { + name: "String" + } + }, smbServerName: { serializedName: "smbServerName", type: { @@ -325,6 +367,35 @@ export const ActiveDirectory: msRest.CompositeMapper = { } } } + }, + kdcIP: { + serializedName: "kdcIP", + constraints: { + Pattern: /^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)((, ?)(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?))*$/ + }, + type: { + name: "String" + } + }, + adName: { + serializedName: "adName", + constraints: { + MaxLength: 64, + MinLength: 1 + }, + type: { + name: "String" + } + }, + serverRootCACertificate: { + serializedName: "serverRootCACertificate", + constraints: { + MaxLength: 10240, + MinLength: 1 + }, + type: { + name: "String" + } } } } @@ -547,6 +618,33 @@ export const CapacityPool: msRest.CompositeMapper = { type: { name: "String" } + }, + totalThroughputMibps: { + readOnly: true, + serializedName: "properties.totalThroughputMibps", + constraints: { + MultipleOf: 0.001 + }, + type: { + name: "Number" + } + }, + utilizedThroughputMibps: { + readOnly: true, + serializedName: "properties.utilizedThroughputMibps", + constraints: { + MultipleOf: 0.001 + }, + type: { + name: "Number" + } + }, + qosType: { + serializedName: "properties.qosType", + defaultValue: 'Auto', + type: { + name: "String" + } } } } @@ -607,9 +705,9 @@ export const CapacityPoolPatch: msRest.CompositeMapper = { name: "Number" } }, - serviceLevel: { - serializedName: "properties.serviceLevel", - defaultValue: 'Premium', + qosType: { + serializedName: "properties.qosType", + defaultValue: 'Auto', type: { name: "String" } @@ -642,6 +740,48 @@ export const ExportPolicyRule: msRest.CompositeMapper = { name: "Boolean" } }, + kerberos5ReadOnly: { + serializedName: "kerberos5ReadOnly", + defaultValue: false, + type: { + name: "Boolean" + } + }, + kerberos5ReadWrite: { + serializedName: "kerberos5ReadWrite", + defaultValue: false, + type: { + name: "Boolean" + } + }, + kerberos5iReadOnly: { + serializedName: "kerberos5iReadOnly", + defaultValue: false, + type: { + name: "Boolean" + } + }, + kerberos5iReadWrite: { + serializedName: "kerberos5iReadWrite", + defaultValue: false, + type: { + name: "Boolean" + } + }, + kerberos5pReadOnly: { + serializedName: "kerberos5pReadOnly", + defaultValue: false, + type: { + name: "Boolean" + } + }, + kerberos5pReadWrite: { + serializedName: "kerberos5pReadWrite", + defaultValue: false, + type: { + name: "Boolean" + } + }, cifs: { serializedName: "cifs", type: { @@ -665,6 +805,13 @@ export const ExportPolicyRule: msRest.CompositeMapper = { type: { name: "String" } + }, + hasRootAccess: { + serializedName: "hasRootAccess", + defaultValue: true, + type: { + name: "Boolean" + } } } } @@ -729,40 +876,44 @@ export const MountTargetProperties: msRest.CompositeMapper = { name: "String" } }, - subnet: { - serializedName: "subnet", - type: { - name: "String" - } - }, - startIp: { - serializedName: "startIp", + smbServerFqdn: { + serializedName: "smbServerFqdn", type: { name: "String" } - }, - endIp: { - serializedName: "endIp", + } + } + } +}; + +export const VolumeBackupProperties: msRest.CompositeMapper = { + serializedName: "volumeBackupProperties", + type: { + name: "Composite", + className: "VolumeBackupProperties", + modelProperties: { + backupPolicyId: { + serializedName: "backupPolicyId", type: { name: "String" } }, - gateway: { - serializedName: "gateway", + policyEnforced: { + serializedName: "policyEnforced", type: { - name: "String" + name: "Boolean" } }, - netmask: { - serializedName: "netmask", + vaultId: { + serializedName: "vaultId", type: { name: "String" } }, - smbServerFqdn: { - serializedName: "smbServerFqdn", + backupEnabled: { + serializedName: "backupEnabled", type: { - name: "String" + name: "Boolean" } } } @@ -833,6 +984,13 @@ export const VolumePropertiesDataProtection: msRest.CompositeMapper = { name: "Composite", className: "VolumePropertiesDataProtection", modelProperties: { + backup: { + serializedName: "backup", + type: { + name: "Composite", + className: "VolumeBackupProperties" + } + }, replication: { serializedName: "replication", type: { @@ -975,6 +1133,17 @@ export const Volume: msRest.CompositeMapper = { name: "String" } }, + backupId: { + serializedName: "properties.backupId", + constraints: { + MaxLength: 36, + MinLength: 36, + Pattern: /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}|(\\?([^\/]*[\/])*)([^\/]+)$/ + }, + type: { + name: "String" + } + }, baremetalTenantId: { readOnly: true, serializedName: "properties.baremetalTenantId", @@ -1030,6 +1199,30 @@ export const Volume: msRest.CompositeMapper = { type: { name: "Boolean" } + }, + kerberosEnabled: { + serializedName: "properties.kerberosEnabled", + defaultValue: false, + type: { + name: "Boolean" + } + }, + securityStyle: { + serializedName: "properties.securityStyle", + type: { + name: "String" + } + }, + throughputMibps: { + serializedName: "properties.throughputMibps", + constraints: { + InclusiveMaximum: 4500, + InclusiveMinimum: 1, + MultipleOf: 0.001 + }, + type: { + name: "Number" + } } } } @@ -1097,6 +1290,23 @@ export const VolumePatchPropertiesExportPolicy: msRest.CompositeMapper = { } }; +export const VolumePatchPropertiesDataProtection: msRest.CompositeMapper = { + serializedName: "volumePatchProperties_dataProtection", + type: { + name: "Composite", + className: "VolumePatchPropertiesDataProtection", + modelProperties: { + backup: { + serializedName: "backup", + type: { + name: "Composite", + className: "VolumeBackupProperties" + } + } + } + } +}; + export const VolumePatch: msRest.CompositeMapper = { serializedName: "volumePatch", type: { @@ -1165,6 +1375,24 @@ export const VolumePatch: msRest.CompositeMapper = { name: "Composite", className: "VolumePatchPropertiesExportPolicy" } + }, + throughputMibps: { + serializedName: "properties.throughputMibps", + constraints: { + InclusiveMaximum: 4500, + InclusiveMinimum: 1, + MultipleOf: 0.001 + }, + type: { + name: "Number" + } + }, + dataProtection: { + serializedName: "properties.dataProtection", + type: { + name: "Composite", + className: "VolumePatchPropertiesDataProtection" + } } } } @@ -1246,36 +1474,6 @@ export const MountTarget: msRest.CompositeMapper = { name: "String" } }, - subnet: { - serializedName: "properties.subnet", - type: { - name: "String" - } - }, - startIp: { - serializedName: "properties.startIp", - type: { - name: "String" - } - }, - endIp: { - serializedName: "properties.endIp", - type: { - name: "String" - } - }, - gateway: { - serializedName: "properties.gateway", - type: { - name: "String" - } - }, - netmask: { - serializedName: "properties.netmask", - type: { - name: "String" - } - }, smbServerFqdn: { serializedName: "properties.smbServerFqdn", type: { @@ -1350,52 +1548,981 @@ export const Snapshot: msRest.CompositeMapper = { } }; -export const VolumeRevert: msRest.CompositeMapper = { - serializedName: "volumeRevert", +export const SnapshotPolicy: msRest.CompositeMapper = { + serializedName: "snapshotPolicy", type: { name: "Composite", - className: "VolumeRevert", + className: "SnapshotPolicy", modelProperties: { - snapshotId: { - serializedName: "snapshotId", + location: { + required: true, + serializedName: "location", type: { name: "String" } - } - } - } -}; - -export const AuthorizeRequest: msRest.CompositeMapper = { - serializedName: "authorizeRequest", - type: { - name: "Composite", - className: "AuthorizeRequest", - modelProperties: { - remoteVolumeResourceId: { - serializedName: "remoteVolumeResourceId", + }, + id: { + readOnly: true, + serializedName: "id", type: { name: "String" } - } - } - } -}; - -export const OperationListResult: msRest.CompositeMapper = { - serializedName: "OperationListResult", - type: { - name: "Composite", - className: "OperationListResult", - modelProperties: { - value: { - serializedName: "", + }, + name: { + readOnly: true, + serializedName: "name", type: { - name: "Sequence", - element: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { - name: "Composite", - className: "Operation" + name: "String" + } + } + } + }, + hourlySchedule: { + serializedName: "properties.hourlySchedule", + type: { + name: "Object" + } + }, + dailySchedule: { + serializedName: "properties.dailySchedule", + type: { + name: "Object" + } + }, + weeklySchedule: { + serializedName: "properties.weeklySchedule", + type: { + name: "Object" + } + }, + monthlySchedule: { + serializedName: "properties.monthlySchedule", + type: { + name: "Object" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + } + } + } +}; + +export const SnapshotPolicyDetails: msRest.CompositeMapper = { + serializedName: "snapshotPolicyDetails", + type: { + name: "Composite", + className: "SnapshotPolicyDetails", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + hourlySchedule: { + serializedName: "properties.hourlySchedule", + type: { + name: "Object" + } + }, + dailySchedule: { + serializedName: "properties.dailySchedule", + type: { + name: "Object" + } + }, + weeklySchedule: { + serializedName: "properties.weeklySchedule", + type: { + name: "Object" + } + }, + monthlySchedule: { + serializedName: "properties.monthlySchedule", + type: { + name: "Object" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + } + } + } +}; + +export const SnapshotPolicyPatch: msRest.CompositeMapper = { + serializedName: "snapshotPolicyPatch", + type: { + name: "Composite", + className: "SnapshotPolicyPatch", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + hourlySchedule: { + serializedName: "properties.hourlySchedule", + type: { + name: "Object" + } + }, + dailySchedule: { + serializedName: "properties.dailySchedule", + type: { + name: "Object" + } + }, + weeklySchedule: { + serializedName: "properties.weeklySchedule", + type: { + name: "Object" + } + }, + monthlySchedule: { + serializedName: "properties.monthlySchedule", + type: { + name: "Object" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + } + } + } +}; + +export const SnapshotPolicyVolumeList: msRest.CompositeMapper = { + serializedName: "snapshotPolicyVolumeList", + type: { + name: "Composite", + className: "SnapshotPolicyVolumeList", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Object" + } + } + } + } + } + } +}; + +export const HourlySchedule: msRest.CompositeMapper = { + serializedName: "hourlySchedule", + type: { + name: "Composite", + className: "HourlySchedule", + modelProperties: { + snapshotsToKeep: { + serializedName: "snapshotsToKeep", + type: { + name: "Number" + } + }, + minute: { + serializedName: "minute", + type: { + name: "Number" + } + }, + usedBytes: { + serializedName: "usedBytes", + type: { + name: "Number" + } + } + } + } +}; + +export const DailySchedule: msRest.CompositeMapper = { + serializedName: "dailySchedule", + type: { + name: "Composite", + className: "DailySchedule", + modelProperties: { + snapshotsToKeep: { + serializedName: "snapshotsToKeep", + type: { + name: "Number" + } + }, + hour: { + serializedName: "hour", + type: { + name: "Number" + } + }, + minute: { + serializedName: "minute", + type: { + name: "Number" + } + }, + usedBytes: { + serializedName: "usedBytes", + type: { + name: "Number" + } + } + } + } +}; + +export const WeeklySchedule: msRest.CompositeMapper = { + serializedName: "weeklySchedule", + type: { + name: "Composite", + className: "WeeklySchedule", + modelProperties: { + snapshotsToKeep: { + serializedName: "snapshotsToKeep", + type: { + name: "Number" + } + }, + day: { + serializedName: "day", + type: { + name: "String" + } + }, + hour: { + serializedName: "hour", + type: { + name: "Number" + } + }, + minute: { + serializedName: "minute", + type: { + name: "Number" + } + }, + usedBytes: { + serializedName: "usedBytes", + type: { + name: "Number" + } + } + } + } +}; + +export const MonthlySchedule: msRest.CompositeMapper = { + serializedName: "monthlySchedule", + type: { + name: "Composite", + className: "MonthlySchedule", + modelProperties: { + snapshotsToKeep: { + serializedName: "snapshotsToKeep", + type: { + name: "Number" + } + }, + daysOfMonth: { + serializedName: "daysOfMonth", + type: { + name: "String" + } + }, + hour: { + serializedName: "hour", + type: { + name: "Number" + } + }, + minute: { + serializedName: "minute", + type: { + name: "Number" + } + }, + usedBytes: { + serializedName: "usedBytes", + type: { + name: "Number" + } + } + } + } +}; + +export const VolumeRevert: msRest.CompositeMapper = { + serializedName: "volumeRevert", + type: { + name: "Composite", + className: "VolumeRevert", + modelProperties: { + snapshotId: { + serializedName: "snapshotId", + type: { + name: "String" + } + } + } + } +}; + +export const AuthorizeRequest: msRest.CompositeMapper = { + serializedName: "authorizeRequest", + type: { + name: "Composite", + className: "AuthorizeRequest", + modelProperties: { + remoteVolumeResourceId: { + serializedName: "remoteVolumeResourceId", + type: { + name: "String" + } + } + } + } +}; + +export const BreakReplicationRequest: msRest.CompositeMapper = { + serializedName: "breakReplicationRequest", + type: { + name: "Composite", + className: "BreakReplicationRequest", + modelProperties: { + forceBreakReplication: { + serializedName: "forceBreakReplication", + type: { + name: "Boolean" + } + } + } + } +}; + +export const PoolChangeRequest: msRest.CompositeMapper = { + serializedName: "poolChangeRequest", + type: { + name: "Composite", + className: "PoolChangeRequest", + modelProperties: { + newPoolResourceId: { + required: true, + serializedName: "newPoolResourceId", + type: { + name: "String" + } + } + } + } +}; + +export const Backup: msRest.CompositeMapper = { + serializedName: "backup", + type: { + name: "Composite", + className: "Backup", + modelProperties: { + location: { + required: true, + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + creationDate: { + readOnly: true, + serializedName: "properties.creationDate", + type: { + name: "DateTime" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + size: { + readOnly: true, + serializedName: "properties.size", + type: { + name: "Number" + } + }, + label: { + serializedName: "properties.label", + type: { + name: "String" + } + }, + backupType: { + readOnly: true, + serializedName: "properties.backupType", + type: { + name: "String" + } + } + } + } +}; + +export const BackupPatch: msRest.CompositeMapper = { + serializedName: "backupPatch", + type: { + name: "Composite", + className: "BackupPatch", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + creationDate: { + readOnly: true, + serializedName: "properties.creationDate", + type: { + name: "DateTime" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + size: { + readOnly: true, + serializedName: "properties.size", + type: { + name: "Number" + } + }, + label: { + serializedName: "properties.label", + type: { + name: "String" + } + }, + backupType: { + readOnly: true, + serializedName: "properties.backupType", + type: { + name: "String" + } + } + } + } +}; + +export const VolumeBackups: msRest.CompositeMapper = { + serializedName: "volumeBackups", + type: { + name: "Composite", + className: "VolumeBackups", + modelProperties: { + volumeName: { + serializedName: "volumeName", + type: { + name: "String" + } + }, + backupsCount: { + serializedName: "backupsCount", + type: { + name: "Number" + } + }, + policyEnabled: { + serializedName: "policyEnabled", + type: { + name: "Boolean" + } + } + } + } +}; + +export const BackupPolicy: msRest.CompositeMapper = { + serializedName: "backupPolicy", + type: { + name: "Composite", + className: "BackupPolicy", + modelProperties: { + location: { + required: true, + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + name1: { + readOnly: true, + serializedName: "properties.name", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + dailyBackupsToKeep: { + serializedName: "properties.dailyBackupsToKeep", + type: { + name: "Number" + } + }, + weeklyBackupsToKeep: { + serializedName: "properties.weeklyBackupsToKeep", + type: { + name: "Number" + } + }, + monthlyBackupsToKeep: { + serializedName: "properties.monthlyBackupsToKeep", + type: { + name: "Number" + } + }, + yearlyBackupsToKeep: { + serializedName: "properties.yearlyBackupsToKeep", + type: { + name: "Number" + } + }, + volumesAssigned: { + serializedName: "properties.volumesAssigned", + type: { + name: "Number" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + }, + volumeBackups: { + serializedName: "properties.volumeBackups", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "VolumeBackups" + } + } + } + } + } + } +}; + +export const BackupPolicyDetails: msRest.CompositeMapper = { + serializedName: "backupPolicyDetails", + type: { + name: "Composite", + className: "BackupPolicyDetails", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + name1: { + readOnly: true, + serializedName: "properties.name", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + dailyBackupsToKeep: { + serializedName: "properties.dailyBackupsToKeep", + type: { + name: "Number" + } + }, + weeklyBackupsToKeep: { + serializedName: "properties.weeklyBackupsToKeep", + type: { + name: "Number" + } + }, + monthlyBackupsToKeep: { + serializedName: "properties.monthlyBackupsToKeep", + type: { + name: "Number" + } + }, + yearlyBackupsToKeep: { + serializedName: "properties.yearlyBackupsToKeep", + type: { + name: "Number" + } + }, + volumesAssigned: { + serializedName: "properties.volumesAssigned", + type: { + name: "Number" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + }, + volumeBackups: { + serializedName: "properties.volumeBackups", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "VolumeBackups" + } + } + } + } + } + } +}; + +export const BackupPolicyPatch: msRest.CompositeMapper = { + serializedName: "backupPolicyPatch", + type: { + name: "Composite", + className: "BackupPolicyPatch", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "properties.name", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + dailyBackupsToKeep: { + serializedName: "properties.dailyBackupsToKeep", + type: { + name: "Number" + } + }, + weeklyBackupsToKeep: { + serializedName: "properties.weeklyBackupsToKeep", + type: { + name: "Number" + } + }, + monthlyBackupsToKeep: { + serializedName: "properties.monthlyBackupsToKeep", + type: { + name: "Number" + } + }, + yearlyBackupsToKeep: { + serializedName: "properties.yearlyBackupsToKeep", + type: { + name: "Number" + } + }, + volumesAssigned: { + serializedName: "properties.volumesAssigned", + type: { + name: "Number" + } + }, + enabled: { + serializedName: "properties.enabled", + type: { + name: "Boolean" + } + }, + volumeBackups: { + serializedName: "properties.volumeBackups", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "VolumeBackups" + } + } + } + } + } + } +}; + +export const Vault: msRest.CompositeMapper = { + serializedName: "vault", + type: { + name: "Composite", + className: "Vault", + modelProperties: { + location: { + required: true, + serializedName: "location", + type: { + name: "String" + } + }, + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + vaultName: { + serializedName: "properties.vaultName", + type: { + name: "String" + } + } + } + } +}; + +export const OperationListResult: msRest.CompositeMapper = { + serializedName: "OperationListResult", + type: { + name: "Composite", + className: "OperationListResult", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Operation" } } } @@ -1491,3 +2618,91 @@ export const SnapshotsList: msRest.CompositeMapper = { } } }; + +export const SnapshotPoliciesList: msRest.CompositeMapper = { + serializedName: "snapshotPoliciesList", + type: { + name: "Composite", + className: "SnapshotPoliciesList", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SnapshotPolicy" + } + } + } + } + } + } +}; + +export const BackupsList: msRest.CompositeMapper = { + serializedName: "backupsList", + type: { + name: "Composite", + className: "BackupsList", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Backup" + } + } + } + } + } + } +}; + +export const BackupPoliciesList: msRest.CompositeMapper = { + serializedName: "backupPoliciesList", + type: { + name: "Composite", + className: "BackupPoliciesList", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "BackupPolicy" + } + } + } + } + } + } +}; + +export const VaultList: msRest.CompositeMapper = { + serializedName: "vaultList", + type: { + name: "Composite", + className: "VaultList", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Vault" + } + } + } + } + } + } +}; diff --git a/sdk/netapp/arm-netapp/src/models/netAppResourceMappers.ts b/sdk/netapp/arm-netapp/src/models/netAppResourceMappers.ts index ddaa64ad7353..871c6134bb70 100644 --- a/sdk/netapp/arm-netapp/src/models/netAppResourceMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/netAppResourceMappers.ts @@ -7,7 +7,8 @@ */ export { + CheckAvailabilityResponse, CloudError, - ResourceNameAvailability, + QuotaAvailabilityRequest, ResourceNameAvailabilityRequest } from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/parameters.ts b/sdk/netapp/arm-netapp/src/models/parameters.ts index 207058680667..c92d033734f1 100644 --- a/sdk/netapp/arm-netapp/src/models/parameters.ts +++ b/sdk/netapp/arm-netapp/src/models/parameters.ts @@ -35,7 +35,27 @@ export const apiVersion: msRest.OperationQueryParameter = { mapper: { required: true, serializedName: "api-version", - defaultValue: '2020-02-01', + defaultValue: '2020-06-01', + type: { + name: "String" + } + } +}; +export const backupName: msRest.OperationURLParameter = { + parameterPath: "backupName", + mapper: { + required: true, + serializedName: "backupName", + type: { + name: "String" + } + } +}; +export const backupPolicyName: msRest.OperationURLParameter = { + parameterPath: "backupPolicyName", + mapper: { + required: true, + serializedName: "backupPolicyName", type: { name: "String" } @@ -91,6 +111,16 @@ export const snapshotName: msRest.OperationURLParameter = { } } }; +export const snapshotPolicyName: msRest.OperationURLParameter = { + parameterPath: "snapshotPolicyName", + mapper: { + required: true, + serializedName: "snapshotPolicyName", + type: { + name: "String" + } + } +}; export const subscriptionId: msRest.OperationURLParameter = { parameterPath: "subscriptionId", mapper: { diff --git a/sdk/netapp/arm-netapp/src/models/poolsMappers.ts b/sdk/netapp/arm-netapp/src/models/poolsMappers.ts index f82680a824b8..f71fd3dd7424 100644 --- a/sdk/netapp/arm-netapp/src/models/poolsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/poolsMappers.ts @@ -8,6 +8,10 @@ export { ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, BaseResource, CapacityPool, CapacityPoolList, @@ -19,8 +23,13 @@ export { NetAppAccountPatch, ReplicationObject, Snapshot, + SnapshotPolicy, + Vault, Volume, + VolumeBackupProperties, + VolumeBackups, VolumePatch, + VolumePatchPropertiesDataProtection, VolumePatchPropertiesExportPolicy, VolumePropertiesDataProtection, VolumePropertiesExportPolicy, diff --git a/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts b/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts new file mode 100644 index 000000000000..c6aacdce9aa4 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts @@ -0,0 +1,39 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + ExportPolicyRule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ReplicationObject, + Snapshot, + SnapshotPoliciesList, + SnapshotPolicy, + SnapshotPolicyPatch, + SnapshotPolicyVolumeList, + Vault, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts b/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts index 9d43e596db18..b966952e7494 100644 --- a/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts @@ -8,6 +8,10 @@ export { ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, BaseResource, CapacityPool, CapacityPoolPatch, @@ -18,9 +22,14 @@ export { NetAppAccountPatch, ReplicationObject, Snapshot, + SnapshotPolicy, SnapshotsList, + Vault, Volume, + VolumeBackupProperties, + VolumeBackups, VolumePatch, + VolumePatchPropertiesDataProtection, VolumePatchPropertiesExportPolicy, VolumePropertiesDataProtection, VolumePropertiesExportPolicy, diff --git a/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts b/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts new file mode 100644 index 000000000000..542bfa060e32 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts @@ -0,0 +1,37 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + ActiveDirectory, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + ExportPolicyRule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ReplicationObject, + Snapshot, + SnapshotPolicy, + Vault, + VaultList, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/volumesMappers.ts b/sdk/netapp/arm-netapp/src/models/volumesMappers.ts index a5075cf0069b..db8be94a5949 100644 --- a/sdk/netapp/arm-netapp/src/models/volumesMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/volumesMappers.ts @@ -9,7 +9,12 @@ export { ActiveDirectory, AuthorizeRequest, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, BaseResource, + BreakReplicationRequest, CapacityPool, CapacityPoolPatch, CloudError, @@ -17,12 +22,18 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + PoolChangeRequest, ReplicationObject, ReplicationStatus, Snapshot, + SnapshotPolicy, + Vault, Volume, + VolumeBackupProperties, + VolumeBackups, VolumeList, VolumePatch, + VolumePatchPropertiesDataProtection, VolumePatchPropertiesExportPolicy, VolumePropertiesDataProtection, VolumePropertiesExportPolicy, diff --git a/sdk/netapp/arm-netapp/src/operations/accountBackups.ts b/sdk/netapp/arm-netapp/src/operations/accountBackups.ts new file mode 100644 index 000000000000..fd9e8808d4ea --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/accountBackups.ts @@ -0,0 +1,213 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * 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/accountBackupsMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a AccountBackups. */ +export class AccountBackups { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a AccountBackups. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * List all Backups for a Netapp Account + * @summary List Backups for a Netapp Account + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get Backup for a Netapp Account + * @summary Get Backup for a Netapp Account + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, accountName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupName The name of the backup + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, backupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupName The name of the backup + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, backupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, accountName: string, backupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + backupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Delete Backup for a Netapp Account + * @summary Delete Backup for a Netapp Account + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, accountName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,accountName,backupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Delete Backup for a Netapp Account + * @summary Delete Backup for a Netapp Account + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, accountName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + backupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/accountBackups", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BackupsList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/accountBackups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Backup + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/accountBackups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/netapp/arm-netapp/src/operations/backupPolicies.ts b/sdk/netapp/arm-netapp/src/operations/backupPolicies.ts new file mode 100644 index 000000000000..08a9ac7bc63e --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/backupPolicies.ts @@ -0,0 +1,362 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * 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/backupPoliciesMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a BackupPolicies. */ +export class BackupPolicies { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a BackupPolicies. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * List backup policies for Netapp Account + * @summary List backup policies + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get a particular backup Policy + * @summary Get a backup Policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, accountName: string, backupPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, backupPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, backupPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, accountName: string, backupPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + backupPolicyName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Create a backup policy for Netapp Account + * @summary Create a backup policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param body Backup policy object supplied in the body of the operation. + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicy, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,accountName,backupPolicyName,body,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Patch a backup policy for Netapp Account + * @summary Patch a backup policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param body Backup policy object supplied in the body of the operation. + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicyPatch, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param body Backup policy object supplied in the body of the operation. + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicyPatch, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param body Backup policy object supplied in the body of the operation. + * @param options The optional parameters + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicyPatch, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + update(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicyPatch, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + backupPolicyName, + body, + options + }, + updateOperationSpec, + callback) as Promise; + } + + /** + * Delete backup policy + * @summary Delete a backup policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, accountName: string, backupPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,accountName,backupPolicyName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Create a backup policy for Netapp Account + * @summary Create a backup policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param body Backup policy object supplied in the body of the operation. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, accountName: string, backupPolicyName: string, body: Models.BackupPolicy, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + backupPolicyName, + body, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Delete backup policy + * @summary Delete a backup policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param backupPolicyName Backup policy Name which uniquely identify backup policy. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, accountName: string, backupPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + backupPolicyName, + options + }, + beginDeleteMethodOperationSpec, + options); + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/backupPolicies", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BackupPoliciesList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/backupPolicies/{backupPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BackupPolicy + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const updateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/backupPolicies/{backupPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "body", + mapper: { + ...Mappers.BackupPolicyPatch, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.BackupPolicy + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/backupPolicies/{backupPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "body", + mapper: { + ...Mappers.BackupPolicy, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.BackupPolicy + }, + 201: { + bodyMapper: Mappers.BackupPolicy + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/backupPolicies/{backupPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.backupPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/netapp/arm-netapp/src/operations/backups.ts b/sdk/netapp/arm-netapp/src/operations/backups.ts new file mode 100644 index 000000000000..a881c90e66d7 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/backups.ts @@ -0,0 +1,416 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * 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/backupsMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a Backups. */ +export class Backups { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a Backups. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * List all backups for a volume + * @summary List Backups + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get a particular backup of the volume + * @summary Get a backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + backupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Create a backup for the volume + * @summary Create a backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param location Resource location + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, location: string, options?: Models.BackupsCreateOptionalParams): Promise { + return this.beginCreate(resourceGroupName,accountName,poolName,volumeName,backupName,location,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Patch a backup for the volume + * @summary Patch a backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: Models.BackupsUpdateOptionalParams): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param options The optional parameters + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options: Models.BackupsUpdateOptionalParams, callback: msRest.ServiceCallback): void; + update(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: Models.BackupsUpdateOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + backupName, + options + }, + updateOperationSpec, + callback) as Promise; + } + + /** + * Delete a backup of the volume + * @summary Delete backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,accountName,poolName,volumeName,backupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Create a backup for the volume + * @summary Create a backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param location Resource location + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, location: string, options?: Models.BackupsBeginCreateOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + backupName, + location, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Delete a backup of the volume + * @summary Delete backup + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param backupName The name of the backup + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, backupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + backupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/backups", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BackupsList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/backups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Backup + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const updateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/backups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + tags: [ + "options", + "tags" + ], + label: [ + "options", + "label" + ] + }, + mapper: Mappers.BackupPatch + }, + responses: { + 200: { + bodyMapper: Mappers.Backup + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/backups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + location: "location", + label: [ + "options", + "label" + ] + }, + mapper: { + ...Mappers.Backup, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Backup + }, + 201: { + bodyMapper: Mappers.Backup + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/backups/{backupName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName, + Parameters.backupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/netapp/arm-netapp/src/operations/index.ts b/sdk/netapp/arm-netapp/src/operations/index.ts index b05a3467d352..d12b86703bd8 100644 --- a/sdk/netapp/arm-netapp/src/operations/index.ts +++ b/sdk/netapp/arm-netapp/src/operations/index.ts @@ -14,3 +14,8 @@ export * from "./accounts"; export * from "./pools"; export * from "./volumes"; export * from "./snapshots"; +export * from "./snapshotPolicies"; +export * from "./accountBackups"; +export * from "./backups"; +export * from "./backupPolicies"; +export * from "./vaults"; diff --git a/sdk/netapp/arm-netapp/src/operations/netAppResource.ts b/sdk/netapp/arm-netapp/src/operations/netAppResource.ts index 0eaf847cddda..5e3dce044b44 100644 --- a/sdk/netapp/arm-netapp/src/operations/netAppResource.ts +++ b/sdk/netapp/arm-netapp/src/operations/netAppResource.ts @@ -50,7 +50,7 @@ export class NetAppResource { * @param resourceGroup Resource group name. * @param callback The callback */ - checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, callback: msRest.ServiceCallback): void; + checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, callback: msRest.ServiceCallback): void; /** * @param location The location * @param name Resource name to verify. @@ -62,8 +62,8 @@ export class NetAppResource { * @param options The optional parameters * @param callback The callback */ - checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; - checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + checkNameAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { return this.client.sendOperationRequest( { location, @@ -100,7 +100,7 @@ export class NetAppResource { * @param resourceGroup Resource group name. * @param callback The callback */ - checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, callback: msRest.ServiceCallback): void; + checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, callback: msRest.ServiceCallback): void; /** * @param location The location * @param name Resource name to verify. @@ -112,8 +112,8 @@ export class NetAppResource { * @param options The optional parameters * @param callback The callback */ - checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; - checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + checkFilePathAvailability(location: string, name: string, type: Models.CheckNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { return this.client.sendOperationRequest( { location, @@ -125,6 +125,56 @@ export class NetAppResource { checkFilePathAvailabilityOperationSpec, callback) as Promise; } + + /** + * Check if a quota is available. + * @summary Check quota availability + * @param location The location + * @param name Name of the resource to verify. + * @param type Resource type used for verification. Possible values include: + * 'Microsoft.NetApp/netAppAccounts', 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + * @param resourceGroup Resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + checkQuotaAvailability(location: string, name: string, type: Models.CheckQuotaNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param location The location + * @param name Name of the resource to verify. + * @param type Resource type used for verification. Possible values include: + * 'Microsoft.NetApp/netAppAccounts', 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + * @param resourceGroup Resource group name. + * @param callback The callback + */ + checkQuotaAvailability(location: string, name: string, type: Models.CheckQuotaNameResourceTypes, resourceGroup: string, callback: msRest.ServiceCallback): void; + /** + * @param location The location + * @param name Name of the resource to verify. + * @param type Resource type used for verification. Possible values include: + * 'Microsoft.NetApp/netAppAccounts', 'Microsoft.NetApp/netAppAccounts/capacityPools', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes', + * 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots' + * @param resourceGroup Resource group name. + * @param options The optional parameters + * @param callback The callback + */ + checkQuotaAvailability(location: string, name: string, type: Models.CheckQuotaNameResourceTypes, resourceGroup: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + checkQuotaAvailability(location: string, name: string, type: Models.CheckQuotaNameResourceTypes, resourceGroup: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + location, + name, + type, + resourceGroup, + options + }, + checkQuotaAvailabilityOperationSpec, + callback) as Promise; + } } // Operation Specifications @@ -155,7 +205,7 @@ const checkNameAvailabilityOperationSpec: msRest.OperationSpec = { }, responses: { 200: { - bodyMapper: Mappers.ResourceNameAvailability + bodyMapper: Mappers.CheckAvailabilityResponse }, default: { bodyMapper: Mappers.CloudError @@ -190,7 +240,42 @@ const checkFilePathAvailabilityOperationSpec: msRest.OperationSpec = { }, responses: { 200: { - bodyMapper: Mappers.ResourceNameAvailability + bodyMapper: Mappers.CheckAvailabilityResponse + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const checkQuotaAvailabilityOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/providers/Microsoft.NetApp/locations/{location}/checkQuotaAvailability", + urlParameters: [ + Parameters.subscriptionId, + Parameters.location + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + name: "name", + type: "type", + resourceGroup: "resourceGroup" + }, + mapper: { + ...Mappers.QuotaAvailabilityRequest, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.CheckAvailabilityResponse }, default: { bodyMapper: Mappers.CloudError diff --git a/sdk/netapp/arm-netapp/src/operations/snapshotPolicies.ts b/sdk/netapp/arm-netapp/src/operations/snapshotPolicies.ts new file mode 100644 index 000000000000..ee8b414c887a --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/snapshotPolicies.ts @@ -0,0 +1,421 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * 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/snapshotPoliciesMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a SnapshotPolicies. */ +export class SnapshotPolicies { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a SnapshotPolicies. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * List snapshot policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get a snapshot Policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, snapshotPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + snapshotPolicyName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Create a snapshot policy + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + create(body: Models.SnapshotPolicy, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param callback The callback + */ + create(body: Models.SnapshotPolicy, resourceGroupName: string, accountName: string, snapshotPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param options The optional parameters + * @param callback The callback + */ + create(body: Models.SnapshotPolicy, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + create(body: Models.SnapshotPolicy, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + body, + resourceGroupName, + accountName, + snapshotPolicyName, + options + }, + createOperationSpec, + callback) as Promise; + } + + /** + * Patch a snapshot policy + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + update(body: Models.SnapshotPolicyPatch, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param callback The callback + */ + update(body: Models.SnapshotPolicyPatch, resourceGroupName: string, accountName: string, snapshotPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param body Snapshot policy object supplied in the body of the operation. + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param options The optional parameters + * @param callback The callback + */ + update(body: Models.SnapshotPolicyPatch, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + update(body: Models.SnapshotPolicyPatch, resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + body, + resourceGroupName, + accountName, + snapshotPolicyName, + options + }, + updateOperationSpec, + callback) as Promise; + } + + /** + * Delete snapshot policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,accountName,snapshotPolicyName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Get volumes associated with snapshot policy + * @summary Get volumes associated with snapshot policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + listVolumes(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param callback The callback + */ + listVolumes(resourceGroupName: string, accountName: string, snapshotPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param options The optional parameters + * @param callback The callback + */ + listVolumes(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listVolumes(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + snapshotPolicyName, + options + }, + listVolumesOperationSpec, + callback) as Promise; + } + + /** + * Delete snapshot policy + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param snapshotPolicyName The name of the snapshot policy target + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, accountName: string, snapshotPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + snapshotPolicyName, + options + }, + beginDeleteMethodOperationSpec, + options); + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SnapshotPoliciesList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies/{snapshotPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.snapshotPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SnapshotPolicy + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const createOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies/{snapshotPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.snapshotPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "body", + mapper: { + ...Mappers.SnapshotPolicy, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.SnapshotPolicy + }, + 201: { + bodyMapper: Mappers.SnapshotPolicy + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const updateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies/{snapshotPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.snapshotPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "body", + mapper: { + ...Mappers.SnapshotPolicyPatch, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.SnapshotPolicy + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listVolumesOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies/{snapshotPolicyName}/listVolumes", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.snapshotPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SnapshotPolicyVolumeList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/snapshotPolicies/{snapshotPolicyName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.snapshotPolicyName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/netapp/arm-netapp/src/operations/vaults.ts b/sdk/netapp/arm-netapp/src/operations/vaults.ts new file mode 100644 index 000000000000..641097b4d7e4 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/vaults.ts @@ -0,0 +1,88 @@ +/* + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * 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 Models from "../models"; +import * as Mappers from "../models/vaultsMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a Vaults. */ +export class Vaults { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a Vaults. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * List vaults for a Netapp Account + * @summary List vaults + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param [options] The optional parameters + * @returns Promise + */ + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param options The optional parameters + * @param callback The callback + */ + list(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + listOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/vaults", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.VaultList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/netapp/arm-netapp/src/operations/volumes.ts b/sdk/netapp/arm-netapp/src/operations/volumes.ts index 2ed8b37d4db5..a30c7ea2ac45 100644 --- a/sdk/netapp/arm-netapp/src/operations/volumes.ts +++ b/sdk/netapp/arm-netapp/src/operations/volumes.ts @@ -177,7 +177,7 @@ export class Volumes { * @param [options] The optional parameters * @returns Promise */ - breakReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase): Promise { + breakReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: Models.VolumesBreakReplicationOptionalParams): Promise { return this.beginBreakReplication(resourceGroupName,accountName,poolName,volumeName,options) .then(lroPoller => lroPoller.pollUntilFinished()); } @@ -270,6 +270,37 @@ export class Volumes { .then(lroPoller => lroPoller.pollUntilFinished()); } + /** + * Re-Initializes the replication connection on the destination volume + * @summary ReInitialize volume replication + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param [options] The optional parameters + * @returns Promise + */ + reInitializeReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginReInitializeReplication(resourceGroupName,accountName,poolName,volumeName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Moves volume to another pool + * @summary Change pool for volume + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param newPoolResourceId Resource id of the pool to move volume to + * @param [options] The optional parameters + * @returns Promise + */ + poolChange(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, newPoolResourceId: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginPoolChange(resourceGroupName,accountName,poolName,volumeName,newPoolResourceId,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + /** * Create or update the specified volume within the capacity pool * @summary Create or Update a volume @@ -376,7 +407,7 @@ export class Volumes { * @param [options] The optional parameters * @returns Promise */ - beginBreakReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase): Promise { + beginBreakReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: Models.VolumesBeginBreakReplicationOptionalParams): Promise { return this.client.sendLRORequest( { resourceGroupName, @@ -459,6 +490,54 @@ export class Volumes { beginAuthorizeReplicationOperationSpec, options); } + + /** + * Re-Initializes the replication connection on the destination volume + * @summary ReInitialize volume replication + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param [options] The optional parameters + * @returns Promise + */ + beginReInitializeReplication(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + options + }, + beginReInitializeReplicationOperationSpec, + options); + } + + /** + * Moves volume to another pool + * @summary Change pool for volume + * @param resourceGroupName The name of the resource group. + * @param accountName The name of the NetApp account + * @param poolName The name of the capacity pool + * @param volumeName The name of the volume + * @param newPoolResourceId Resource id of the pool to move volume to + * @param [options] The optional parameters + * @returns Promise + */ + beginPoolChange(resourceGroupName: string, accountName: string, poolName: string, volumeName: string, newPoolResourceId: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + accountName, + poolName, + volumeName, + newPoolResourceId, + options + }, + beginPoolChangeOperationSpec, + options); + } } // Operation Specifications @@ -696,6 +775,15 @@ const beginBreakReplicationOperationSpec: msRest.OperationSpec = { headerParameters: [ Parameters.acceptLanguage ], + requestBody: { + parameterPath: { + forceBreakReplication: [ + "options", + "forceBreakReplication" + ] + }, + mapper: Mappers.BreakReplicationRequest + }, responses: { 200: {}, 202: {}, @@ -795,3 +883,64 @@ const beginAuthorizeReplicationOperationSpec: msRest.OperationSpec = { }, serializer }; + +const beginReInitializeReplicationOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/reinitializeReplication", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginPoolChangeOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NetApp/netAppAccounts/{accountName}/capacityPools/{poolName}/volumes/{volumeName}/poolChange", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName, + Parameters.poolName, + Parameters.volumeName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + newPoolResourceId: "newPoolResourceId" + }, + mapper: { + ...Mappers.PoolChangeRequest, + required: true + } + }, + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; From adf66f618bfad1a4f4756b204f16d38a79ea5a9a Mon Sep 17 00:00:00 2001 From: colawwj Date: Wed, 26 Aug 2020 17:22:05 +0800 Subject: [PATCH 3/3] version change --- sdk/netapp/arm-netapp/package.json | 2 +- .../arm-netapp/src/azureNetAppFilesManagementClientContext.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sdk/netapp/arm-netapp/package.json b/sdk/netapp/arm-netapp/package.json index adfd2e4f6662..83869015f7a2 100644 --- a/sdk/netapp/arm-netapp/package.json +++ b/sdk/netapp/arm-netapp/package.json @@ -2,7 +2,7 @@ "name": "@azure/arm-netapp", "author": "Microsoft Corporation", "description": "AzureNetAppFilesManagementClient Library with typescript type definitions for node.js and browser.", - "version": "11.1.0", + "version": "12.0.0", "dependencies": { "@azure/ms-rest-azure-js": "^2.0.1", "@azure/ms-rest-js": "^2.0.4", diff --git a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts index c57afcf826fc..3ebdcacb0888 100644 --- a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts +++ b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClientContext.ts @@ -13,7 +13,7 @@ import * as msRest from "@azure/ms-rest-js"; import * as msRestAzure from "@azure/ms-rest-azure-js"; const packageName = "@azure/arm-netapp"; -const packageVersion = "11.1.0"; +const packageVersion = "12.0.0"; export class AzureNetAppFilesManagementClientContext extends msRestAzure.AzureServiceClient { credentials: msRest.ServiceClientCredentials;