From 598970bd8cf294379ac6cfd8cfa6aaecec68d3b0 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Fri, 20 Apr 2018 01:10:55 +0000 Subject: [PATCH 1/2] Generated from 15e066396a2791da1195f7d902ec6cdd27dc99aa Removed ShortTermRetentionPolicies_ListByDatabase until it is fixed to return array --- .../sqlManagement2/lib/models/index.d.ts | 432 +- .../sqlManagement2/lib/models/index.js | 17 +- .../sqlManagement2/lib/operations/index.d.ts | 7898 ++++++----------- .../sqlManagement2/lib/operations/index.js | 3 - .../lib/sqlManagementClient.d.ts | 3 - .../sqlManagement2/lib/sqlManagementClient.js | 3 - 6 files changed, 2540 insertions(+), 5816 deletions(-) diff --git a/lib/services/sqlManagement2/lib/models/index.d.ts b/lib/services/sqlManagement2/lib/models/index.d.ts index fa1c535c36..e291789c89 100644 --- a/lib/services/sqlManagement2/lib/models/index.d.ts +++ b/lib/services/sqlManagement2/lib/models/index.d.ts @@ -1292,140 +1292,6 @@ export interface FailoverGroupUpdate { tags?: { [propertyName: string]: string }; } -/** - * @class - * Initializes a new instance of the ResourceIdentity class. - * @constructor - * Azure Active Directory identity configuration for a resource. - * - * @member {uuid} [principalId] The Azure Active Directory principal id. - * @member {string} [type] The identity type. Set this to 'SystemAssigned' in - * order to automatically create and assign an Azure Active Directory principal - * for the resource. Possible values include: 'SystemAssigned' - * @member {uuid} [tenantId] The Azure Active Directory tenant id. - */ -export interface ResourceIdentity { - readonly principalId?: string; - type?: string; - readonly tenantId?: string; -} - -/** - * @class - * Initializes a new instance of the Sku class. - * @constructor - * An ARM Resource SKU. - * - * @member {string} name The name of the SKU, typically, a letter + Number - * code, e.g. P3. - * @member {string} [tier] The tier of the particular SKU, e.g. Basic, Premium. - * @member {string} [size] Size of the particular SKU - * @member {string} [family] If the service has different generations of - * hardware, for the same SKU, then that can be captured here. - * @member {number} [capacity] Capacity of the particular SKU. - */ -export interface Sku { - name: string; - tier?: string; - size?: string; - family?: string; - capacity?: number; -} - -/** - * @class - * Initializes a new instance of the ManagedInstance class. - * @constructor - * An Azure SQL managed instance. - * - * @member {object} [identity] The Azure Active Directory identity of the - * managed instance. - * @member {uuid} [identity.principalId] The Azure Active Directory principal - * id. - * @member {string} [identity.type] The identity type. Set this to - * 'SystemAssigned' in order to automatically create and assign an Azure Active - * Directory principal for the resource. Possible values include: - * 'SystemAssigned' - * @member {uuid} [identity.tenantId] The Azure Active Directory tenant id. - * @member {object} [sku] Managed instance sku - * @member {string} [sku.name] The name of the SKU, typically, a letter + - * Number code, e.g. P3. - * @member {string} [sku.tier] The tier of the particular SKU, e.g. Basic, - * Premium. - * @member {string} [sku.size] Size of the particular SKU - * @member {string} [sku.family] If the service has different generations of - * hardware, for the same SKU, then that can be captured here. - * @member {number} [sku.capacity] Capacity of the particular SKU. - * @member {string} [fullyQualifiedDomainName] The fully qualified domain name - * of the managed instance. - * @member {string} [administratorLogin] Administrator username for the managed - * instance. Can only be specified when the managed instance is being created - * (and is required for creation). - * @member {string} [administratorLoginPassword] The administrator login - * password (required for managed instance creation). - * @member {string} [subnetId] Subnet resource ID for the managed instance. - * @member {string} [state] The state of the managed instance. - * @member {string} [licenseType] The license type. Possible values are - * 'LicenseIncluded' and 'BasePrice'. - * @member {number} [vCores] The number of VCores. - * @member {number} [storageSizeInGB] The maximum storage size in GB. - */ -export interface ManagedInstance extends TrackedResource { - identity?: ResourceIdentity; - sku?: Sku; - readonly fullyQualifiedDomainName?: string; - administratorLogin?: string; - administratorLoginPassword?: string; - subnetId?: string; - readonly state?: string; - licenseType?: string; - vCores?: number; - storageSizeInGB?: number; -} - -/** - * @class - * Initializes a new instance of the ManagedInstanceUpdate class. - * @constructor - * An update request for an Azure SQL Database managed instance. - * - * @member {object} [sku] Managed instance sku - * @member {string} [sku.name] The name of the SKU, typically, a letter + - * Number code, e.g. P3. - * @member {string} [sku.tier] The tier of the particular SKU, e.g. Basic, - * Premium. - * @member {string} [sku.size] Size of the particular SKU - * @member {string} [sku.family] If the service has different generations of - * hardware, for the same SKU, then that can be captured here. - * @member {number} [sku.capacity] Capacity of the particular SKU. - * @member {string} [fullyQualifiedDomainName] The fully qualified domain name - * of the managed instance. - * @member {string} [administratorLogin] Administrator username for the managed - * instance. Can only be specified when the managed instance is being created - * (and is required for creation). - * @member {string} [administratorLoginPassword] The administrator login - * password (required for managed instance creation). - * @member {string} [subnetId] Subnet resource ID for the managed instance. - * @member {string} [state] The state of the managed instance. - * @member {string} [licenseType] The license type. Possible values are - * 'LicenseIncluded' and 'BasePrice'. - * @member {number} [vCores] The number of VCores. - * @member {number} [storageSizeInGB] The maximum storage size in GB. - * @member {object} [tags] Resource tags. - */ -export interface ManagedInstanceUpdate { - sku?: Sku; - readonly fullyQualifiedDomainName?: string; - administratorLogin?: string; - administratorLoginPassword?: string; - subnetId?: string; - readonly state?: string; - licenseType?: string; - vCores?: number; - storageSizeInGB?: number; - tags?: { [propertyName: string]: string }; -} - /** * @class * Initializes a new instance of the OperationDisplay class. @@ -1502,6 +1368,24 @@ export interface ServerKey extends ProxyResource { creationDate?: Date; } +/** + * @class + * Initializes a new instance of the ResourceIdentity class. + * @constructor + * Azure Active Directory identity configuration for a resource. + * + * @member {uuid} [principalId] The Azure Active Directory principal id. + * @member {string} [type] The identity type. Set this to 'SystemAssigned' in + * order to automatically create and assign an Azure Active Directory principal + * for the resource. Possible values include: 'SystemAssigned' + * @member {uuid} [tenantId] The Azure Active Directory tenant id. + */ +export interface ResourceIdentity { + readonly principalId?: string; + type?: string; + readonly tenantId?: string; +} + /** * @class * Initializes a new instance of the Server class. @@ -1925,125 +1809,6 @@ export interface BackupLongTermRetentionPolicy extends ProxyResource { weekOfYear?: number; } -/** - * @class - * Initializes a new instance of the CompleteDatabaseRestoreDefinition class. - * @constructor - * Contains the information necessary to perform a complete database restore - * operation. - * - * @member {string} lastBackupName The last backup name to apply - */ -export interface CompleteDatabaseRestoreDefinition { - lastBackupName: string; -} - -/** - * @class - * Initializes a new instance of the ManagedDatabase class. - * @constructor - * A managed database resource. - * - * @member {string} [collation] Collation of the managed database. - * @member {string} [status] Status for the database. Possible values include: - * 'Online', 'Offline', 'Shutdown', 'Creating', 'Inaccessible' - * @member {date} [creationDate] Creation date of the database. - * @member {date} [earliestRestorePoint] Earliest restore point in time for - * point in time restore. - * @member {date} [restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * @member {string} [defaultSecondaryLocation] Geo paired region. - * @member {string} [catalogCollation] Collation of the metadata catalog. - * Possible values include: 'DATABASE_DEFAULT', 'SQL_Latin1_General_CP1_CI_AS' - * @member {string} [createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * @member {string} [storageContainerUri] Conditional. If createMode is - * RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * @member {string} [sourceDatabaseId] The resource identifier of the source - * database associated with create operation of this database. - * @member {string} [storageContainerSasToken] Conditional. If createMode is - * RestoreExternalBackup, this value is required. Specifies the storage - * container sas token. - * @member {string} [failoverGroupId] Instance Failover Group resource - * identifier that this managed database belongs to. - */ -export interface ManagedDatabase extends TrackedResource { - collation?: string; - readonly status?: string; - readonly creationDate?: Date; - readonly earliestRestorePoint?: Date; - restorePointInTime?: Date; - readonly defaultSecondaryLocation?: string; - catalogCollation?: string; - createMode?: string; - storageContainerUri?: string; - sourceDatabaseId?: string; - storageContainerSasToken?: string; - readonly failoverGroupId?: string; -} - -/** - * @class - * Initializes a new instance of the ManagedDatabaseUpdate class. - * @constructor - * An managed database update. - * - * @member {string} [collation] Collation of the managed database. - * @member {string} [status] Status for the database. Possible values include: - * 'Online', 'Offline', 'Shutdown', 'Creating', 'Inaccessible' - * @member {date} [creationDate] Creation date of the database. - * @member {date} [earliestRestorePoint] Earliest restore point in time for - * point in time restore. - * @member {date} [restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * @member {string} [defaultSecondaryLocation] Geo paired region. - * @member {string} [catalogCollation] Collation of the metadata catalog. - * Possible values include: 'DATABASE_DEFAULT', 'SQL_Latin1_General_CP1_CI_AS' - * @member {string} [createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * @member {string} [storageContainerUri] Conditional. If createMode is - * RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * @member {string} [sourceDatabaseId] The resource identifier of the source - * database associated with create operation of this database. - * @member {string} [storageContainerSasToken] Conditional. If createMode is - * RestoreExternalBackup, this value is required. Specifies the storage - * container sas token. - * @member {string} [failoverGroupId] Instance Failover Group resource - * identifier that this managed database belongs to. - * @member {object} [tags] Resource tags. - */ -export interface ManagedDatabaseUpdate { - collation?: string; - readonly status?: string; - readonly creationDate?: Date; - readonly earliestRestorePoint?: Date; - restorePointInTime?: Date; - readonly defaultSecondaryLocation?: string; - catalogCollation?: string; - createMode?: string; - storageContainerUri?: string; - sourceDatabaseId?: string; - storageContainerSasToken?: string; - readonly failoverGroupId?: string; - tags?: { [propertyName: string]: string }; -} - /** * @class * Initializes a new instance of the AutomaticTuningServerOptions class. @@ -2317,6 +2082,28 @@ export interface PerformanceLevelCapability { readonly unit?: string; } +/** + * @class + * Initializes a new instance of the Sku class. + * @constructor + * An ARM Resource SKU. + * + * @member {string} name The name of the SKU, typically, a letter + Number + * code, e.g. P3. + * @member {string} [tier] The tier of the particular SKU, e.g. Basic, Premium. + * @member {string} [size] Size of the particular SKU + * @member {string} [family] If the service has different generations of + * hardware, for the same SKU, then that can be captured here. + * @member {number} [capacity] Capacity of the particular SKU. + */ +export interface Sku { + name: string; + tier?: string; + size?: string; + family?: string; + capacity?: number; +} + /** * @class * Initializes a new instance of the LicenseTypeCapability class. @@ -3066,109 +2853,6 @@ export interface ElasticPoolUpdate { tags?: { [propertyName: string]: string }; } -/** - * @class - * Initializes a new instance of the InstanceFailoverGroupReadWriteEndpoint class. - * @constructor - * Read-write endpoint of the failover group instance. - * - * @member {string} failoverPolicy Failover policy of the read-write endpoint - * for the failover group. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. Possible values include: - * 'Manual', 'Automatic' - * @member {number} [failoverWithDataLossGracePeriodMinutes] Grace period - * before failover with data loss is attempted for the read-write endpoint. If - * failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is - * required. - */ -export interface InstanceFailoverGroupReadWriteEndpoint { - failoverPolicy: string; - failoverWithDataLossGracePeriodMinutes?: number; -} - -/** - * @class - * Initializes a new instance of the InstanceFailoverGroupReadOnlyEndpoint class. - * @constructor - * Read-only endpoint of the failover group instance. - * - * @member {string} [failoverPolicy] Failover policy of the read-only endpoint - * for the failover group. Possible values include: 'Disabled', 'Enabled' - */ -export interface InstanceFailoverGroupReadOnlyEndpoint { - failoverPolicy?: string; -} - -/** - * @class - * Initializes a new instance of the PartnerRegionInfo class. - * @constructor - * Partner region information for the failover group. - * - * @member {string} [location] Geo location of the partner managed instances. - * @member {string} [replicationRole] Replication role of the partner managed - * instances. Possible values include: 'Primary', 'Secondary' - */ -export interface PartnerRegionInfo { - location?: string; - readonly replicationRole?: string; -} - -/** - * @class - * Initializes a new instance of the ManagedInstancePairInfo class. - * @constructor - * Pairs of Managed Instances in the failover group. - * - * @member {string} [primaryManagedInstanceId] Id of Primary Managed Instance - * in pair. - * @member {string} [partnerManagedInstanceId] Id of Partner Managed Instance - * in pair. - */ -export interface ManagedInstancePairInfo { - primaryManagedInstanceId?: string; - partnerManagedInstanceId?: string; -} - -/** - * @class - * Initializes a new instance of the InstanceFailoverGroup class. - * @constructor - * An instance failover group. - * - * @member {object} readWriteEndpoint Read-write endpoint of the failover group - * instance. - * @member {string} [readWriteEndpoint.failoverPolicy] Failover policy of the - * read-write endpoint for the failover group. If failoverPolicy is Automatic - * then failoverWithDataLossGracePeriodMinutes is required. Possible values - * include: 'Manual', 'Automatic' - * @member {number} [readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] - * Grace period before failover with data loss is attempted for the read-write - * endpoint. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. - * @member {object} [readOnlyEndpoint] Read-only endpoint of the failover group - * instance. - * @member {string} [readOnlyEndpoint.failoverPolicy] Failover policy of the - * read-only endpoint for the failover group. Possible values include: - * 'Disabled', 'Enabled' - * @member {string} [replicationRole] Local replication role of the failover - * group instance. Possible values include: 'Primary', 'Secondary' - * @member {string} [replicationState] Replication state of the failover group - * instance. - * @member {array} partnerRegions Partner region information for the failover - * group. - * @member {array} managedInstancePairs List of managed instance pairs in the - * failover group. - */ -export interface InstanceFailoverGroup extends ProxyResource { - readWriteEndpoint: InstanceFailoverGroupReadWriteEndpoint; - readOnlyEndpoint?: InstanceFailoverGroupReadOnlyEndpoint; - readonly replicationRole?: string; - readonly replicationState?: string; - partnerRegions: PartnerRegionInfo[]; - managedInstancePairs: ManagedInstancePairInfo[]; -} - /** * @class @@ -3421,18 +3105,6 @@ export interface FailoverGroupListResult extends Array { readonly nextLink?: string; } -/** - * @class - * Initializes a new instance of the ManagedInstanceListResult class. - * @constructor - * A list of managed instances. - * - * @member {string} [nextLink] Link to retrieve next page of results. - */ -export interface ManagedInstanceListResult extends Array { - readonly nextLink?: string; -} - /** * @class * Initializes a new instance of the OperationListResult class. @@ -3577,18 +3249,6 @@ export interface LongTermRetentionBackupListResult extends Array { - readonly nextLink?: string; -} - /** * @class * Initializes a new instance of the ServerDnsAliasListResult class. @@ -3636,15 +3296,3 @@ export interface DatabaseOperationListResult extends Array { export interface ElasticPoolOperationListResult extends Array { readonly nextLink?: string; } - -/** - * @class - * Initializes a new instance of the InstanceFailoverGroupListResult class. - * @constructor - * A list of instance failover groups. - * - * @member {string} [nextLink] Link to retrieve next page of results. - */ -export interface InstanceFailoverGroupListResult extends Array { - readonly nextLink?: string; -} diff --git a/lib/services/sqlManagement2/lib/models/index.js b/lib/services/sqlManagement2/lib/models/index.js index bf52bd6905..eb58f54c80 100644 --- a/lib/services/sqlManagement2/lib/models/index.js +++ b/lib/services/sqlManagement2/lib/models/index.js @@ -65,13 +65,10 @@ exports.FailoverGroupReadOnlyEndpoint = require('./failoverGroupReadOnlyEndpoint exports.PartnerInfo = require('./partnerInfo'); exports.FailoverGroup = require('./failoverGroup'); exports.FailoverGroupUpdate = require('./failoverGroupUpdate'); -exports.ResourceIdentity = require('./resourceIdentity'); -exports.Sku = require('./sku'); -exports.ManagedInstance = require('./managedInstance'); -exports.ManagedInstanceUpdate = require('./managedInstanceUpdate'); exports.OperationDisplay = require('./operationDisplay'); exports.Operation = require('./operation'); exports.ServerKey = require('./serverKey'); +exports.ResourceIdentity = require('./resourceIdentity'); exports.Server = require('./server'); exports.ServerUpdate = require('./serverUpdate'); exports.SyncAgent = require('./syncAgent'); @@ -91,9 +88,6 @@ exports.SubscriptionUsage = require('./subscriptionUsage'); exports.VirtualNetworkRule = require('./virtualNetworkRule'); exports.LongTermRetentionBackup = require('./longTermRetentionBackup'); exports.BackupLongTermRetentionPolicy = require('./backupLongTermRetentionPolicy'); -exports.CompleteDatabaseRestoreDefinition = require('./completeDatabaseRestoreDefinition'); -exports.ManagedDatabase = require('./managedDatabase'); -exports.ManagedDatabaseUpdate = require('./managedDatabaseUpdate'); exports.AutomaticTuningServerOptions = require('./automaticTuningServerOptions'); exports.ServerAutomaticTuning = require('./serverAutomaticTuning'); exports.ServerDnsAlias = require('./serverDnsAlias'); @@ -106,6 +100,7 @@ exports.MaxSizeCapability = require('./maxSizeCapability'); exports.LogSizeCapability = require('./logSizeCapability'); exports.MaxSizeRangeCapability = require('./maxSizeRangeCapability'); exports.PerformanceLevelCapability = require('./performanceLevelCapability'); +exports.Sku = require('./sku'); exports.LicenseTypeCapability = require('./licenseTypeCapability'); exports.ServiceObjectiveCapability = require('./serviceObjectiveCapability'); exports.EditionCapability = require('./editionCapability'); @@ -125,11 +120,6 @@ exports.ResourceMoveDefinition = require('./resourceMoveDefinition'); exports.ElasticPoolPerDatabaseSettings = require('./elasticPoolPerDatabaseSettings'); exports.ElasticPool = require('./elasticPool'); exports.ElasticPoolUpdate = require('./elasticPoolUpdate'); -exports.InstanceFailoverGroupReadWriteEndpoint = require('./instanceFailoverGroupReadWriteEndpoint'); -exports.InstanceFailoverGroupReadOnlyEndpoint = require('./instanceFailoverGroupReadOnlyEndpoint'); -exports.PartnerRegionInfo = require('./partnerRegionInfo'); -exports.ManagedInstancePairInfo = require('./managedInstancePairInfo'); -exports.InstanceFailoverGroup = require('./instanceFailoverGroup'); exports.RecoverableDatabaseListResult = require('./recoverableDatabaseListResult'); exports.RestorableDroppedDatabaseListResult = require('./restorableDroppedDatabaseListResult'); exports.ServerListResult = require('./serverListResult'); @@ -154,7 +144,6 @@ exports.ServerUsageListResult = require('./serverUsageListResult'); exports.DatabaseUsageListResult = require('./databaseUsageListResult'); exports.EncryptionProtectorListResult = require('./encryptionProtectorListResult'); exports.FailoverGroupListResult = require('./failoverGroupListResult'); -exports.ManagedInstanceListResult = require('./managedInstanceListResult'); exports.OperationListResult = require('./operationListResult'); exports.ServerKeyListResult = require('./serverKeyListResult'); exports.SyncAgentListResult = require('./syncAgentListResult'); @@ -167,9 +156,7 @@ exports.SyncMemberListResult = require('./syncMemberListResult'); exports.SubscriptionUsageListResult = require('./subscriptionUsageListResult'); exports.VirtualNetworkRuleListResult = require('./virtualNetworkRuleListResult'); exports.LongTermRetentionBackupListResult = require('./longTermRetentionBackupListResult'); -exports.ManagedDatabaseListResult = require('./managedDatabaseListResult'); exports.ServerDnsAliasListResult = require('./serverDnsAliasListResult'); exports.RestorePointListResult = require('./restorePointListResult'); exports.DatabaseOperationListResult = require('./databaseOperationListResult'); exports.ElasticPoolOperationListResult = require('./elasticPoolOperationListResult'); -exports.InstanceFailoverGroupListResult = require('./instanceFailoverGroupListResult'); diff --git a/lib/services/sqlManagement2/lib/operations/index.d.ts b/lib/services/sqlManagement2/lib/operations/index.d.ts index a128bea671..c753734bba 100644 --- a/lib/services/sqlManagement2/lib/operations/index.d.ts +++ b/lib/services/sqlManagement2/lib/operations/index.d.ts @@ -10710,15 +10710,15 @@ export interface FailoverGroups { /** * @class - * ManagedInstances + * Operations * __NOTE__: An instance of this class is automatically created for an * instance of the SqlManagementClient. */ -export interface ManagedInstances { +export interface Operations { /** - * Gets a list of all managed instances in the subscription. + * Lists all of the available SQL Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -10727,14 +10727,14 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of all managed instances in the subscription. + * Lists all of the available SQL Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -10748,7 +10748,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstanceListResult} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10756,25 +10756,23 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstanceListResult} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of managed instances in a resource group. + * Lists all of the available SQL Rest API operations. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10783,18 +10781,17 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of managed instances in a resource group. + * Lists all of the available SQL Rest API operations. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -10808,7 +10805,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstanceListResult} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10816,27 +10813,35 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstanceListResult} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; - listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ServerKeys + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ServerKeys { /** - * Gets a managed instance. + * Gets a list of server keys. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -10845,20 +10850,20 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a managed instance. + * Gets a list of server keys. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -10872,7 +10877,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstance} - The deserialized result object. + * @resolve {ServerKeyListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10880,140 +10885,159 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstance} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstance} for more information. + * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKeyListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a managed instance. + * Gets a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. + * @param {string} serverName The name of the server. * - * @param {object} [parameters.identity] The Azure Active Directory identity of - * the managed instance. + * @param {string} keyName The name of the server key to be retrieved. * - * @param {string} [parameters.identity.type] The identity type. Set this to - * 'SystemAssigned' in order to automatically create and assign an Azure Active - * Directory principal for the resource. Possible values include: - * 'SystemAssigned' + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.sku] Managed instance sku + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.sku.size] Size of the particular SKU + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a server key. * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * @param {string} serverName The name of the server. * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). + * @param {string} keyName The name of the server key to be retrieved. * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {number} [parameters.vCores] The number of VCores. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * {Promise} A promise is returned. * - * @param {object} [parameters.tags] Resource tags. + * @resolve {ServerKey} - The deserialized result object. * - * @param {string} parameters.location Resource location. + * @reject {Error|ServiceError} - The error object. * - * @param {object} [options] Optional Parameters. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @returns {Promise} A promise is returned + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @reject {Error|ServiceError} - The error object. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + get(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Creates or updates a managed instance. + * Creates or updates a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * - * @param {object} parameters The requested managed instance resource state. + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 * - * @param {object} [parameters.identity] The Azure Active Directory identity of - * the managed instance. + * @param {object} parameters The requested server key resource state. * - * @param {string} [parameters.identity.type] The identity type. Set this to - * 'SystemAssigned' in order to automatically create and assign an Azure Active - * Directory principal for the resource. Possible values include: - * 'SystemAssigned' + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. * - * @param {object} [parameters.sku] Managed instance sku + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. + * @param {string} [parameters.uri] The URI of the server key. * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. + * @param {string} [parameters.thumbprint] Thumbprint of the server key. * - * @param {string} [parameters.sku.size] Size of the particular SKU + * @param {date} [parameters.creationDate] The server key creation date. * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. + * @param {object} [options] Optional Parameters. * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). + * @returns {Promise} A promise is returned * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a server key. * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {string} serverName The name of the server. * - * @param {number} [parameters.vCores] The number of VCores. + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @param {object} parameters The requested server key resource state. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. * - * @param {string} parameters.location Resource location. + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' + * + * @param {string} [parameters.uri] The URI of the server key. + * + * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -11027,7 +11051,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstance} - The deserialized result object. + * @resolve {ServerKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11035,26 +11059,28 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstance} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstance} for more information. + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a managed instance. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -11067,16 +11093,18 @@ export interface ManagedInstances { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a managed instance. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -11104,55 +11132,41 @@ export interface ManagedInstances { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a managed instance. + * Creates or updates a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. - * - * @param {object} [parameters.sku] Managed instance sku - * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. - * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. - * - * @param {string} [parameters.sku.size] Size of the particular SKU - * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. - * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * @param {string} serverName The name of the server. * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). + * @param {object} parameters The requested server key resource state. * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' * - * @param {number} [parameters.vCores] The number of VCores. + * @param {string} [parameters.uri] The URI of the server key. * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @param {string} [parameters.thumbprint] Thumbprint of the server key. * - * @param {object} [parameters.tags] Resource tags. + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -11161,56 +11175,42 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a managed instance. + * Creates or updates a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. + * @param {string} serverName The name of the server. * - * @param {object} [parameters.sku] Managed instance sku + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. + * @param {object} parameters The requested server key resource state. * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. * - * @param {string} [parameters.sku.size] Size of the particular SKU - * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. - * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. - * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). - * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). - * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. - * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' * - * @param {number} [parameters.vCores] The number of VCores. + * @param {string} [parameters.uri] The URI of the server key. * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @param {string} [parameters.thumbprint] Thumbprint of the server key. * - * @param {object} [parameters.tags] Resource tags. + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -11224,7 +11224,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstance} - The deserialized result object. + * @resolve {ServerKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11232,72 +11232,28 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstance} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstance} for more information. + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, callback: ServiceCallback): void; - update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a managed instance. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. - * - * @param {object} [parameters.identity] The Azure Active Directory identity of - * the managed instance. - * - * @param {string} [parameters.identity.type] The identity type. Set this to - * 'SystemAssigned' in order to automatically create and assign an Azure Active - * Directory principal for the resource. Possible values include: - * 'SystemAssigned' - * - * @param {object} [parameters.sku] Managed instance sku - * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. - * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. - * - * @param {string} [parameters.sku.size] Size of the particular SKU - * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. - * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. - * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). - * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). - * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. - * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. - * - * @param {number} [parameters.vCores] The number of VCores. - * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} serverName The name of the server. * - * @param {string} parameters.location Resource location. + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -11306,66 +11262,78 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a managed instance. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be deleted. * - * @param {object} parameters The requested managed instance resource state. + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.identity] The Azure Active Directory identity of - * the managed instance. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.identity.type] The identity type. Set this to - * 'SystemAssigned' in order to automatically create and assign an Azure Active - * Directory principal for the resource. Possible values include: - * 'SystemAssigned' + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {object} [parameters.sku] Managed instance sku + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. + * {Promise} A promise is returned. * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. + * @resolve {null} - The deserialized result object. * - * @param {string} [parameters.sku.size] Size of the particular SKU + * @reject {Error|ServiceError} - The error object. * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). + * {null} [result] - The deserialized result object if an error did not occur. * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a list of server keys. * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {object} [options] Optional Parameters. * - * @param {number} [parameters.vCores] The number of VCores. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @returns {Promise} A promise is returned * - * @param {object} [parameters.tags] Resource tags. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} parameters.location Resource location. + * @reject {Error|ServiceError} - The error object. + */ + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a list of server keys. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11379,7 +11347,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstance} - The deserialized result object. + * @resolve {ServerKeyListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11387,26 +11355,38 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstance} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstance} for more information. + * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKeyListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SyncAgents + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncAgents { /** - * Deletes a managed instance. + * Gets a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11415,20 +11395,23 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a managed instance. + * Gets a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11442,7 +11425,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11450,61 +11433,34 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a managed instance. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. - * - * @param {object} [parameters.sku] Managed instance sku - * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. - * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. - * - * @param {string} [parameters.sku.size] Size of the particular SKU - * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. - * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. - * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). - * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). - * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. - * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {number} [parameters.vCores] The number of VCores. + * @param {string} syncAgentName The name of the sync agent. * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @param {object} parameters The requested sync agent resource state. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11513,56 +11469,28 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a managed instance. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {object} parameters The requested managed instance resource state. - * - * @param {object} [parameters.sku] Managed instance sku - * - * @param {string} parameters.sku.name The name of the SKU, typically, a letter - * + Number code, e.g. P3. - * - * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. - * Basic, Premium. - * - * @param {string} [parameters.sku.size] Size of the particular SKU - * - * @param {string} [parameters.sku.family] If the service has different - * generations of hardware, for the same SKU, then that can be captured here. - * - * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. - * - * @param {string} [parameters.administratorLogin] Administrator username for - * the managed instance. Can only be specified when the managed instance is - * being created (and is required for creation). - * - * @param {string} [parameters.administratorLoginPassword] The administrator - * login password (required for managed instance creation). - * - * @param {string} [parameters.subnetId] Subnet resource ID for the managed - * instance. - * - * @param {string} [parameters.licenseType] The license type. Possible values - * are 'LicenseIncluded' and 'BasePrice'. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {number} [parameters.vCores] The number of VCores. + * @param {string} syncAgentName The name of the sync agent. * - * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * @param {object} parameters The requested sync agent resource state. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11576,7 +11504,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstance} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11584,23 +11512,29 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstance} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstance} for more information. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of all managed instances in the subscription. + * Deletes a sync agent. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11609,17 +11543,23 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of all managed instances in the subscription. + * Deletes a sync agent. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11633,7 +11573,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstanceListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11641,24 +11581,26 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstanceListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of managed instances in a resource group. + * Lists sync agents in a server. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * * @param {object} [options] Optional Parameters. * @@ -11667,17 +11609,21 @@ export interface ManagedInstances { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of managed instances in a resource group. + * Lists sync agents in a server. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * * @param {object} [options] Optional Parameters. * @@ -11691,7 +11637,7 @@ export interface ManagedInstances { * * {Promise} A promise is returned. * - * @resolve {ManagedInstanceListResult} - The deserialized result object. + * @resolve {SyncAgentListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11699,30 +11645,29 @@ export interface ManagedInstances { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedInstanceListResult} for more - * information. + * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * Operations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface Operations { + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all of the available SQL Rest API operations. + * Generates a sync agent key. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11731,14 +11676,23 @@ export interface Operations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + generateKeyWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all of the available SQL Rest API operations. + * Generates a sync agent key. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11752,7 +11706,7 @@ export interface Operations { * * {Promise} A promise is returned. * - * @resolve {OperationListResult} - The deserialized result object. + * @resolve {SyncAgentKeyProperties} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11760,23 +11714,30 @@ export interface Operations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. + * {SyncAgentKeyProperties} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentKeyProperties} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all of the available SQL Rest API operations. + * Lists databases linked to a sync agent. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11785,17 +11746,23 @@ export interface Operations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLinkedDatabasesWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all of the available SQL Rest API operations. + * Lists databases linked to a sync agent. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11809,7 +11776,7 @@ export interface Operations { * * {Promise} A promise is returned. * - * @resolve {OperationListResult} - The deserialized result object. + * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11817,35 +11784,35 @@ export interface Operations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. + * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentLinkedDatabaseListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ServerKeys - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ServerKeys { + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server keys. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. + * + * @param {object} parameters The requested sync agent resource state. + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11854,20 +11821,28 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server keys. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. + * + * @param {string} syncAgentName The name of the sync agent. + * + * @param {object} parameters The requested sync agent resource state. + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11881,7 +11856,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKeyListResult} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11889,28 +11864,29 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKeyListResult} for more information. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a server key. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} keyName The name of the server key to be retrieved. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11919,22 +11895,23 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a server key. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} keyName The name of the server key to be retrieved. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -11948,7 +11925,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKey} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11956,48 +11933,22 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a server key. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 - * - * @param {object} parameters The requested server key resource state. - * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. - * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' - * - * @param {string} [parameters.uri] The URI of the server key. - * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * Lists sync agents in a server. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12006,56 +11957,31 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a server key. + * Lists sync agents in a server. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} serverName The name of the server. + * @param {object} [options] Optional Parameters. * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {object} parameters The requested server key resource state. + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' + * {Promise} A promise is returned. * - * @param {string} [parameters.uri] The URI of the server key. - * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. - * - * @param {date} [parameters.creationDate] The server key creation date. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {ServerKey} - The deserialized result object. + * @resolve {SyncAgentListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12063,28 +11989,23 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server key with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists databases linked to a sync agent. * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12093,22 +12014,17 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLinkedDatabasesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server key with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists databases linked to a sync agent. * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12122,7 +12038,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12130,47 +12046,33 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentLinkedDatabaseListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listLinkedDatabasesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLinkedDatabasesNext(nextPageLink: string, callback: ServiceCallback): void; + listLinkedDatabasesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SyncGroups + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncGroups { /** - * Creates or updates a server key. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 - * - * @param {object} parameters The requested server key resource state. - * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. - * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' - * - * @param {string} [parameters.uri] The URI of the server key. - * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * Gets a collection of sync database ids. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -12179,42 +12081,17 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listSyncDatabaseIdsWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a server key. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 - * - * @param {object} parameters The requested server key resource state. - * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. - * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' - * - * @param {string} [parameters.uri] The URI of the server key. - * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * Gets a collection of sync database ids. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -12228,7 +12105,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKey} - The deserialized result object. + * @resolve {SyncDatabaseIdListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12236,20 +12113,21 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncDatabaseIdListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listSyncDatabaseIds(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listSyncDatabaseIds(locationName: string, callback: ServiceCallback): void; + listSyncDatabaseIds(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server key with the given name. + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -12257,7 +12135,10 @@ export interface ServerKeys { * * @param {string} serverName The name of the server. * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12270,10 +12151,10 @@ export interface ServerKeys { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + refreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server key with the given name. + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -12281,7 +12162,10 @@ export interface ServerKeys { * * @param {string} serverName The name of the server. * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12309,16 +12193,24 @@ export interface ServerKeys { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server keys. + * Gets a collection of hub database schemas. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12327,17 +12219,25 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listHubSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server keys. + * Gets a collection of hub database schemas. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12351,7 +12251,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKeyListResult} - The deserialized result object. + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12359,66 +12259,82 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKeyListResult} for more information. + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncAgents - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncAgents { + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync agent. + * Gets a collection of sync group logs. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {string} startTime Get logs generated after this time. + * + * @param {string} endTime Get logs generated before this time. + * + * @param {string} type The types of logs to retrieve. Possible values include: + * 'All', 'Error', 'Warning', 'Success' * * @param {object} [options] Optional Parameters. * + * @param {string} [options.continuationToken] The continuation token for this + * operation. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLogsWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync agent. + * Gets a collection of sync group logs. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {string} startTime Get logs generated after this time. + * + * @param {string} endTime Get logs generated before this time. + * + * @param {string} type The types of logs to retrieve. Possible values include: + * 'All', 'Error', 'Warning', 'Success' * * @param {object} [options] Optional Parameters. * + * @param {string} [options.continuationToken] The continuation token for this + * operation. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12429,7 +12345,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {SyncGroupLogListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12437,34 +12353,32 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupLogListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, callback: ServiceCallback): void; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync agent. + * Cancels a sync group synchronization. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} serverName The name of the server. * - * @param {object} parameters The requested sync agent resource state. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12473,28 +12387,25 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync agent. + * Cancels a sync group synchronization. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} serverName The name of the server. * - * @param {object} parameters The requested sync agent resource state. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12508,7 +12419,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12516,29 +12427,30 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync agent. + * Triggers a sync group synchronization. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12551,19 +12463,21 @@ export interface SyncAgents { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + triggerSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync agent. + * Triggers a sync group synchronization. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12591,20 +12505,24 @@ export interface SyncAgents { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync agents in a server. + * Gets a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12613,21 +12531,25 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync agents in a server. + * Gets a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12641,7 +12563,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentListResult} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12649,29 +12571,55 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentListResult} for more information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Generates a sync agent key. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -12680,23 +12628,49 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - generateKeyWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates a sync agent key. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -12710,7 +12684,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentKeyProperties} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12718,30 +12692,31 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentKeyProperties} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentKeyProperties} for more - * information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists databases linked to a sync agent. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12750,23 +12725,25 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLinkedDatabasesWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists databases linked to a sync agent. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12780,7 +12757,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12788,35 +12765,54 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentLinkedDatabaseListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + /** - * Creates or updates a sync agent. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {object} parameters The requested sync agent resource state. + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -12825,28 +12821,49 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync agent. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {object} parameters The requested sync agent resource state. + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -12860,7 +12877,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12868,29 +12885,29 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync agent. + * Lists sync groups under a hub database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * * @param {object} [options] Optional Parameters. * @@ -12899,23 +12916,23 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync agent. + * Lists sync groups under a hub database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * * @param {object} [options] Optional Parameters. * @@ -12929,7 +12946,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12937,22 +12954,31 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync agents in a server. + * Refreshes a hub database schema. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12961,17 +12987,25 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginRefreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync agents in a server. + * Refreshes a hub database schema. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -12985,7 +13019,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12993,23 +13027,54 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentListResult} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists databases linked to a sync agent. + * Creates or updates a sync group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13018,17 +13083,49 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLinkedDatabasesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists databases linked to a sync agent. + * Creates or updates a sync group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13042,7 +13139,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13050,88 +13147,20 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentLinkedDatabaseListResult} for more - * information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLinkedDatabasesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLinkedDatabasesNext(nextPageLink: string, callback: ServiceCallback): void; - listLinkedDatabasesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncGroups - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncGroups { - - - /** - * Gets a collection of sync database ids. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listSyncDatabaseIdsWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a collection of sync database ids. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncDatabaseIdListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncDatabaseIdListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listSyncDatabaseIds(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listSyncDatabaseIds(locationName: string, callback: ServiceCallback): void; - listSyncDatabaseIds(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a hub database schema. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13155,10 +13184,10 @@ export interface SyncGroups { * * @reject {Error|ServiceError} - The error object. */ - refreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a hub database schema. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13197,13 +13226,13 @@ export interface SyncGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of hub database schemas. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13216,6 +13245,30 @@ export interface SyncGroups { * * @param {string} syncGroupName The name of the sync group. * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13223,14 +13276,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listHubSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of hub database schemas. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13243,6 +13296,30 @@ export interface SyncGroups { * * @param {string} syncGroupName The name of the sync group. * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13255,7 +13332,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13263,82 +13340,45 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of sync group logs. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {string} startTime Get logs generated after this time. - * - * @param {string} endTime Get logs generated before this time. + * Gets a collection of sync database ids. * - * @param {string} type The types of logs to retrieve. Possible values include: - * 'All', 'Error', 'Warning', 'Success' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.continuationToken] The continuation token for this - * operation. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLogsWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listSyncDatabaseIdsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of sync group logs. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {string} startTime Get logs generated after this time. - * - * @param {string} endTime Get logs generated before this time. + * Gets a collection of sync database ids. * - * @param {string} type The types of logs to retrieve. Possible values include: - * 'All', 'Error', 'Warning', 'Success' + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.continuationToken] The continuation token for this - * operation. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -13349,7 +13389,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroupLogListResult} - The deserialized result object. + * @resolve {SyncDatabaseIdListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13357,32 +13397,24 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupLogListResult} for more + * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncDatabaseIdListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, callback: ServiceCallback): void; - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listSyncDatabaseIdsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listSyncDatabaseIdsNext(nextPageLink: string, callback: ServiceCallback): void; + listSyncDatabaseIdsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels a sync group synchronization. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Gets a collection of hub database schemas. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13391,25 +13423,17 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - cancelSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listHubSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels a sync group synchronization. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Gets a collection of hub database schemas. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13423,7 +13447,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13431,57 +13455,101 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listHubSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listHubSchemasNext(nextPageLink: string, callback: ServiceCallback): void; + listHubSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Triggers a sync group synchronization. + * Gets a collection of sync group logs. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} serverName The name of the server. + * @param {object} [options] Optional Parameters. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} syncGroupName The name of the sync group. + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listLogsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a collection of sync group logs. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @returns {Promise} A promise is returned + * @param {ServiceCallback} [optionalCallback] - The optional callback. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. * - * @reject {Error|ServiceError} - The error object. + * {Promise} A promise is returned. + * + * @resolve {SyncGroupLogListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupLogListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - triggerSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLogsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLogsNext(nextPageLink: string, callback: ServiceCallback): void; + listLogsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + /** - * Triggers a sync group synchronization. + * Lists sync groups under a hub database. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * - * @param {string} serverName The name of the server. + * @param {object} [options] Optional Parameters. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} syncGroupName The name of the sync group. + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists sync groups under a hub database. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13495,7 +13563,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13503,19 +13571,29 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SyncMembers + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncMembers { /** - * Gets a sync group. + * Gets a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13526,7 +13604,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -13535,14 +13616,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync group. + * Gets a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13553,7 +13634,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -13567,7 +13651,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncMember} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13575,20 +13659,20 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync group. + * Creates or updates a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13599,31 +13683,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {object} parameters The requested sync group resource state. + * @param {string} syncMemberName The name of the sync member. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {object} parameters The requested sync member resource state. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member * - * @param {object} [parameters.schema] Sync schema of the sync group. + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} [parameters.userName] User name of the member database in + * the sync member. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -13632,14 +13722,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync group. + * Creates or updates a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13650,31 +13740,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {object} parameters The requested sync group resource state. + * @param {string} syncMemberName The name of the sync member. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {object} parameters The requested sync member resource state. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member * - * @param {object} [parameters.schema] Sync schema of the sync group. + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} [parameters.userName] User name of the member database in + * the sync member. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -13688,7 +13784,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncMember} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13696,20 +13792,20 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync group. + * Deletes a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13720,7 +13816,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -13733,10 +13832,10 @@ export interface SyncGroups { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync group. + * Deletes a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13747,7 +13846,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -13775,13 +13877,13 @@ export interface SyncGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a sync group. + * Updates an existing sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13792,31 +13894,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {object} parameters The requested sync group resource state. + * @param {string} syncMemberName The name of the sync member. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {object} parameters The requested sync member resource state. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member * - * @param {object} [parameters.schema] Sync schema of the sync group. + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} [parameters.userName] User name of the member database in + * the sync member. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -13825,14 +13933,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a sync group. + * Updates an existing sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13843,31 +13951,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {object} parameters The requested sync group resource state. + * @param {string} syncMemberName The name of the sync member. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {object} parameters The requested sync member resource state. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member * - * @param {object} [parameters.schema] Sync schema of the sync group. + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} [parameters.userName] User name of the member database in + * the sync member. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -13881,7 +13995,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncMember} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13889,20 +14003,20 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync groups under a hub database. + * Lists sync members in the given sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13913,6 +14027,8 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * + * @param {string} syncGroupName The name of the sync group. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13920,14 +14036,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listBySyncGroupWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync groups under a hub database. + * Lists sync members in the given sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13938,6 +14054,8 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * + * @param {string} syncGroupName The name of the sync group. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13950,7 +14068,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroupListResult} - The deserialized result object. + * @resolve {SyncMemberListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13958,20 +14076,20 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupListResult} for more information. + * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMemberListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a hub database schema. + * Gets a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13982,7 +14100,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -13991,14 +14112,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginRefreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listMemberSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a hub database schema. + * Gets a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14009,7 +14130,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -14023,7 +14147,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14031,19 +14155,21 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync group. + * Refreshes a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14054,31 +14180,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -14087,14 +14192,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + refreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync group. + * Refreshes a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14105,31 +14210,10 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -14143,7 +14227,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14151,20 +14235,19 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync group. + * Creates or updates a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14175,7 +14258,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -14184,14 +14297,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync group. + * Creates or updates a sync member. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14202,2732 +14315,37 @@ export interface SyncGroups { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Updates a sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates a sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncGroup} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a collection of sync database ids. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listSyncDatabaseIdsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a collection of sync database ids. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncDatabaseIdListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncDatabaseIdListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listSyncDatabaseIdsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listSyncDatabaseIdsNext(nextPageLink: string, callback: ServiceCallback): void; - listSyncDatabaseIdsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a collection of hub database schemas. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listHubSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a collection of hub database schemas. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listHubSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listHubSchemasNext(nextPageLink: string, callback: ServiceCallback): void; - listHubSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a collection of sync group logs. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listLogsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a collection of sync group logs. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncGroupLogListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupLogListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listLogsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLogsNext(nextPageLink: string, callback: ServiceCallback): void; - listLogsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists sync groups under a hub database. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists sync groups under a hub database. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncGroupListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupListResult} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncMembers - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncMembers { - - - /** - * Gets a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMember} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMember} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Updates an existing sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates an existing sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMember} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists sync members in the given sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listBySyncGroupWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists sync members in the given sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMemberListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMemberListResult} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listMemberSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Refreshes a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - refreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Refreshes a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMember} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes a sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Updates an existing sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Updates an existing sync member. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMember} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Refreshes a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginRefreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Refreshes a sync member database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists sync members in the given sync group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listBySyncGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists sync members in the given sync group. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncMemberListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMemberListResult} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listBySyncGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listBySyncGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listBySyncGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a sync member database schema. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listMemberSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a sync member database schema. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listMemberSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listMemberSchemasNext(nextPageLink: string, callback: ServiceCallback): void; - listMemberSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SubscriptionUsages - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SubscriptionUsages { - - - /** - * Gets all subscription usage metrics in a given location. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all subscription usage metrics in a given location. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SubscriptionUsageListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsageListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByLocation(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a subscription usage metric. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} usageName Name of usage metric to return. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a subscription usage metric. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} usageName Name of usage metric to return. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SubscriptionUsage} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SubscriptionUsage} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsage} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(locationName: string, usageName: string, callback: ServiceCallback): void; - get(locationName: string, usageName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets all subscription usage metrics in a given location. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets all subscription usage metrics in a given location. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SubscriptionUsageListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsageListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; - listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * VirtualNetworkRules - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface VirtualNetworkRules { - - - /** - * Gets a virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {VirtualNetworkRule} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates an existing virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates an existing virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {VirtualNetworkRule} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the virtual network rule with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the virtual network rule with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a list of virtual network rules in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a list of virtual network rules in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRuleListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Creates or updates an existing virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates an existing virtual network rule. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {VirtualNetworkRule} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes the virtual network rule with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes the virtual network rule with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a list of virtual network rules in a server. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a list of virtual network rules in a server. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRuleListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LongTermRetentionBackups - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface LongTermRetentionBackups { - - - /** - * Gets a long term retention backup. - * - * @param {string} locationName The location of the database. - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a long term retention backup. - * - * @param {string} locationName The location of the database. - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {LongTermRetentionBackup} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {LongTermRetentionBackup} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackup} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - deleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {null} [result] - The deserialized result object if an error did not occur. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists all long term retention backups for a database. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByDatabaseWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists all long term retention backups for a database. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, callback: ServiceCallback): void; - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists the long term retention backups for a given location. - * - * @param {string} locationName The location of the database - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists the long term retention backups for a given location. - * - * @param {string} locationName The location of the database - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByLocation(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists the long term retention backups for a given server. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - listByServerWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists the long term retention backups for a given server. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {object} [options] Optional Parameters. - * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - listByServer(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(locationName: string, longTermRetentionServerName: string, callback: ServiceCallback): void; - listByServer(locationName: string, longTermRetentionServerName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @returns {Promise} A promise is returned - * - * @resolve {HttpOperationResponse} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - */ - beginDeleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database - * - * @param {string} longTermRetentionServerName - * - * @param {string} longTermRetentionDatabaseName - * - * @param {string} backupName The backup name. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request - * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {null} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. * - * {null} [result] - The deserialized result object if an error did not occur. + * @param {string} syncMemberName The name of the sync member. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {object} parameters The requested sync member resource state. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Lists all long term retention backups for a database. + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. * - * @param {object} [options] Optional Parameters. + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member * - * @returns {Promise} A promise is returned + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.userName] User name of the member database in + * the sync member. * - * @reject {Error|ServiceError} - The error object. - */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists all long term retention backups for a database. + * @param {string} [parameters.password] Password of the member database in the + * sync member. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -16941,7 +14359,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {SyncMember} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16949,24 +14367,34 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the long term retention backups for a given location. + * Deletes a sync member. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -16975,17 +14403,28 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given location. + * Deletes a sync member. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -16999,7 +14438,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17007,24 +14446,60 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; - listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the long term retention backups for a given server. + * Updates an existing sync member. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -17033,17 +14508,55 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given server. + * Updates an existing sync member. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' * * @param {object} [options] Optional Parameters. * @@ -17057,7 +14570,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {SyncMember} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17065,30 +14578,20 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * BackupLongTermRetentionPolicies - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface BackupLongTermRetentionPolicies { + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a database's long term retention policy. + * Refreshes a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17096,7 +14599,13 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -17105,14 +14614,14 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginRefreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a database's long term retention policy. + * Refreshes a sync member database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17120,7 +14629,13 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. * * @param {object} [options] Optional Parameters. * @@ -17134,51 +14649,30 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. - * - * {WebResource} [request] - The HTTP Request object if an error did not occur. - * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - get(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Sets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @resolve {null} - The deserialized result object. * - * @param {string} serverName The name of the server. + * @reject {Error|ServiceError} - The error object. * - * @param {string} databaseName The name of the database. + * {ServiceCallback} optionalCallback(err, result, request, response) * - * @param {object} parameters The long term retention policy info. + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. + * {null} [result] - The deserialized result object if an error did not occur. * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. + * {WebResource} [request] - The HTTP Request object if an error did not occur. * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists sync members in the given sync group. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17187,36 +14681,17 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listBySyncGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Sets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * Lists sync members in the given sync group. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17230,7 +14705,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {SyncMemberListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17238,29 +14713,23 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. + * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMemberListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listBySyncGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listBySyncGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listBySyncGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Gets a sync member database schema. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17269,22 +14738,17 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listMemberSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Gets a sync member database schema. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17298,7 +14762,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17306,43 +14770,33 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listMemberSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listMemberSchemasNext(nextPageLink: string, callback: ServiceCallback): void; + listMemberSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SubscriptionUsages + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SubscriptionUsages { /** - * Sets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * Gets all subscription usage metrics in a given location. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -17351,36 +14805,17 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Sets a database's long term retention policy. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * Gets all subscription usage metrics in a given location. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -17394,7 +14829,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {SubscriptionUsageListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17402,41 +14837,26 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more + * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsageListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ManagedDatabases - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ManagedDatabases { + listByLocation(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Completes the restore operation on a managed database. + * Gets a subscription usage metric. * * @param {string} locationName The name of the region where the resource is * located. * - * @param {uuid} operationId Management operation id that this request tries to - * complete. - * - * @param {object} parameters The definition for completing the restore of this - * managed database. - * - * @param {string} parameters.lastBackupName The last backup name to apply + * @param {string} usageName Name of usage metric to return. * * @param {object} [options] Optional Parameters. * @@ -17445,25 +14865,19 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - completeRestoreWithHttpOperationResponse(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Completes the restore operation on a managed database. + * Gets a subscription usage metric. * * @param {string} locationName The name of the region where the resource is * located. * - * @param {uuid} operationId Management operation id that this request tries to - * complete. - * - * @param {object} parameters The definition for completing the restore of this - * managed database. - * - * @param {string} parameters.lastBackupName The last backup name to apply + * @param {string} usageName Name of usage metric to return. * * @param {object} [options] Optional Parameters. * @@ -17477,7 +14891,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SubscriptionUsage} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17485,25 +14899,23 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SubscriptionUsage} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsage} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, callback: ServiceCallback): void; - completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(locationName: string, usageName: string, callback: ServiceCallback): void; + get(locationName: string, usageName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of managed databases. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets all subscription usage metrics in a given location. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17512,20 +14924,17 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByInstanceWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of managed databases. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets all subscription usage metrics in a given location. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17539,7 +14948,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabaseListResult} - The deserialized result object. + * @resolve {SubscriptionUsageListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17547,29 +14956,38 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabaseListResult} for more + * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsageListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByInstance(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByInstance(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; - listByInstance(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworkRules + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface VirtualNetworkRules { /** - * Gets a managed database. + * Gets a virtual network rule. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -17578,22 +14996,22 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a managed database. + * Gets a virtual network rule. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -17607,7 +15025,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabase} - The deserialized result object. + * @resolve {VirtualNetworkRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17615,64 +15033,37 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabase} for more information. + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a new database or updates an existing database. + * Creates or updates an existing virtual network rule. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. + * @param {string} serverName The name of the server. * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. + * @param {object} parameters The requested virtual Network Rule Resource + * state. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. * - * @param {string} parameters.location Resource location. + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. * * @param {object} [options] Optional Parameters. * @@ -17681,58 +15072,31 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a new database or updates an existing database. + * Creates or updates an existing virtual network rule. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. + * @param {string} serverName The name of the server. * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. + * @param {object} parameters The requested virtual Network Rule Resource + * state. * - * @param {object} [parameters.tags] Resource tags. + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. * - * @param {string} parameters.location Resource location. + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. * * @param {object} [options] Optional Parameters. * @@ -17746,7 +15110,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabase} - The deserialized result object. + * @resolve {VirtualNetworkRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17754,28 +15118,28 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabase} for more information. + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the managed database. + * Deletes the virtual network rule with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -17788,18 +15152,18 @@ export interface ManagedDatabases { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the managed database. + * Deletes the virtual network rule with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. + * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -17827,55 +15191,19 @@ export interface ManagedDatabases { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an existing database. + * Gets a list of virtual network rules in a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. - * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -17884,56 +15212,20 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an existing database. + * Gets a list of virtual network rules in a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. - * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -17947,7 +15239,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabase} - The deserialized result object. + * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17955,31 +15247,38 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabase} for more information. + * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, callback: ServiceCallback): void; - update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Completes the restore operation on a managed database. + * Creates or updates an existing virtual network rule. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * - * @param {uuid} operationId Management operation id that this request tries to - * complete. + * @param {object} parameters The requested virtual Network Rule Resource + * state. * - * @param {object} parameters The definition for completing the restore of this - * managed database. + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. * - * @param {string} parameters.lastBackupName The last backup name to apply + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. * * @param {object} [options] Optional Parameters. * @@ -17988,25 +15287,31 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCompleteRestoreWithHttpOperationResponse(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Completes the restore operation on a managed database. + * Creates or updates an existing virtual network rule. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. * - * @param {uuid} operationId Management operation id that this request tries to - * complete. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} parameters The requested virtual Network Rule Resource + * state. * - * @param {object} parameters The definition for completing the restore of this - * managed database. + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. * - * @param {string} parameters.lastBackupName The last backup name to apply + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. * * @param {object} [options] Optional Parameters. * @@ -18020,7 +15325,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VirtualNetworkRule} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18028,63 +15333,28 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, callback: ServiceCallback): void; - beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a new database or updates an existing database. + * Deletes the virtual network rule with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. - * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} serverName The name of the server. * - * @param {string} parameters.location Resource location. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -18093,58 +15363,22 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a new database or updates an existing database. + * Deletes the virtual network rule with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' - * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. - * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. - * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. - * - * @param {object} [parameters.tags] Resource tags. + * @param {string} serverName The name of the server. * - * @param {string} parameters.location Resource location. + * @param {string} virtualNetworkRuleName The name of the virtual network rule. * * @param {object} [options] Optional Parameters. * @@ -18158,7 +15392,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabase} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18166,28 +15400,22 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabase} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the managed database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} managedInstanceName The name of the managed instance. + * Gets a list of virtual network rules in a server. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18196,22 +15424,17 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the managed database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} managedInstanceName The name of the managed instance. + * Gets a list of virtual network rules in a server. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18225,7 +15448,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18233,61 +15456,38 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRuleListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LongTermRetentionBackups + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface LongTermRetentionBackups { /** - * Updates an existing database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * Gets a long term retention backup. * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. + * @param {string} locationName The location of the database. * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. + * @param {string} longTermRetentionServerName * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. + * @param {string} longTermRetentionDatabaseName * - * @param {object} [parameters.tags] Resource tags. + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18296,56 +15496,22 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an existing database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} managedInstanceName The name of the managed instance. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The requested database resource state. - * - * @param {string} [parameters.collation] Collation of the managed database. - * - * @param {date} [parameters.restorePointInTime] Conditional. If createMode is - * PointInTimeRestore, this value is required. Specifies the point in time - * (ISO8601 format) of the source database that will be restored to create the - * new database. - * - * @param {string} [parameters.catalogCollation] Collation of the metadata - * catalog. Possible values include: 'DATABASE_DEFAULT', - * 'SQL_Latin1_General_CP1_CI_AS' - * - * @param {string} [parameters.createMode] Managed database create mode. - * PointInTimeRestore: Create a database by restoring a point in time backup of - * an existing database. SourceDatabaseName, SourceManagedInstanceName and - * PointInTime must be specified. RestoreExternalBackup: Create a database by - * restoring from external backup files. Collation, StorageContainerUri and - * StorageContainerSasToken must be specified. Possible values include: - * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * Gets a long term retention backup. * - * @param {string} [parameters.storageContainerUri] Conditional. If createMode - * is RestoreExternalBackup, this value is required. Specifies the uri of the - * storage container where backups for this restore are stored. + * @param {string} locationName The location of the database. * - * @param {string} [parameters.sourceDatabaseId] The resource identifier of the - * source database associated with create operation of this database. + * @param {string} longTermRetentionServerName * - * @param {string} [parameters.storageContainerSasToken] Conditional. If - * createMode is RestoreExternalBackup, this value is required. Specifies the - * storage container sas token. + * @param {string} longTermRetentionDatabaseName * - * @param {object} [parameters.tags] Resource tags. + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18359,7 +15525,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabase} - The deserialized result object. + * @resolve {LongTermRetentionBackup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18367,23 +15533,29 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabase} for more information. + * {LongTermRetentionBackup} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackup} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of managed databases. + * Deletes a long term retention backup. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18392,17 +15564,22 @@ export interface ManagedDatabases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByInstanceNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of managed databases. + * Deletes a long term retention backup. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18416,7 +15593,7 @@ export interface ManagedDatabases { * * {Promise} A promise is returned. * - * @resolve {ManagedDatabaseListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18424,61 +15601,64 @@ export interface ManagedDatabases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ManagedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ManagedDatabaseListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByInstanceNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByInstanceNext(nextPageLink: string, callback: ServiceCallback): void; - listByInstanceNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ServerAutomaticTuningOperations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ServerAutomaticTuningOperations { + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Retrieves server automatic tuning options. + * Lists all long term retention backups for a database. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} locationName The location of the database * - * @param {string} serverName The name of the server. + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName * * @param {object} [options] Optional Parameters. * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves server automatic tuning options. + * Lists all long term retention backups for a database. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} locationName The location of the database * - * @param {string} serverName The name of the server. + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName * * @param {object} [options] Optional Parameters. * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -18489,7 +15669,7 @@ export interface ServerAutomaticTuningOperations { * * {Promise} A promise is returned. * - * @resolve {ServerAutomaticTuning} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18497,64 +15677,57 @@ export interface ServerAutomaticTuningOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. - * See {@link ServerAutomaticTuning} for more information. + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, callback: ServiceCallback): void; + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Update automatic tuning options on server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists the long term retention backups for a given location. * - * @param {object} parameters The requested automatic tuning resource state. + * @param {string} locationName The location of the database * - * @param {string} [parameters.desiredState] Automatic tuning desired state. - * Possible values include: 'Custom', 'Auto', 'Unspecified' + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.options] Automatic tuning options definition. + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. * - * @param {object} [options] Optional Parameters. + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationWithHttpOperationResponse(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Update automatic tuning options on server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists the long term retention backups for a given location. * - * @param {object} parameters The requested automatic tuning resource state. + * @param {string} locationName The location of the database * - * @param {string} [parameters.desiredState] Automatic tuning desired state. - * Possible values include: 'Custom', 'Auto', 'Unspecified' + * @param {object} [options] Optional Parameters. * - * @param {object} [parameters.options] Automatic tuning options definition. + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. * - * @param {object} [options] Optional Parameters. + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -18566,7 +15739,7 @@ export interface ServerAutomaticTuningOperations { * * {Promise} A promise is returned. * - * @resolve {ServerAutomaticTuning} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18574,66 +15747,62 @@ export interface ServerAutomaticTuningOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. - * See {@link ServerAutomaticTuning} for more information. + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ServerDnsAliases - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ServerDnsAliases { + listByLocation(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a server DNS alias. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Lists the long term retention backups for a given server. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The location of the database * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} longTermRetentionServerName * * @param {object} [options] Optional Parameters. * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a server DNS alias. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Lists the long term retention backups for a given server. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The location of the database * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} longTermRetentionServerName * * @param {object} [options] Optional Parameters. * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -18644,7 +15813,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18652,29 +15821,29 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(locationName: string, longTermRetentionServerName: string, callback: ServiceCallback): void; + listByServer(locationName: string, longTermRetentionServerName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a server dns alias. + * Deletes a long term retention backup. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} locationName The location of the database * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} longTermRetentionServerName * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18683,23 +15852,22 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a server dns alias. + * Deletes a long term retention backup. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} locationName The location of the database * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} longTermRetentionServerName * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. * * @param {object} [options] Optional Parameters. * @@ -18713,7 +15881,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18721,29 +15889,22 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server DNS alias with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * Lists all long term retention backups for a database. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18752,23 +15913,17 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server DNS alias with the given name. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * Lists all long term retention backups for a database. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18782,7 +15937,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18790,26 +15945,24 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server DNS aliases for a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Lists the long term retention backups for a given location. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18818,21 +15971,17 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server DNS aliases for a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Lists the long term retention backups for a given location. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18846,7 +15995,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAliasListResult} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18854,35 +16003,24 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAliasListResult} for more + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Acquires server DNS alias from another server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * Lists the long term retention backups for a given server. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18891,28 +16029,17 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - acquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Acquires server DNS alias from another server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * Lists the long term retention backups for a given server. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -18926,7 +16053,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18934,28 +16061,38 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * BackupLongTermRetentionPolicies + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface BackupLongTermRetentionPolicies { /** - * Creates a server dns alias. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -18964,23 +16101,22 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a server dns alias. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -18994,7 +16130,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19002,29 +16138,43 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server DNS alias with the given name. + * Sets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -19033,23 +16183,36 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server DNS alias with the given name. + * Sets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -19063,7 +16226,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19071,33 +16234,29 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Acquires server DNS alias from another server. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * @param {string} serverName The name of the server. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -19106,28 +16265,22 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginAcquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Acquires server DNS alias from another server. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * @param {string} serverName The name of the server. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -19141,7 +16294,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19149,22 +16302,43 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server DNS aliases for a server. + * Sets a database's long term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -19173,17 +16347,36 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server DNS aliases for a server. + * Sets a database's long term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -19197,7 +16390,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAliasListResult} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19205,30 +16398,30 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAliasListResult} for more + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * RestorePoints + * ServerAutomaticTuningOperations * __NOTE__: An instance of this class is automatically created for an * instance of the SqlManagementClient. */ -export interface RestorePoints { +export interface ServerAutomaticTuningOperations { /** - * Gets a list of database restore points. + * Retrieves server automatic tuning options. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -19236,8 +16429,6 @@ export interface RestorePoints { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -19245,14 +16436,14 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of database restore points. + * Retrieves server automatic tuning options. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -19260,8 +16451,6 @@ export interface RestorePoints { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -19274,7 +16463,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePointListResult} - The deserialized result object. + * @resolve {ServerAutomaticTuning} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19282,21 +16471,20 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePointListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePointListResult} for more - * information. + * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. + * See {@link ServerAutomaticTuning} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a restore point for a data warehouse. + * Update automatic tuning options on server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -19304,13 +16492,12 @@ export interface RestorePoints { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {object} parameters The requested automatic tuning resource state. * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} [parameters.desiredState] Automatic tuning desired state. + * Possible values include: 'Custom', 'Auto', 'Unspecified' * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {object} [parameters.options] Automatic tuning options definition. * * @param {object} [options] Optional Parameters. * @@ -19319,14 +16506,14 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a restore point for a data warehouse. + * Update automatic tuning options on server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -19334,13 +16521,12 @@ export interface RestorePoints { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {object} parameters The requested automatic tuning resource state. * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} [parameters.desiredState] Automatic tuning desired state. + * Possible values include: 'Custom', 'Auto', 'Unspecified' * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {object} [parameters.options] Automatic tuning options definition. * * @param {object} [options] Optional Parameters. * @@ -19354,7 +16540,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {ServerAutomaticTuning} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19362,30 +16548,38 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. + * See {@link ServerAutomaticTuning} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ServerDnsAliases + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ServerDnsAliases { /** - * Gets a restore point. + * Gets a server DNS alias. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} restorePointName The name of the restore point. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19394,24 +16588,23 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a restore point. + * Gets a server DNS alias. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} restorePointName The name of the restore point. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19425,7 +16618,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19433,30 +16626,29 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a restore point. + * Creates a server dns alias. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Manager API or the portal. * - * @param {string} databaseName The name of the database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} restorePointName The name of the restore point. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19465,24 +16657,23 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a restore point. + * Creates a server dns alias. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} restorePointName The name of the restore point. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19496,7 +16687,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19504,33 +16695,29 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a restore point for a data warehouse. + * Deletes the server DNS alias with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19539,28 +16726,23 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a restore point for a data warehouse. + * Deletes the server DNS alias with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19574,7 +16756,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19582,39 +16764,26 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * DatabaseOperations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface DatabaseOperations { + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels the asynchronous operation on the database. + * Gets a list of server DNS aliases for a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {uuid} operationId The operation identifier. + * @param {string} serverName The name of the server that the alias is pointing + * to. * * @param {object} [options] Optional Parameters. * @@ -19623,24 +16792,21 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels the asynchronous operation on the database. + * Gets a list of server DNS aliases for a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {uuid} operationId The operation identifier. + * @param {string} serverName The name of the server that the alias is pointing + * to. * * @param {object} [options] Optional Parameters. * @@ -19654,7 +16820,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ServerDnsAliasListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19662,27 +16828,35 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAliasListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, callback: ServiceCallback): void; - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the database. + * Acquires server DNS alias from another server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} databaseName The name of the database. + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -19691,22 +16865,28 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + acquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the database. + * Acquires server DNS alias from another server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} databaseName The name of the database. + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -19720,7 +16900,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {DatabaseOperationListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19728,24 +16908,28 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DatabaseOperationListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the database. + * Creates a server dns alias. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19754,17 +16938,23 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the database. + * Creates a server dns alias. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19778,7 +16968,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {DatabaseOperationListResult} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19786,40 +16976,29 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DatabaseOperationListResult} for more - * information. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ElasticPoolOperations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ElasticPoolOperations { + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels the asynchronous operation on the elastic pool. + * Deletes the server DNS alias with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} elasticPoolName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {uuid} operationId The operation identifier. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19832,20 +17011,19 @@ export interface ElasticPoolOperations { * * @reject {Error|ServiceError} - The error object. */ - cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels the asynchronous operation on the elastic pool. + * Deletes the server DNS alias with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} elasticPoolName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {uuid} operationId The operation identifier. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -19873,21 +17051,27 @@ export interface ElasticPoolOperations { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, callback: ServiceCallback): void; - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the elastic pool. + * Acquires server DNS alias from another server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} elasticPoolName + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -19896,22 +17080,28 @@ export interface ElasticPoolOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByElasticPoolWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginAcquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the elastic pool. + * Acquires server DNS alias from another server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} elasticPoolName + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -19925,7 +17115,7 @@ export interface ElasticPoolOperations { * * {Promise} A promise is returned. * - * @resolve {ElasticPoolOperationListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19933,21 +17123,19 @@ export interface ElasticPoolOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ElasticPoolOperationListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, callback: ServiceCallback): void; - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the elastic pool. + * Gets a list of server DNS aliases for a server. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -19959,14 +17147,14 @@ export interface ElasticPoolOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByElasticPoolNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the elastic pool. + * Gets a list of server DNS aliases for a server. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -19983,7 +17171,7 @@ export interface ElasticPoolOperations { * * {Promise} A promise is returned. * - * @resolve {ElasticPoolOperationListResult} - The deserialized result object. + * @resolve {ServerDnsAliasListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -19991,64 +17179,64 @@ export interface ElasticPoolOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ElasticPoolOperationListResult} for more + * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAliasListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByElasticPoolNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByElasticPoolNext(nextPageLink: string, callback: ServiceCallback): void; - listByElasticPoolNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * Capabilities + * RestorePoints * __NOTE__: An instance of this class is automatically created for an * instance of the SqlManagementClient. */ -export interface Capabilities { +export interface RestorePoints { /** - * Gets the subscription capabilities available for the specified location. + * Gets a list of database restore points. * - * @param {string} locationName The location name whose capabilities are - * retrieved. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server. * - * @param {string} [options.include] If specified, restricts the response to - * only include the selected item. Possible values include: - * 'supportedEditions', 'supportedElasticPoolEditions', - * 'supportedManagedInstanceVersions' + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the subscription capabilities available for the specified location. + * Gets a list of database restore points. * - * @param {string} locationName The location name whose capabilities are - * retrieved. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server. * - * @param {string} [options.include] If specified, restricts the response to - * only include the selected item. Possible values include: - * 'supportedEditions', 'supportedElasticPoolEditions', - * 'supportedManagedInstanceVersions' + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -20060,7 +17248,7 @@ export interface Capabilities { * * {Promise} A promise is returned. * - * @resolve {LocationCapabilities} - The deserialized result object. + * @resolve {RestorePointListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20068,38 +17256,35 @@ export interface Capabilities { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocationCapabilities} [result] - The deserialized result object if an error did not occur. - * See {@link LocationCapabilities} for more information. + * {RestorePointListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePointListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocation(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { include? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * InstanceFailoverGroups - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface InstanceFailoverGroups { + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a failover group. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -20108,23 +17293,28 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a failover group. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -20138,7 +17328,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20146,58 +17336,30 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a failover group. + * Gets a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} failoverGroupName The name of the failover group. - * - * @param {object} parameters The failover group parameters. - * - * @param {object} parameters.readWriteEndpoint Read-write endpoint of the - * failover group instance. - * - * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy - * of the read-write endpoint for the failover group. If failoverPolicy is - * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible - * values include: 'Manual', 'Automatic' - * - * @param {number} - * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace - * period before failover with data loss is attempted for the read-write - * endpoint. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. - * - * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the - * failover group instance. - * - * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy - * of the read-only endpoint for the failover group. Possible values include: - * 'Disabled', 'Enabled' + * @param {string} serverName The name of the server. * - * @param {array} parameters.partnerRegions Partner region information for the - * failover group. + * @param {string} databaseName The name of the database. * - * @param {array} parameters.managedInstancePairs List of managed instance - * pairs in the failover group. + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -20206,52 +17368,24 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a failover group. + * Gets a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} failoverGroupName The name of the failover group. - * - * @param {object} parameters The failover group parameters. - * - * @param {object} parameters.readWriteEndpoint Read-write endpoint of the - * failover group instance. - * - * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy - * of the read-write endpoint for the failover group. If failoverPolicy is - * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible - * values include: 'Manual', 'Automatic' - * - * @param {number} - * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace - * period before failover with data loss is attempted for the read-write - * endpoint. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. - * - * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the - * failover group instance. - * - * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy - * of the read-only endpoint for the failover group. Possible values include: - * 'Disabled', 'Enabled' + * @param {string} serverName The name of the server. * - * @param {array} parameters.partnerRegions Partner region information for the - * failover group. + * @param {string} databaseName The name of the database. * - * @param {array} parameters.managedInstancePairs List of managed instance - * pairs in the failover group. + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -20265,7 +17399,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20273,29 +17407,30 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a failover group. + * Deletes a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -20308,19 +17443,20 @@ export interface InstanceFailoverGroups { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a failover group. + * Deletes a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -20348,20 +17484,27 @@ export interface InstanceFailoverGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the failover groups in a location. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -20370,21 +17513,28 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationWithHttpOperationResponse(resourceGroupName: string, locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the failover groups in a location. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -20398,7 +17548,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroupListResult} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20406,31 +17556,39 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroupListResult} for more - * information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocation(resourceGroupName: string, locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(resourceGroupName: string, locationName: string, callback: ServiceCallback): void; - listByLocation(resourceGroupName: string, locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * DatabaseOperations + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface DatabaseOperations { /** - * Fails over from the current primary managed instance to this managed - * instance. + * Cancels the asynchronous operation on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -20439,24 +17597,24 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - failoverWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Fails over from the current primary managed instance to this managed - * instance. + * Cancels the asynchronous operation on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -20470,7 +17628,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20478,30 +17636,27 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - failover(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - failover(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - failover(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Fails over from the current primary managed instance to this managed - * instance. This operation might result in data loss. + * Gets a list of operations performed on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -20510,24 +17665,22 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - forceFailoverAllowDataLossWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Fails over from the current primary managed instance to this managed - * instance. This operation might result in data loss. + * Gets a list of operations performed on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -20541,7 +17694,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {DatabaseOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20549,58 +17702,24 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DatabaseOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a failover group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} failoverGroupName The name of the failover group. - * - * @param {object} parameters The failover group parameters. - * - * @param {object} parameters.readWriteEndpoint Read-write endpoint of the - * failover group instance. - * - * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy - * of the read-write endpoint for the failover group. If failoverPolicy is - * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible - * values include: 'Manual', 'Automatic' - * - * @param {number} - * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace - * period before failover with data loss is attempted for the read-write - * endpoint. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. - * - * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the - * failover group instance. - * - * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy - * of the read-only endpoint for the failover group. Possible values include: - * 'Disabled', 'Enabled' - * - * @param {array} parameters.partnerRegions Partner region information for the - * failover group. + * Gets a list of operations performed on the database. * - * @param {array} parameters.managedInstancePairs List of managed instance - * pairs in the failover group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -20609,52 +17728,17 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a failover group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} locationName The name of the region where the resource is - * located. - * - * @param {string} failoverGroupName The name of the failover group. - * - * @param {object} parameters The failover group parameters. - * - * @param {object} parameters.readWriteEndpoint Read-write endpoint of the - * failover group instance. - * - * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy - * of the read-write endpoint for the failover group. If failoverPolicy is - * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible - * values include: 'Manual', 'Automatic' - * - * @param {number} - * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace - * period before failover with data loss is attempted for the read-write - * endpoint. If failoverPolicy is Automatic then - * failoverWithDataLossGracePeriodMinutes is required. - * - * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the - * failover group instance. - * - * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy - * of the read-only endpoint for the failover group. Possible values include: - * 'Disabled', 'Enabled' - * - * @param {array} parameters.partnerRegions Partner region information for the - * failover group. + * Gets a list of operations performed on the database. * - * @param {array} parameters.managedInstancePairs List of managed instance - * pairs in the failover group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -20668,7 +17752,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {DatabaseOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20676,29 +17760,40 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DatabaseOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ElasticPoolOperations + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ElasticPoolOperations { /** - * Deletes a failover group. + * Cancels the asynchronous operation on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} elasticPoolName + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -20711,19 +17806,20 @@ export interface InstanceFailoverGroups { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a failover group. + * Cancels the asynchronous operation on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} elasticPoolName + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -20751,23 +17847,21 @@ export interface InstanceFailoverGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Fails over from the current primary managed instance to this managed - * instance. + * Gets a list of operations performed on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} elasticPoolName * * @param {object} [options] Optional Parameters. * @@ -20776,24 +17870,22 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginFailoverWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByElasticPoolWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Fails over from the current primary managed instance to this managed - * instance. + * Gets a list of operations performed on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} serverName The name of the server. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} elasticPoolName * * @param {object} [options] Optional Parameters. * @@ -20807,7 +17899,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {ElasticPoolOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20815,30 +17907,24 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ElasticPoolOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, callback: ServiceCallback): void; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Fails over from the current primary managed instance to this managed - * instance. This operation might result in data loss. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} locationName The name of the region where the resource is - * located. + * Gets a list of operations performed on the elastic pool. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -20847,24 +17933,17 @@ export interface InstanceFailoverGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginForceFailoverAllowDataLossWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByElasticPoolNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Fails over from the current primary managed instance to this managed - * instance. This operation might result in data loss. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} locationName The name of the region where the resource is - * located. + * Gets a list of operations performed on the elastic pool. * - * @param {string} failoverGroupName The name of the failover group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -20878,7 +17957,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroup} - The deserialized result object. + * @resolve {ElasticPoolOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20886,45 +17965,65 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroup} for more information. + * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ElasticPoolOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; - beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByElasticPoolNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByElasticPoolNext(nextPageLink: string, callback: ServiceCallback): void; + listByElasticPoolNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Capabilities + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface Capabilities { /** - * Lists the failover groups in a location. + * Gets the subscription capabilities available for the specified location. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The location name whose capabilities are + * retrieved. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.include] If specified, restricts the response to + * only include the selected item. Possible values include: + * 'supportedEditions', 'supportedElasticPoolEditions', + * 'supportedManagedInstanceVersions' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationWithHttpOperationResponse(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the failover groups in a location. + * Gets the subscription capabilities available for the specified location. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The location name whose capabilities are + * retrieved. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.include] If specified, restricts the response to + * only include the selected item. Possible values include: + * 'supportedEditions', 'supportedElasticPoolEditions', + * 'supportedManagedInstanceVersions' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -20935,7 +18034,7 @@ export interface InstanceFailoverGroups { * * {Promise} A promise is returned. * - * @resolve {InstanceFailoverGroupListResult} - The deserialized result object. + * @resolve {LocationCapabilities} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -20943,15 +18042,14 @@ export interface InstanceFailoverGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {InstanceFailoverGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link InstanceFailoverGroupListResult} for more - * information. + * {LocationCapabilities} [result] - The deserialized result object if an error did not occur. + * See {@link LocationCapabilities} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; - listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByLocation(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { include? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } diff --git a/lib/services/sqlManagement2/lib/operations/index.js b/lib/services/sqlManagement2/lib/operations/index.js index c8f3d9bcdd..56d738959a 100644 --- a/lib/services/sqlManagement2/lib/operations/index.js +++ b/lib/services/sqlManagement2/lib/operations/index.js @@ -41,7 +41,6 @@ exports.DatabaseBlobAuditingPolicies = require('./databaseBlobAuditingPolicies') exports.DatabaseAutomaticTuningOperations = require('./databaseAutomaticTuningOperations'); exports.EncryptionProtectors = require('./encryptionProtectors'); exports.FailoverGroups = require('./failoverGroups'); -exports.ManagedInstances = require('./managedInstances'); exports.Operations = require('./operations'); exports.ServerKeys = require('./serverKeys'); exports.SyncAgents = require('./syncAgents'); @@ -51,11 +50,9 @@ exports.SubscriptionUsages = require('./subscriptionUsages'); exports.VirtualNetworkRules = require('./virtualNetworkRules'); exports.LongTermRetentionBackups = require('./longTermRetentionBackups'); exports.BackupLongTermRetentionPolicies = require('./backupLongTermRetentionPolicies'); -exports.ManagedDatabases = require('./managedDatabases'); exports.ServerAutomaticTuningOperations = require('./serverAutomaticTuningOperations'); exports.ServerDnsAliases = require('./serverDnsAliases'); exports.RestorePoints = require('./restorePoints'); exports.DatabaseOperations = require('./databaseOperations'); exports.ElasticPoolOperations = require('./elasticPoolOperations'); exports.Capabilities = require('./capabilities'); -exports.InstanceFailoverGroups = require('./instanceFailoverGroups'); diff --git a/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts b/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts index 4877fafd88..951e647e01 100644 --- a/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts +++ b/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts @@ -81,7 +81,6 @@ export default class SqlManagementClient extends AzureServiceClient { databaseAutomaticTuningOperations: operations.DatabaseAutomaticTuningOperations; encryptionProtectors: operations.EncryptionProtectors; failoverGroups: operations.FailoverGroups; - managedInstances: operations.ManagedInstances; operations: operations.Operations; serverKeys: operations.ServerKeys; syncAgents: operations.SyncAgents; @@ -91,14 +90,12 @@ export default class SqlManagementClient extends AzureServiceClient { virtualNetworkRules: operations.VirtualNetworkRules; longTermRetentionBackups: operations.LongTermRetentionBackups; backupLongTermRetentionPolicies: operations.BackupLongTermRetentionPolicies; - managedDatabases: operations.ManagedDatabases; serverAutomaticTuningOperations: operations.ServerAutomaticTuningOperations; serverDnsAliases: operations.ServerDnsAliases; restorePoints: operations.RestorePoints; databaseOperations: operations.DatabaseOperations; elasticPoolOperations: operations.ElasticPoolOperations; capabilities: operations.Capabilities; - instanceFailoverGroups: operations.InstanceFailoverGroups; } export { SqlManagementClient, models as SqlManagementModels }; diff --git a/lib/services/sqlManagement2/lib/sqlManagementClient.js b/lib/services/sqlManagement2/lib/sqlManagementClient.js index 76cf74c0a5..4c2f9a8ebd 100644 --- a/lib/services/sqlManagement2/lib/sqlManagementClient.js +++ b/lib/services/sqlManagement2/lib/sqlManagementClient.js @@ -98,7 +98,6 @@ class SqlManagementClient extends ServiceClient { this.databaseAutomaticTuningOperations = new operations.DatabaseAutomaticTuningOperations(this); this.encryptionProtectors = new operations.EncryptionProtectors(this); this.failoverGroups = new operations.FailoverGroups(this); - this.managedInstances = new operations.ManagedInstances(this); this.operations = new operations.Operations(this); this.serverKeys = new operations.ServerKeys(this); this.syncAgents = new operations.SyncAgents(this); @@ -108,14 +107,12 @@ class SqlManagementClient extends ServiceClient { this.virtualNetworkRules = new operations.VirtualNetworkRules(this); this.longTermRetentionBackups = new operations.LongTermRetentionBackups(this); this.backupLongTermRetentionPolicies = new operations.BackupLongTermRetentionPolicies(this); - this.managedDatabases = new operations.ManagedDatabases(this); this.serverAutomaticTuningOperations = new operations.ServerAutomaticTuningOperations(this); this.serverDnsAliases = new operations.ServerDnsAliases(this); this.restorePoints = new operations.RestorePoints(this); this.databaseOperations = new operations.DatabaseOperations(this); this.elasticPoolOperations = new operations.ElasticPoolOperations(this); this.capabilities = new operations.Capabilities(this); - this.instanceFailoverGroups = new operations.InstanceFailoverGroups(this); this.models = models; msRest.addSerializationMixin(this); } From af5d08a9c6c011b3c461a01e25e089c3b3d48e33 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Fri, 20 Apr 2018 06:58:12 +0000 Subject: [PATCH 2/2] Generated from c5b0234ad63d8130d3f2af0d43aed548bf0c20eb Merge branch 'master' into master --- .../sqlManagement2/lib/models/index.d.ts | 445 +- .../sqlManagement2/lib/models/index.js | 18 +- .../lib/models/shortTermRetentionPolicy.js | 81 + .../sqlManagement2/lib/operations/index.d.ts | 8199 ++++++++++++----- .../sqlManagement2/lib/operations/index.js | 4 + .../operations/shortTermRetentionPolicies.js | 1231 +++ .../lib/sqlManagementClient.d.ts | 4 + .../sqlManagement2/lib/sqlManagementClient.js | 4 + 8 files changed, 7490 insertions(+), 2496 deletions(-) create mode 100644 lib/services/sqlManagement2/lib/models/shortTermRetentionPolicy.js create mode 100644 lib/services/sqlManagement2/lib/operations/shortTermRetentionPolicies.js diff --git a/lib/services/sqlManagement2/lib/models/index.d.ts b/lib/services/sqlManagement2/lib/models/index.d.ts index e291789c89..363749ddaa 100644 --- a/lib/services/sqlManagement2/lib/models/index.d.ts +++ b/lib/services/sqlManagement2/lib/models/index.d.ts @@ -1292,6 +1292,140 @@ export interface FailoverGroupUpdate { tags?: { [propertyName: string]: string }; } +/** + * @class + * Initializes a new instance of the ResourceIdentity class. + * @constructor + * Azure Active Directory identity configuration for a resource. + * + * @member {uuid} [principalId] The Azure Active Directory principal id. + * @member {string} [type] The identity type. Set this to 'SystemAssigned' in + * order to automatically create and assign an Azure Active Directory principal + * for the resource. Possible values include: 'SystemAssigned' + * @member {uuid} [tenantId] The Azure Active Directory tenant id. + */ +export interface ResourceIdentity { + readonly principalId?: string; + type?: string; + readonly tenantId?: string; +} + +/** + * @class + * Initializes a new instance of the Sku class. + * @constructor + * An ARM Resource SKU. + * + * @member {string} name The name of the SKU, typically, a letter + Number + * code, e.g. P3. + * @member {string} [tier] The tier of the particular SKU, e.g. Basic, Premium. + * @member {string} [size] Size of the particular SKU + * @member {string} [family] If the service has different generations of + * hardware, for the same SKU, then that can be captured here. + * @member {number} [capacity] Capacity of the particular SKU. + */ +export interface Sku { + name: string; + tier?: string; + size?: string; + family?: string; + capacity?: number; +} + +/** + * @class + * Initializes a new instance of the ManagedInstance class. + * @constructor + * An Azure SQL managed instance. + * + * @member {object} [identity] The Azure Active Directory identity of the + * managed instance. + * @member {uuid} [identity.principalId] The Azure Active Directory principal + * id. + * @member {string} [identity.type] The identity type. Set this to + * 'SystemAssigned' in order to automatically create and assign an Azure Active + * Directory principal for the resource. Possible values include: + * 'SystemAssigned' + * @member {uuid} [identity.tenantId] The Azure Active Directory tenant id. + * @member {object} [sku] Managed instance sku + * @member {string} [sku.name] The name of the SKU, typically, a letter + + * Number code, e.g. P3. + * @member {string} [sku.tier] The tier of the particular SKU, e.g. Basic, + * Premium. + * @member {string} [sku.size] Size of the particular SKU + * @member {string} [sku.family] If the service has different generations of + * hardware, for the same SKU, then that can be captured here. + * @member {number} [sku.capacity] Capacity of the particular SKU. + * @member {string} [fullyQualifiedDomainName] The fully qualified domain name + * of the managed instance. + * @member {string} [administratorLogin] Administrator username for the managed + * instance. Can only be specified when the managed instance is being created + * (and is required for creation). + * @member {string} [administratorLoginPassword] The administrator login + * password (required for managed instance creation). + * @member {string} [subnetId] Subnet resource ID for the managed instance. + * @member {string} [state] The state of the managed instance. + * @member {string} [licenseType] The license type. Possible values are + * 'LicenseIncluded' and 'BasePrice'. + * @member {number} [vCores] The number of VCores. + * @member {number} [storageSizeInGB] The maximum storage size in GB. + */ +export interface ManagedInstance extends TrackedResource { + identity?: ResourceIdentity; + sku?: Sku; + readonly fullyQualifiedDomainName?: string; + administratorLogin?: string; + administratorLoginPassword?: string; + subnetId?: string; + readonly state?: string; + licenseType?: string; + vCores?: number; + storageSizeInGB?: number; +} + +/** + * @class + * Initializes a new instance of the ManagedInstanceUpdate class. + * @constructor + * An update request for an Azure SQL Database managed instance. + * + * @member {object} [sku] Managed instance sku + * @member {string} [sku.name] The name of the SKU, typically, a letter + + * Number code, e.g. P3. + * @member {string} [sku.tier] The tier of the particular SKU, e.g. Basic, + * Premium. + * @member {string} [sku.size] Size of the particular SKU + * @member {string} [sku.family] If the service has different generations of + * hardware, for the same SKU, then that can be captured here. + * @member {number} [sku.capacity] Capacity of the particular SKU. + * @member {string} [fullyQualifiedDomainName] The fully qualified domain name + * of the managed instance. + * @member {string} [administratorLogin] Administrator username for the managed + * instance. Can only be specified when the managed instance is being created + * (and is required for creation). + * @member {string} [administratorLoginPassword] The administrator login + * password (required for managed instance creation). + * @member {string} [subnetId] Subnet resource ID for the managed instance. + * @member {string} [state] The state of the managed instance. + * @member {string} [licenseType] The license type. Possible values are + * 'LicenseIncluded' and 'BasePrice'. + * @member {number} [vCores] The number of VCores. + * @member {number} [storageSizeInGB] The maximum storage size in GB. + * @member {object} [tags] Resource tags. + */ +export interface ManagedInstanceUpdate { + sku?: Sku; + readonly fullyQualifiedDomainName?: string; + administratorLogin?: string; + administratorLoginPassword?: string; + subnetId?: string; + readonly state?: string; + licenseType?: string; + vCores?: number; + storageSizeInGB?: number; + tags?: { [propertyName: string]: string }; +} + /** * @class * Initializes a new instance of the OperationDisplay class. @@ -1368,24 +1502,6 @@ export interface ServerKey extends ProxyResource { creationDate?: Date; } -/** - * @class - * Initializes a new instance of the ResourceIdentity class. - * @constructor - * Azure Active Directory identity configuration for a resource. - * - * @member {uuid} [principalId] The Azure Active Directory principal id. - * @member {string} [type] The identity type. Set this to 'SystemAssigned' in - * order to automatically create and assign an Azure Active Directory principal - * for the resource. Possible values include: 'SystemAssigned' - * @member {uuid} [tenantId] The Azure Active Directory tenant id. - */ -export interface ResourceIdentity { - readonly principalId?: string; - type?: string; - readonly tenantId?: string; -} - /** * @class * Initializes a new instance of the Server class. @@ -1809,6 +1925,125 @@ export interface BackupLongTermRetentionPolicy extends ProxyResource { weekOfYear?: number; } +/** + * @class + * Initializes a new instance of the CompleteDatabaseRestoreDefinition class. + * @constructor + * Contains the information necessary to perform a complete database restore + * operation. + * + * @member {string} lastBackupName The last backup name to apply + */ +export interface CompleteDatabaseRestoreDefinition { + lastBackupName: string; +} + +/** + * @class + * Initializes a new instance of the ManagedDatabase class. + * @constructor + * A managed database resource. + * + * @member {string} [collation] Collation of the managed database. + * @member {string} [status] Status for the database. Possible values include: + * 'Online', 'Offline', 'Shutdown', 'Creating', 'Inaccessible' + * @member {date} [creationDate] Creation date of the database. + * @member {date} [earliestRestorePoint] Earliest restore point in time for + * point in time restore. + * @member {date} [restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * @member {string} [defaultSecondaryLocation] Geo paired region. + * @member {string} [catalogCollation] Collation of the metadata catalog. + * Possible values include: 'DATABASE_DEFAULT', 'SQL_Latin1_General_CP1_CI_AS' + * @member {string} [createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * @member {string} [storageContainerUri] Conditional. If createMode is + * RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * @member {string} [sourceDatabaseId] The resource identifier of the source + * database associated with create operation of this database. + * @member {string} [storageContainerSasToken] Conditional. If createMode is + * RestoreExternalBackup, this value is required. Specifies the storage + * container sas token. + * @member {string} [failoverGroupId] Instance Failover Group resource + * identifier that this managed database belongs to. + */ +export interface ManagedDatabase extends TrackedResource { + collation?: string; + readonly status?: string; + readonly creationDate?: Date; + readonly earliestRestorePoint?: Date; + restorePointInTime?: Date; + readonly defaultSecondaryLocation?: string; + catalogCollation?: string; + createMode?: string; + storageContainerUri?: string; + sourceDatabaseId?: string; + storageContainerSasToken?: string; + readonly failoverGroupId?: string; +} + +/** + * @class + * Initializes a new instance of the ManagedDatabaseUpdate class. + * @constructor + * An managed database update. + * + * @member {string} [collation] Collation of the managed database. + * @member {string} [status] Status for the database. Possible values include: + * 'Online', 'Offline', 'Shutdown', 'Creating', 'Inaccessible' + * @member {date} [creationDate] Creation date of the database. + * @member {date} [earliestRestorePoint] Earliest restore point in time for + * point in time restore. + * @member {date} [restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * @member {string} [defaultSecondaryLocation] Geo paired region. + * @member {string} [catalogCollation] Collation of the metadata catalog. + * Possible values include: 'DATABASE_DEFAULT', 'SQL_Latin1_General_CP1_CI_AS' + * @member {string} [createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * @member {string} [storageContainerUri] Conditional. If createMode is + * RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * @member {string} [sourceDatabaseId] The resource identifier of the source + * database associated with create operation of this database. + * @member {string} [storageContainerSasToken] Conditional. If createMode is + * RestoreExternalBackup, this value is required. Specifies the storage + * container sas token. + * @member {string} [failoverGroupId] Instance Failover Group resource + * identifier that this managed database belongs to. + * @member {object} [tags] Resource tags. + */ +export interface ManagedDatabaseUpdate { + collation?: string; + readonly status?: string; + readonly creationDate?: Date; + readonly earliestRestorePoint?: Date; + restorePointInTime?: Date; + readonly defaultSecondaryLocation?: string; + catalogCollation?: string; + createMode?: string; + storageContainerUri?: string; + sourceDatabaseId?: string; + storageContainerSasToken?: string; + readonly failoverGroupId?: string; + tags?: { [propertyName: string]: string }; +} + /** * @class * Initializes a new instance of the AutomaticTuningServerOptions class. @@ -2082,28 +2317,6 @@ export interface PerformanceLevelCapability { readonly unit?: string; } -/** - * @class - * Initializes a new instance of the Sku class. - * @constructor - * An ARM Resource SKU. - * - * @member {string} name The name of the SKU, typically, a letter + Number - * code, e.g. P3. - * @member {string} [tier] The tier of the particular SKU, e.g. Basic, Premium. - * @member {string} [size] Size of the particular SKU - * @member {string} [family] If the service has different generations of - * hardware, for the same SKU, then that can be captured here. - * @member {number} [capacity] Capacity of the particular SKU. - */ -export interface Sku { - name: string; - tier?: string; - size?: string; - family?: string; - capacity?: number; -} - /** * @class * Initializes a new instance of the LicenseTypeCapability class. @@ -2853,6 +3066,122 @@ export interface ElasticPoolUpdate { tags?: { [propertyName: string]: string }; } +/** + * @class + * Initializes a new instance of the InstanceFailoverGroupReadWriteEndpoint class. + * @constructor + * Read-write endpoint of the failover group instance. + * + * @member {string} failoverPolicy Failover policy of the read-write endpoint + * for the failover group. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. Possible values include: + * 'Manual', 'Automatic' + * @member {number} [failoverWithDataLossGracePeriodMinutes] Grace period + * before failover with data loss is attempted for the read-write endpoint. If + * failoverPolicy is Automatic then failoverWithDataLossGracePeriodMinutes is + * required. + */ +export interface InstanceFailoverGroupReadWriteEndpoint { + failoverPolicy: string; + failoverWithDataLossGracePeriodMinutes?: number; +} + +/** + * @class + * Initializes a new instance of the InstanceFailoverGroupReadOnlyEndpoint class. + * @constructor + * Read-only endpoint of the failover group instance. + * + * @member {string} [failoverPolicy] Failover policy of the read-only endpoint + * for the failover group. Possible values include: 'Disabled', 'Enabled' + */ +export interface InstanceFailoverGroupReadOnlyEndpoint { + failoverPolicy?: string; +} + +/** + * @class + * Initializes a new instance of the PartnerRegionInfo class. + * @constructor + * Partner region information for the failover group. + * + * @member {string} [location] Geo location of the partner managed instances. + * @member {string} [replicationRole] Replication role of the partner managed + * instances. Possible values include: 'Primary', 'Secondary' + */ +export interface PartnerRegionInfo { + location?: string; + readonly replicationRole?: string; +} + +/** + * @class + * Initializes a new instance of the ManagedInstancePairInfo class. + * @constructor + * Pairs of Managed Instances in the failover group. + * + * @member {string} [primaryManagedInstanceId] Id of Primary Managed Instance + * in pair. + * @member {string} [partnerManagedInstanceId] Id of Partner Managed Instance + * in pair. + */ +export interface ManagedInstancePairInfo { + primaryManagedInstanceId?: string; + partnerManagedInstanceId?: string; +} + +/** + * @class + * Initializes a new instance of the InstanceFailoverGroup class. + * @constructor + * An instance failover group. + * + * @member {object} readWriteEndpoint Read-write endpoint of the failover group + * instance. + * @member {string} [readWriteEndpoint.failoverPolicy] Failover policy of the + * read-write endpoint for the failover group. If failoverPolicy is Automatic + * then failoverWithDataLossGracePeriodMinutes is required. Possible values + * include: 'Manual', 'Automatic' + * @member {number} [readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] + * Grace period before failover with data loss is attempted for the read-write + * endpoint. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. + * @member {object} [readOnlyEndpoint] Read-only endpoint of the failover group + * instance. + * @member {string} [readOnlyEndpoint.failoverPolicy] Failover policy of the + * read-only endpoint for the failover group. Possible values include: + * 'Disabled', 'Enabled' + * @member {string} [replicationRole] Local replication role of the failover + * group instance. Possible values include: 'Primary', 'Secondary' + * @member {string} [replicationState] Replication state of the failover group + * instance. + * @member {array} partnerRegions Partner region information for the failover + * group. + * @member {array} managedInstancePairs List of managed instance pairs in the + * failover group. + */ +export interface InstanceFailoverGroup extends ProxyResource { + readWriteEndpoint: InstanceFailoverGroupReadWriteEndpoint; + readOnlyEndpoint?: InstanceFailoverGroupReadOnlyEndpoint; + readonly replicationRole?: string; + readonly replicationState?: string; + partnerRegions: PartnerRegionInfo[]; + managedInstancePairs: ManagedInstancePairInfo[]; +} + +/** + * @class + * Initializes a new instance of the ShortTermRetentionPolicy class. + * @constructor + * A short term retention policy resource. + * + * @member {number} [retentionDays] The backup retention period in days. This + * is how many days Point-in-Time Restore will be supported. + */ +export interface ShortTermRetentionPolicy extends ProxyResource { + retentionDays?: number; +} + /** * @class @@ -3105,6 +3434,18 @@ export interface FailoverGroupListResult extends Array { readonly nextLink?: string; } +/** + * @class + * Initializes a new instance of the ManagedInstanceListResult class. + * @constructor + * A list of managed instances. + * + * @member {string} [nextLink] Link to retrieve next page of results. + */ +export interface ManagedInstanceListResult extends Array { + readonly nextLink?: string; +} + /** * @class * Initializes a new instance of the OperationListResult class. @@ -3249,6 +3590,18 @@ export interface LongTermRetentionBackupListResult extends Array { + readonly nextLink?: string; +} + /** * @class * Initializes a new instance of the ServerDnsAliasListResult class. @@ -3296,3 +3649,15 @@ export interface DatabaseOperationListResult extends Array { export interface ElasticPoolOperationListResult extends Array { readonly nextLink?: string; } + +/** + * @class + * Initializes a new instance of the InstanceFailoverGroupListResult class. + * @constructor + * A list of instance failover groups. + * + * @member {string} [nextLink] Link to retrieve next page of results. + */ +export interface InstanceFailoverGroupListResult extends Array { + readonly nextLink?: string; +} diff --git a/lib/services/sqlManagement2/lib/models/index.js b/lib/services/sqlManagement2/lib/models/index.js index eb58f54c80..86aa7c826a 100644 --- a/lib/services/sqlManagement2/lib/models/index.js +++ b/lib/services/sqlManagement2/lib/models/index.js @@ -65,10 +65,13 @@ exports.FailoverGroupReadOnlyEndpoint = require('./failoverGroupReadOnlyEndpoint exports.PartnerInfo = require('./partnerInfo'); exports.FailoverGroup = require('./failoverGroup'); exports.FailoverGroupUpdate = require('./failoverGroupUpdate'); +exports.ResourceIdentity = require('./resourceIdentity'); +exports.Sku = require('./sku'); +exports.ManagedInstance = require('./managedInstance'); +exports.ManagedInstanceUpdate = require('./managedInstanceUpdate'); exports.OperationDisplay = require('./operationDisplay'); exports.Operation = require('./operation'); exports.ServerKey = require('./serverKey'); -exports.ResourceIdentity = require('./resourceIdentity'); exports.Server = require('./server'); exports.ServerUpdate = require('./serverUpdate'); exports.SyncAgent = require('./syncAgent'); @@ -88,6 +91,9 @@ exports.SubscriptionUsage = require('./subscriptionUsage'); exports.VirtualNetworkRule = require('./virtualNetworkRule'); exports.LongTermRetentionBackup = require('./longTermRetentionBackup'); exports.BackupLongTermRetentionPolicy = require('./backupLongTermRetentionPolicy'); +exports.CompleteDatabaseRestoreDefinition = require('./completeDatabaseRestoreDefinition'); +exports.ManagedDatabase = require('./managedDatabase'); +exports.ManagedDatabaseUpdate = require('./managedDatabaseUpdate'); exports.AutomaticTuningServerOptions = require('./automaticTuningServerOptions'); exports.ServerAutomaticTuning = require('./serverAutomaticTuning'); exports.ServerDnsAlias = require('./serverDnsAlias'); @@ -100,7 +106,6 @@ exports.MaxSizeCapability = require('./maxSizeCapability'); exports.LogSizeCapability = require('./logSizeCapability'); exports.MaxSizeRangeCapability = require('./maxSizeRangeCapability'); exports.PerformanceLevelCapability = require('./performanceLevelCapability'); -exports.Sku = require('./sku'); exports.LicenseTypeCapability = require('./licenseTypeCapability'); exports.ServiceObjectiveCapability = require('./serviceObjectiveCapability'); exports.EditionCapability = require('./editionCapability'); @@ -120,6 +125,12 @@ exports.ResourceMoveDefinition = require('./resourceMoveDefinition'); exports.ElasticPoolPerDatabaseSettings = require('./elasticPoolPerDatabaseSettings'); exports.ElasticPool = require('./elasticPool'); exports.ElasticPoolUpdate = require('./elasticPoolUpdate'); +exports.InstanceFailoverGroupReadWriteEndpoint = require('./instanceFailoverGroupReadWriteEndpoint'); +exports.InstanceFailoverGroupReadOnlyEndpoint = require('./instanceFailoverGroupReadOnlyEndpoint'); +exports.PartnerRegionInfo = require('./partnerRegionInfo'); +exports.ManagedInstancePairInfo = require('./managedInstancePairInfo'); +exports.InstanceFailoverGroup = require('./instanceFailoverGroup'); +exports.ShortTermRetentionPolicy = require('./shortTermRetentionPolicy'); exports.RecoverableDatabaseListResult = require('./recoverableDatabaseListResult'); exports.RestorableDroppedDatabaseListResult = require('./restorableDroppedDatabaseListResult'); exports.ServerListResult = require('./serverListResult'); @@ -144,6 +155,7 @@ exports.ServerUsageListResult = require('./serverUsageListResult'); exports.DatabaseUsageListResult = require('./databaseUsageListResult'); exports.EncryptionProtectorListResult = require('./encryptionProtectorListResult'); exports.FailoverGroupListResult = require('./failoverGroupListResult'); +exports.ManagedInstanceListResult = require('./managedInstanceListResult'); exports.OperationListResult = require('./operationListResult'); exports.ServerKeyListResult = require('./serverKeyListResult'); exports.SyncAgentListResult = require('./syncAgentListResult'); @@ -156,7 +168,9 @@ exports.SyncMemberListResult = require('./syncMemberListResult'); exports.SubscriptionUsageListResult = require('./subscriptionUsageListResult'); exports.VirtualNetworkRuleListResult = require('./virtualNetworkRuleListResult'); exports.LongTermRetentionBackupListResult = require('./longTermRetentionBackupListResult'); +exports.ManagedDatabaseListResult = require('./managedDatabaseListResult'); exports.ServerDnsAliasListResult = require('./serverDnsAliasListResult'); exports.RestorePointListResult = require('./restorePointListResult'); exports.DatabaseOperationListResult = require('./databaseOperationListResult'); exports.ElasticPoolOperationListResult = require('./elasticPoolOperationListResult'); +exports.InstanceFailoverGroupListResult = require('./instanceFailoverGroupListResult'); diff --git a/lib/services/sqlManagement2/lib/models/shortTermRetentionPolicy.js b/lib/services/sqlManagement2/lib/models/shortTermRetentionPolicy.js new file mode 100644 index 0000000000..10bf5396d9 --- /dev/null +++ b/lib/services/sqlManagement2/lib/models/shortTermRetentionPolicy.js @@ -0,0 +1,81 @@ +/* + * 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. + */ + +'use strict'; + +const models = require('./index'); + +/** + * A short term retention policy resource. + * + * @extends models['ProxyResource'] + */ +class ShortTermRetentionPolicy extends models['ProxyResource'] { + /** + * Create a ShortTermRetentionPolicy. + * @member {number} [retentionDays] The backup retention period in days. This + * is how many days Point-in-Time Restore will be supported. + */ + constructor() { + super(); + } + + /** + * Defines the metadata of ShortTermRetentionPolicy + * + * @returns {object} metadata of ShortTermRetentionPolicy + * + */ + mapper() { + return { + required: false, + serializedName: 'ShortTermRetentionPolicy', + type: { + name: 'Composite', + className: 'ShortTermRetentionPolicy', + modelProperties: { + id: { + required: false, + readOnly: true, + serializedName: 'id', + type: { + name: 'String' + } + }, + name: { + required: false, + readOnly: true, + serializedName: 'name', + type: { + name: 'String' + } + }, + type: { + required: false, + readOnly: true, + serializedName: 'type', + type: { + name: 'String' + } + }, + retentionDays: { + required: false, + serializedName: 'properties.retentionDays', + type: { + name: 'Number' + } + } + } + } + }; + } +} + +module.exports = ShortTermRetentionPolicy; diff --git a/lib/services/sqlManagement2/lib/operations/index.d.ts b/lib/services/sqlManagement2/lib/operations/index.d.ts index c753734bba..bbd70b7886 100644 --- a/lib/services/sqlManagement2/lib/operations/index.d.ts +++ b/lib/services/sqlManagement2/lib/operations/index.d.ts @@ -10710,15 +10710,15 @@ export interface FailoverGroups { /** * @class - * Operations + * ManagedInstances * __NOTE__: An instance of this class is automatically created for an * instance of the SqlManagementClient. */ -export interface Operations { +export interface ManagedInstances { /** - * Lists all of the available SQL Rest API operations. + * Gets a list of all managed instances in the subscription. * * @param {object} [options] Optional Parameters. * @@ -10727,14 +10727,14 @@ export interface Operations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all of the available SQL Rest API operations. + * Gets a list of all managed instances in the subscription. * * @param {object} [options] Optional Parameters. * @@ -10748,7 +10748,7 @@ export interface Operations { * * {Promise} A promise is returned. * - * @resolve {OperationListResult} - The deserialized result object. + * @resolve {ManagedInstanceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10756,23 +10756,25 @@ export interface Operations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. + * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstanceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - list(callback: ServiceCallback): void; - list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all of the available SQL Rest API operations. + * Gets a list of managed instances in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * * @param {object} [options] Optional Parameters. * @@ -10781,17 +10783,18 @@ export interface Operations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all of the available SQL Rest API operations. + * Gets a list of managed instances in a resource group. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * * @param {object} [options] Optional Parameters. * @@ -10805,7 +10808,7 @@ export interface Operations { * * {Promise} A promise is returned. * - * @resolve {OperationListResult} - The deserialized result object. + * @resolve {ManagedInstanceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10813,35 +10816,27 @@ export interface Operations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {OperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link OperationListResult} for more information. + * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstanceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listNext(nextPageLink: string, callback: ServiceCallback): void; - listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ServerKeys - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ServerKeys { + listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroup(resourceGroupName: string, callback: ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server keys. + * Gets a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -10850,20 +10845,20 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server keys. + * Gets a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -10877,7 +10872,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKeyListResult} - The deserialized result object. + * @resolve {ManagedInstance} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -10885,159 +10880,140 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKeyListResult} for more information. + * {ManagedInstance} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstance} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a server key. + * Creates or updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} keyName The name of the server key to be retrieved. + * @param {object} parameters The requested managed instance resource state. * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.identity] The Azure Active Directory identity of + * the managed instance. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.identity.type] The identity type. Set this to + * 'SystemAssigned' in order to automatically create and assign an Azure Active + * Directory principal for the resource. Possible values include: + * 'SystemAssigned' * - * @returns {Promise} A promise is returned + * @param {object} [parameters.sku] Managed instance sku * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. * - * @reject {Error|ServiceError} - The error object. - */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a server key. + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {string} [parameters.sku.size] Size of the particular SKU * - * @param {string} serverName The name of the server. + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. * - * @param {string} keyName The name of the server key to be retrieved. + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. * - * {Promise} A promise is returned. + * @param {number} [parameters.vCores] The number of VCores. * - * @resolve {ServerKey} - The deserialized result object. + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. * - * @reject {Error|ServiceError} - The error object. + * @param {object} [parameters.tags] Resource tags. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} parameters.location Resource location. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {object} [options] Optional Parameters. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @returns {Promise} A promise is returned * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. */ - get(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a server key. + * Creates or updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 - * - * @param {object} parameters The requested server key resource state. - * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. - * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} [parameters.uri] The URI of the server key. + * @param {object} parameters The requested managed instance resource state. * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * @param {object} [parameters.identity] The Azure Active Directory identity of + * the managed instance. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} [parameters.identity.type] The identity type. Set this to + * 'SystemAssigned' in order to automatically create and assign an Azure Active + * Directory principal for the resource. Possible values include: + * 'SystemAssigned' * - * @param {object} [options] Optional Parameters. + * @param {object} [parameters.sku] Managed instance sku * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. * - * @returns {Promise} A promise is returned + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} [parameters.sku.size] Size of the particular SKU * - * @reject {Error|ServiceError} - The error object. - */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Creates or updates a server key. + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. * - * @param {string} serverName The name of the server. + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). * - * @param {object} parameters The requested server key resource state. + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' + * @param {number} [parameters.vCores] The number of VCores. * - * @param {string} [parameters.uri] The URI of the server key. + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * @param {object} [parameters.tags] Resource tags. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -11051,7 +11027,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKey} - The deserialized result object. + * @resolve {ManagedInstance} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11059,28 +11035,26 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * {ManagedInstance} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstance} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server key with the given name. + * Deletes a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -11093,18 +11067,16 @@ export interface ServerKeys { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server key with the given name. + * Deletes a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be deleted. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -11132,41 +11104,55 @@ export interface ServerKeys { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a server key. + * Updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 + * @param {object} parameters The requested managed instance resource state. * - * @param {object} parameters The requested server key resource state. + * @param {object} [parameters.sku] Managed instance sku * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. * - * @param {string} [parameters.uri] The URI of the server key. + * @param {string} [parameters.sku.size] Size of the particular SKU * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). + * + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). + * + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. + * + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. + * + * @param {number} [parameters.vCores] The number of VCores. + * + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -11175,42 +11161,56 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a server key. + * Updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be operated on - * (updated or created). The key name is required to be in the format of - * 'vault_key_version'. For example, if the keyId is - * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, - * then the server key name should be formatted as: - * YourVaultName_YourKeyName_01234567890123456789012345678901 + * @param {string} managedInstanceName The name of the managed instance. * - * @param {object} parameters The requested server key resource state. + * @param {object} parameters The requested managed instance resource state. * - * @param {string} [parameters.kind] Kind of encryption protector. This is - * metadata used for the Azure portal experience. + * @param {object} [parameters.sku] Managed instance sku * - * @param {string} parameters.serverKeyType The server key type like - * 'ServiceManaged', 'AzureKeyVault'. Possible values include: - * 'ServiceManaged', 'AzureKeyVault' + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. * - * @param {string} [parameters.uri] The URI of the server key. + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. * - * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * @param {string} [parameters.sku.size] Size of the particular SKU * - * @param {date} [parameters.creationDate] The server key creation date. + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. + * + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). + * + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). + * + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. + * + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. + * + * @param {number} [parameters.vCores] The number of VCores. + * + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -11224,7 +11224,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKey} - The deserialized result object. + * @resolve {ManagedInstance} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11232,28 +11232,72 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKey} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKey} for more information. + * {ManagedInstance} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstance} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, callback: ServiceCallback): void; + update(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server key with the given name. + * Creates or updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} keyName The name of the server key to be deleted. + * @param {object} parameters The requested managed instance resource state. + * + * @param {object} [parameters.identity] The Azure Active Directory identity of + * the managed instance. + * + * @param {string} [parameters.identity.type] The identity type. Set this to + * 'SystemAssigned' in order to automatically create and assign an Azure Active + * Directory principal for the resource. Possible values include: + * 'SystemAssigned' + * + * @param {object} [parameters.sku] Managed instance sku + * + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. + * + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. + * + * @param {string} [parameters.sku.size] Size of the particular SKU + * + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. + * + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). + * + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). + * + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. + * + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. + * + * @param {number} [parameters.vCores] The number of VCores. + * + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -11262,78 +11306,66 @@ export interface ServerKeys { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server key with the given name. + * Creates or updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} keyName The name of the server key to be deleted. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} managedInstanceName The name of the managed instance. * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} parameters The requested managed instance resource state. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {object} [parameters.identity] The Azure Active Directory identity of + * the managed instance. * - * {Promise} A promise is returned. + * @param {string} [parameters.identity.type] The identity type. Set this to + * 'SystemAssigned' in order to automatically create and assign an Azure Active + * Directory principal for the resource. Possible values include: + * 'SystemAssigned' * - * @resolve {null} - The deserialized result object. + * @param {object} [parameters.sku] Managed instance sku * - * @reject {Error|ServiceError} - The error object. + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. * - * {ServiceCallback} optionalCallback(err, result, request, response) + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * @param {string} [parameters.sku.size] Size of the particular SKU * - * {null} [result] - The deserialized result object if an error did not occur. + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. - */ - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - - - /** - * Gets a list of server keys. + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). * - * @param {object} [options] Optional Parameters. + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. * - * @returns {Promise} A promise is returned + * @param {number} [parameters.vCores] The number of VCores. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. * - * @reject {Error|ServiceError} - The error object. - */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a list of server keys. + * @param {object} [parameters.tags] Resource tags. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -11347,7 +11379,7 @@ export interface ServerKeys { * * {Promise} A promise is returned. * - * @resolve {ServerKeyListResult} - The deserialized result object. + * @resolve {ManagedInstance} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11355,38 +11387,26 @@ export interface ServerKeys { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerKeyListResult} for more information. + * {ManagedInstance} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstance} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncAgents - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncAgents { + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstance, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync agent. + * Deletes a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -11395,23 +11415,20 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync agent. + * Deletes a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -11425,7 +11442,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11433,34 +11450,61 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync agent. + * Updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} syncAgentName The name of the sync agent. + * @param {object} parameters The requested managed instance resource state. * - * @param {object} parameters The requested sync agent resource state. + * @param {object} [parameters.sku] Managed instance sku * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. + * + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. + * + * @param {string} [parameters.sku.size] Size of the particular SKU + * + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. + * + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). + * + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). + * + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. + * + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. + * + * @param {number} [parameters.vCores] The number of VCores. + * + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -11469,28 +11513,56 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync agent. + * Updates a managed instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} syncAgentName The name of the sync agent. + * @param {object} parameters The requested managed instance resource state. * - * @param {object} parameters The requested sync agent resource state. + * @param {object} [parameters.sku] Managed instance sku * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} parameters.sku.name The name of the SKU, typically, a letter + * + Number code, e.g. P3. + * + * @param {string} [parameters.sku.tier] The tier of the particular SKU, e.g. + * Basic, Premium. + * + * @param {string} [parameters.sku.size] Size of the particular SKU + * + * @param {string} [parameters.sku.family] If the service has different + * generations of hardware, for the same SKU, then that can be captured here. + * + * @param {number} [parameters.sku.capacity] Capacity of the particular SKU. + * + * @param {string} [parameters.administratorLogin] Administrator username for + * the managed instance. Can only be specified when the managed instance is + * being created (and is required for creation). + * + * @param {string} [parameters.administratorLoginPassword] The administrator + * login password (required for managed instance creation). + * + * @param {string} [parameters.subnetId] Subnet resource ID for the managed + * instance. + * + * @param {string} [parameters.licenseType] The license type. Possible values + * are 'LicenseIncluded' and 'BasePrice'. + * + * @param {number} [parameters.vCores] The number of VCores. + * + * @param {number} [parameters.storageSizeInGB] The maximum storage size in GB. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -11504,7 +11576,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {ManagedInstance} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11512,29 +11584,23 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {ManagedInstance} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstance} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, managedInstanceName: string, parameters: models.ManagedInstanceUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync agent. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * Gets a list of all managed instances in the subscription. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11543,23 +11609,17 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync agent. + * Gets a list of all managed instances in the subscription. * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11573,7 +11633,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ManagedInstanceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11581,26 +11641,24 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstanceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync agents in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of managed instances in a resource group. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11609,21 +11667,17 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByResourceGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync agents in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of managed instances in a resource group. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11637,7 +11691,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentListResult} - The deserialized result object. + * @resolve {ManagedInstanceListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11645,29 +11699,30 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentListResult} for more information. + * {ManagedInstanceListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedInstanceListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByResourceGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Operations + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface Operations { /** - * Generates a sync agent key. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * Lists all of the available SQL Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -11676,23 +11731,14 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - generateKeyWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Generates a sync agent key. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. + * Lists all of the available SQL Rest API operations. * * @param {object} [options] Optional Parameters. * @@ -11706,7 +11752,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentKeyProperties} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11714,30 +11760,23 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentKeyProperties} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentKeyProperties} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + list(options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + list(callback: ServiceCallback): void; + list(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists databases linked to a sync agent. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * Lists all of the available SQL Rest API operations. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11746,23 +11785,17 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLinkedDatabasesWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists databases linked to a sync agent. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * Lists all of the available SQL Rest API operations. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -11776,7 +11809,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. + * @resolve {OperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11784,35 +11817,35 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentLinkedDatabaseListResult} for more - * information. + * {OperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link OperationListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listNext(nextPageLink: string, callback: ServiceCallback): void; + listNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ServerKeys + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ServerKeys { /** - * Creates or updates a sync agent. + * Gets a list of server keys. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. - * - * @param {object} parameters The requested sync agent resource state. - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -11821,28 +11854,20 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync agent. + * Gets a list of server keys. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. - * - * @param {string} syncAgentName The name of the sync agent. - * - * @param {object} parameters The requested sync agent resource state. - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync agent. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -11856,7 +11881,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgent} - The deserialized result object. + * @resolve {ServerKeyListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11864,29 +11889,28 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgent} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgent} for more information. + * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKeyListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync agent. + * Gets a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} keyName The name of the server key to be retrieved. * * @param {object} [options] Optional Parameters. * @@ -11895,23 +11919,22 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync agent. + * Gets a server key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server on which the sync agent is - * hosted. + * @param {string} serverName The name of the server. * - * @param {string} syncAgentName The name of the sync agent. + * @param {string} keyName The name of the server key to be retrieved. * * @param {object} [options] Optional Parameters. * @@ -11925,7 +11948,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ServerKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11933,22 +11956,48 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync agents in a server. + * Creates or updates a server key. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 + * + * @param {object} parameters The requested server key resource state. + * + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. + * + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' + * + * @param {string} [parameters.uri] The URI of the server key. + * + * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -11957,31 +12006,56 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync agents in a server. + * Creates or updates a server key. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server. * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 * - * @param {ServiceCallback} [optionalCallback] - The optional callback. + * @param {object} parameters The requested server key resource state. * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. * - * {Promise} A promise is returned. + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' * - * @resolve {SyncAgentListResult} - The deserialized result object. + * @param {string} [parameters.uri] The URI of the server key. + * + * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * + * @param {date} [parameters.creationDate] The server key creation date. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {ServerKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -11989,23 +12063,28 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentListResult} for more information. + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists databases linked to a sync agent. + * Deletes the server key with the given name. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -12014,17 +12093,22 @@ export interface SyncAgents { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLinkedDatabasesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists databases linked to a sync agent. + * Deletes the server key with the given name. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -12038,7 +12122,7 @@ export interface SyncAgents { * * {Promise} A promise is returned. * - * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12046,33 +12130,47 @@ export interface SyncAgents { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncAgentLinkedDatabaseListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLinkedDatabasesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLinkedDatabasesNext(nextPageLink: string, callback: ServiceCallback): void; - listLinkedDatabasesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncGroups - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncGroups { + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of sync database ids. + * Creates or updates a server key. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 + * + * @param {object} parameters The requested server key resource state. + * + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. + * + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' + * + * @param {string} [parameters.uri] The URI of the server key. + * + * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -12081,17 +12179,42 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listSyncDatabaseIdsWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of sync database ids. + * Creates or updates a server key. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} keyName The name of the server key to be operated on + * (updated or created). The key name is required to be in the format of + * 'vault_key_version'. For example, if the keyId is + * https://YourVaultName.vault.azure.net/keys/YourKeyName/01234567890123456789012345678901, + * then the server key name should be formatted as: + * YourVaultName_YourKeyName_01234567890123456789012345678901 + * + * @param {object} parameters The requested server key resource state. + * + * @param {string} [parameters.kind] Kind of encryption protector. This is + * metadata used for the Azure portal experience. + * + * @param {string} parameters.serverKeyType The server key type like + * 'ServiceManaged', 'AzureKeyVault'. Possible values include: + * 'ServiceManaged', 'AzureKeyVault' + * + * @param {string} [parameters.uri] The URI of the server key. + * + * @param {string} [parameters.thumbprint] Thumbprint of the server key. + * + * @param {date} [parameters.creationDate] The server key creation date. * * @param {object} [options] Optional Parameters. * @@ -12105,7 +12228,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncDatabaseIdListResult} - The deserialized result object. + * @resolve {ServerKey} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12113,21 +12236,20 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncDatabaseIdListResult} for more - * information. + * {ServerKey} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKey} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listSyncDatabaseIds(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listSyncDatabaseIds(locationName: string, callback: ServiceCallback): void; - listSyncDatabaseIds(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, keyName: string, parameters: models.ServerKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a hub database schema. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -12135,10 +12257,7 @@ export interface SyncGroups { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -12151,10 +12270,10 @@ export interface SyncGroups { * * @reject {Error|ServiceError} - The error object. */ - refreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a hub database schema. + * Deletes the server key with the given name. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -12162,10 +12281,7 @@ export interface SyncGroups { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. + * @param {string} keyName The name of the server key to be deleted. * * @param {object} [options] Optional Parameters. * @@ -12193,24 +12309,16 @@ export interface SyncGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, keyName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of hub database schemas. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Gets a list of server keys. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12219,25 +12327,17 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listHubSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of hub database schemas. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Gets a list of server keys. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12251,7 +12351,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * @resolve {ServerKeyListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12259,82 +12359,66 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. + * {ServerKeyListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerKeyListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SyncAgents + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncAgents { /** - * Gets a collection of sync group logs. + * Gets a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {string} startTime Get logs generated after this time. - * - * @param {string} endTime Get logs generated before this time. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} type The types of logs to retrieve. Possible values include: - * 'All', 'Error', 'Warning', 'Success' + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.continuationToken] The continuation token for this - * operation. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listLogsWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of sync group logs. + * Gets a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {string} startTime Get logs generated after this time. - * - * @param {string} endTime Get logs generated before this time. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} type The types of logs to retrieve. Possible values include: - * 'All', 'Error', 'Warning', 'Success' + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * - * @param {string} [options.continuationToken] The continuation token for this - * operation. - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -12345,7 +12429,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroupLogListResult} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12353,32 +12437,34 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupLogListResult} for more - * information. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, callback: ServiceCallback): void; - listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels a sync group synchronization. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} syncAgentName The name of the sync agent. * - * @param {string} syncGroupName The name of the sync group. + * @param {object} parameters The requested sync agent resource state. + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12387,25 +12473,28 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - cancelSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels a sync group synchronization. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} syncAgentName The name of the sync agent. * - * @param {string} syncGroupName The name of the sync group. + * @param {object} parameters The requested sync agent resource state. + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12419,7 +12508,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12427,30 +12516,29 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Triggers a sync group synchronization. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12463,21 +12551,19 @@ export interface SyncGroups { * * @reject {Error|ServiceError} - The error object. */ - triggerSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Triggers a sync group synchronization. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12505,24 +12591,20 @@ export interface SyncGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync group. + * Lists sync agents in a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * * @param {object} [options] Optional Parameters. * @@ -12531,25 +12613,21 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync group. + * Lists sync agents in a server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * * @param {object} [options] Optional Parameters. * @@ -12563,7 +12641,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncAgentListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12571,55 +12649,29 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync group. + * Generates a sync agent key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12628,49 +12680,23 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + generateKeyWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync group. + * Generates a sync agent key. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12684,7 +12710,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncAgentKeyProperties} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12692,31 +12718,30 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncAgentKeyProperties} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentKeyProperties} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + generateKey(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync group. + * Lists databases linked to a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12725,25 +12750,23 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLinkedDatabasesWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync group. + * Lists databases linked to a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12757,7 +12780,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12765,54 +12788,35 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentLinkedDatabaseListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + listLinkedDatabases(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a sync group. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {string} syncAgentName The name of the sync agent. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {object} parameters The requested sync agent resource state. * * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12821,49 +12825,28 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a sync group. + * Creates or updates a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {number} [parameters.interval] Sync interval of the sync group. + * @param {string} syncAgentName The name of the sync agent. * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * @param {object} parameters The requested sync agent resource state. * * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * database in the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12877,7 +12860,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncAgent} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12885,29 +12868,29 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncAgent} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgent} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, syncAgentName: string, parameters: models.SyncAgent, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync groups under a hub database. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12916,23 +12899,23 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync groups under a hub database. + * Deletes a sync agent. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} serverName The name of the server on which the sync agent is + * hosted. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} syncAgentName The name of the sync agent. * * @param {object} [options] Optional Parameters. * @@ -12946,7 +12929,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -12954,31 +12937,22 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupListResult} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, syncAgentName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a hub database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Lists sync agents in a server. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -12987,25 +12961,17 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginRefreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a hub database schema. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * Lists sync agents in a server. * - * @param {string} syncGroupName The name of the sync group. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13019,7 +12985,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncAgentListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13027,54 +12993,23 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncAgentListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * Lists databases linked to a sync agent. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13083,49 +13018,17 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLinkedDatabasesNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync group. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group. - * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. + * Lists databases linked to a sync agent. * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -13139,7 +13042,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncAgentLinkedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13147,20 +13050,88 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncAgentLinkedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncAgentLinkedDatabaseListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + listLinkedDatabasesNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLinkedDatabasesNext(nextPageLink: string, callback: ServiceCallback): void; + listLinkedDatabasesNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} - /** - * Deletes a sync group. +/** + * @class + * SyncGroups + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncGroups { + + + /** + * Gets a collection of sync database ids. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listSyncDatabaseIdsWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a collection of sync database ids. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncDatabaseIdListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncDatabaseIdListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listSyncDatabaseIds(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listSyncDatabaseIds(locationName: string, callback: ServiceCallback): void; + listSyncDatabaseIds(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13184,10 +13155,10 @@ export interface SyncGroups { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + refreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync group. + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13226,13 +13197,13 @@ export interface SyncGroups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + refreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates a sync group. + * Gets a collection of hub database schemas. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13245,30 +13216,6 @@ export interface SyncGroups { * * @param {string} syncGroupName The name of the sync group. * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13276,14 +13223,14 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listHubSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates a sync group. + * Gets a collection of hub database schemas. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13296,30 +13243,6 @@ export interface SyncGroups { * * @param {string} syncGroupName The name of the sync group. * - * @param {object} parameters The requested sync group resource state. - * - * @param {number} [parameters.interval] Sync interval of the sync group. - * - * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution - * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' - * - * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync - * database in the sync group. - * - * @param {string} [parameters.hubDatabaseUserName] User name for the sync - * group hub database credential. - * - * @param {string} [parameters.hubDatabasePassword] Password for the sync group - * hub database credential. - * - * @param {object} [parameters.schema] Sync schema of the sync group. - * - * @param {array} [parameters.schema.tables] List of tables in sync group - * schema. - * - * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync - * member where the schema is from. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -13332,7 +13255,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroup} - The deserialized result object. + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13340,45 +13263,82 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroup} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroup} for more information. + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + listHubSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of sync database ids. + * Gets a collection of sync group logs. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {string} startTime Get logs generated after this time. + * + * @param {string} endTime Get logs generated before this time. + * + * @param {string} type The types of logs to retrieve. Possible values include: + * 'All', 'Error', 'Warning', 'Success' * * @param {object} [options] Optional Parameters. * + * @param {string} [options.continuationToken] The continuation token for this + * operation. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listSyncDatabaseIdsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listLogsWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of sync database ids. + * Gets a collection of sync group logs. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {string} startTime Get logs generated after this time. + * + * @param {string} endTime Get logs generated before this time. + * + * @param {string} type The types of logs to retrieve. Possible values include: + * 'All', 'Error', 'Warning', 'Success' * * @param {object} [options] Optional Parameters. * + * @param {string} [options.continuationToken] The continuation token for this + * operation. + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -13389,7 +13349,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncDatabaseIdListResult} - The deserialized result object. + * @resolve {SyncGroupLogListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13397,24 +13357,32 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncDatabaseIdListResult} for more + * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupLogListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listSyncDatabaseIdsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listSyncDatabaseIdsNext(nextPageLink: string, callback: ServiceCallback): void; - listSyncDatabaseIdsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options?: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, callback: ServiceCallback): void; + listLogs(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, startTime: string, endTime: string, type: string, options: { continuationToken? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of hub database schemas. + * Cancels a sync group synchronization. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13423,17 +13391,25 @@ export interface SyncGroups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listHubSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a collection of hub database schemas. + * Cancels a sync group synchronization. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13447,7 +13423,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13455,101 +13431,57 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listHubSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listHubSchemasNext(nextPageLink: string, callback: ServiceCallback): void; - listHubSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + cancelSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a collection of sync group logs. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * Triggers a sync group synchronization. * - * @returns {Promise} A promise is returned + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} serverName The name of the server. * - * @reject {Error|ServiceError} - The error object. - */ - listLogsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a collection of sync group logs. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * - * @param {ServiceCallback} [optionalCallback] - The optional callback. - * - * @returns {ServiceCallback|Promise} If a callback was passed as the last - * parameter then it returns the callback else returns a Promise. - * - * {Promise} A promise is returned. - * - * @resolve {SyncGroupLogListResult} - The deserialized result object. - * - * @reject {Error|ServiceError} - The error object. - * - * {ServiceCallback} optionalCallback(err, result, request, response) - * - * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. - * - * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupLogListResult} for more - * information. + * @returns {Promise} A promise is returned * - * {WebResource} [request] - The HTTP Request object if an error did not occur. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + * @reject {Error|ServiceError} - The error object. */ - listLogsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listLogsNext(nextPageLink: string, callback: ServiceCallback): void; - listLogsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; - + triggerSyncWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync groups under a hub database. - * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. - * - * @param {object} [options] Optional Parameters. - * - * @param {object} [options.customHeaders] Headers that will be added to the - * request + * Triggers a sync group synchronization. * - * @returns {Promise} A promise is returned + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @param {string} serverName The name of the server. * - * @reject {Error|ServiceError} - The error object. - */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Lists sync groups under a hub database. + * @param {string} databaseName The name of the database on which the sync + * group is hosted. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13563,7 +13495,7 @@ export interface SyncGroups { * * {Promise} A promise is returned. * - * @resolve {SyncGroupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13571,29 +13503,19 @@ export interface SyncGroups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncGroupListResult} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SyncMembers - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SyncMembers { + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + triggerSync(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync member. + * Gets a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13604,10 +13526,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13616,14 +13535,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync member. + * Gets a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13634,10 +13553,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13651,7 +13567,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMember} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13659,20 +13575,20 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync member. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13683,37 +13599,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * - * @param {object} parameters The requested sync member resource state. + * @param {object} parameters The requested sync group resource state. * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {number} [parameters.interval] Sync interval of the sync group. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {object} [parameters.schema] Sync schema of the sync group. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13722,14 +13632,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync member. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13740,37 +13650,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * - * @param {object} parameters The requested sync member resource state. + * @param {object} parameters The requested sync group resource state. * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {number} [parameters.interval] Sync interval of the sync group. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {object} [parameters.schema] Sync schema of the sync group. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13784,7 +13688,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMember} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -13792,20 +13696,20 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync member. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13816,10 +13720,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13832,10 +13733,10 @@ export interface SyncMembers { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync member. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13846,10 +13747,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -13877,13 +13775,13 @@ export interface SyncMembers { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an existing sync member. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13894,37 +13792,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. + * @param {string} syncGroupName The name of the sync group. * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. + * @param {object} parameters The requested sync group resource state. * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {number} [parameters.interval] Sync interval of the sync group. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {object} [parameters.schema] Sync schema of the sync group. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13933,14 +13825,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an existing sync member. + * Updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -13951,37 +13843,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * - * @param {object} parameters The requested sync member resource state. + * @param {object} parameters The requested sync group resource state. * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {number} [parameters.interval] Sync interval of the sync group. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {object} [parameters.schema] Sync schema of the sync group. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -13995,7 +13881,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMember} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14003,20 +13889,20 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync members in the given sync group. + * Lists sync groups under a hub database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14027,8 +13913,6 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -14036,14 +13920,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listBySyncGroupWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync members in the given sync group. + * Lists sync groups under a hub database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14054,8 +13938,6 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -14068,7 +13950,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMemberListResult} - The deserialized result object. + * @resolve {SyncGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14076,20 +13958,20 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMemberListResult} for more information. + * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupListResult} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; - listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync member database schema. + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14100,10 +13982,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -14112,14 +13991,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listMemberSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginRefreshHubSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync member database schema. + * Refreshes a hub database schema. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14130,10 +14009,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -14147,7 +14023,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14155,21 +14031,19 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + beginRefreshHubSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a sync member database schema. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14180,10 +14054,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. + * @param {string} syncGroupName The name of the sync group. * - * @param {string} syncMemberName The name of the sync member. + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -14192,14 +14087,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - refreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a sync member database schema. + * Creates or updates a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14210,10 +14105,31 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. + * @param {string} syncGroupName The name of the sync group. * - * @param {string} syncMemberName The name of the sync member. + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. * * @param {object} [options] Optional Parameters. * @@ -14227,7 +14143,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {SyncGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14235,19 +14151,20 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates a sync member. + * Deletes a sync group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14258,37 +14175,7 @@ export interface SyncMembers { * @param {string} databaseName The name of the database on which the sync * group is hosted. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. - * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member - * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. - * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. - * - * @param {string} [parameters.password] Password of the member database in the - * sync member. - * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} syncGroupName The name of the sync group. * * @param {object} [options] Optional Parameters. * @@ -14297,14 +14184,2979 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates a sync member. + * Deletes a sync group. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates a sync group. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates a sync group. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} parameters The requested sync group resource state. + * + * @param {number} [parameters.interval] Sync interval of the sync group. + * + * @param {string} [parameters.conflictResolutionPolicy] Conflict resolution + * policy of the sync group. Possible values include: 'HubWin', 'MemberWin' + * + * @param {string} [parameters.syncDatabaseId] ARM resource id of the sync + * database in the sync group. + * + * @param {string} [parameters.hubDatabaseUserName] User name for the sync + * group hub database credential. + * + * @param {string} [parameters.hubDatabasePassword] Password for the sync group + * hub database credential. + * + * @param {object} [parameters.schema] Sync schema of the sync group. + * + * @param {array} [parameters.schema.tables] List of tables in sync group + * schema. + * + * @param {string} [parameters.schema.masterSyncMemberName] Name of master sync + * member where the schema is from. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncGroup} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncGroup} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroup} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, parameters: models.SyncGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a collection of sync database ids. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listSyncDatabaseIdsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a collection of sync database ids. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncDatabaseIdListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncDatabaseIdListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncDatabaseIdListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listSyncDatabaseIdsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listSyncDatabaseIdsNext(nextPageLink: string, callback: ServiceCallback): void; + listSyncDatabaseIdsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a collection of hub database schemas. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listHubSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a collection of hub database schemas. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listHubSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listHubSchemasNext(nextPageLink: string, callback: ServiceCallback): void; + listHubSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a collection of sync group logs. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listLogsNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a collection of sync group logs. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncGroupLogListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncGroupLogListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupLogListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listLogsNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listLogsNext(nextPageLink: string, callback: ServiceCallback): void; + listLogsNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists sync groups under a hub database. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists sync groups under a hub database. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncGroupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncGroupListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SyncMembers + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SyncMembers { + + + /** + * Gets a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMember} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMember} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates an existing sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates an existing sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMember} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists sync members in the given sync group. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listBySyncGroupWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists sync members in the given sync group. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMemberListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMemberListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, callback: ServiceCallback): void; + listBySyncGroup(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listMemberSchemasWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + listMemberSchemas(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Refreshes a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + refreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Refreshes a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + refreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMember} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Updates an existing sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Updates an existing sync member. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} parameters The requested sync member resource state. + * + * @param {string} [parameters.databaseType] Database type of the sync member. + * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * + * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent + * in the sync member. + * + * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the + * sync member. + * + * @param {string} [parameters.serverName] Server name of the member database + * in the sync member + * + * @param {string} [parameters.databaseName] Database name of the member + * database in the sync member. + * + * @param {string} [parameters.userName] User name of the member database in + * the sync member. + * + * @param {string} [parameters.password] Password of the member database in the + * sync member. + * + * @param {string} [parameters.syncDirection] Sync direction of the sync + * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', + * 'OneWayHubToMember' + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMember} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMember} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMember} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Refreshes a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginRefreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Refreshes a sync member database schema. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database on which the sync + * group is hosted. + * + * @param {string} syncGroupName The name of the sync group on which the sync + * member is hosted. + * + * @param {string} syncMemberName The name of the sync member. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; + beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists sync members in the given sync group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listBySyncGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists sync members in the given sync group. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncMemberListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncMemberListResult} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listBySyncGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listBySyncGroupNext(nextPageLink: string, callback: ServiceCallback): void; + listBySyncGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a sync member database schema. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listMemberSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a sync member database schema. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SyncFullSchemaPropertiesListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listMemberSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listMemberSchemasNext(nextPageLink: string, callback: ServiceCallback): void; + listMemberSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * SubscriptionUsages + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface SubscriptionUsages { + + + /** + * Gets all subscription usage metrics in a given location. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByLocationWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all subscription usage metrics in a given location. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SubscriptionUsageListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsageListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByLocation(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a subscription usage metric. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {string} usageName Name of usage metric to return. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a subscription usage metric. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {string} usageName Name of usage metric to return. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SubscriptionUsage} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SubscriptionUsage} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsage} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(locationName: string, usageName: string, callback: ServiceCallback): void; + get(locationName: string, usageName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets all subscription usage metrics in a given location. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets all subscription usage metrics in a given location. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {SubscriptionUsageListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. + * See {@link SubscriptionUsageListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * VirtualNetworkRules + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface VirtualNetworkRules { + + + /** + * Gets a virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkRule} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates an existing virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} parameters The requested virtual Network Rule Resource + * state. + * + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. + * + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates an existing virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} parameters The requested virtual Network Rule Resource + * state. + * + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. + * + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkRule} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the virtual network rule with the given name. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the virtual network rule with the given name. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a list of virtual network rules in a server. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a list of virtual network rules in a server. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRuleListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Creates or updates an existing virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} parameters The requested virtual Network Rule Resource + * state. + * + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. + * + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Creates or updates an existing virtual network rule. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} parameters The requested virtual Network Rule Resource + * state. + * + * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the + * virtual network subnet. + * + * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create + * firewall rule before the virtual network has vnet service endpoint enabled. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkRule} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRule} for more information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes the virtual network rule with the given name. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes the virtual network rule with the given name. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Gets a list of virtual network rules in a server. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a list of virtual network rules in a server. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. + * See {@link VirtualNetworkRuleListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * LongTermRetentionBackups + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface LongTermRetentionBackups { + + + /** + * Gets a long term retention backup. + * + * @param {string} locationName The location of the database. + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a long term retention backup. + * + * @param {string} locationName The location of the database. + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackup} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackup} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackup} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a long term retention backup. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + deleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a long term retention backup. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all long term retention backups for a database. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByDatabaseWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all long term retention backups for a database. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, callback: ServiceCallback): void; + listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists the long term retention backups for a given location. + * + * @param {string} locationName The location of the database + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByLocationWithHttpOperationResponse(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists the long term retention backups for a given location. + * + * @param {string} locationName The location of the database + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByLocation(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists the long term retention backups for a given server. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByServerWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists the long term retention backups for a given server. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {object} [options] Optional Parameters. + * + * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get + * the latest backup for each database. + * + * @param {string} [options.databaseState] Whether to query against just live + * databases, just deleted databases, or all databases. Possible values + * include: 'All', 'Live', 'Deleted' + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByServer(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(locationName: string, longTermRetentionServerName: string, callback: ServiceCallback): void; + listByServer(locationName: string, longTermRetentionServerName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Deletes a long term retention backup. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + beginDeleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Deletes a long term retention backup. + * + * @param {string} locationName The location of the database + * + * @param {string} longTermRetentionServerName + * + * @param {string} longTermRetentionDatabaseName + * + * @param {string} backupName The backup name. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {null} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {null} [result] - The deserialized result object if an error did not occur. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; + beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists all long term retention backups for a database. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists all long term retention backups for a database. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists the long term retention backups for a given location. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists the long term retention backups for a given location. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Lists the long term retention backups for a given server. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Lists the long term retention backups for a given server. + * + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link LongTermRetentionBackupListResult} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * BackupLongTermRetentionPolicies + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface BackupLongTermRetentionPolicies { + + + /** + * Gets a database's long term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a database's long term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + + + /** + * Sets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14312,40 +17164,59 @@ export interface SyncMembers { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} databaseName The name of the database. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. + * @param {object} parameters The long term retention policy info. * - * @param {string} syncMemberName The name of the sync member. + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. * - * @param {object} parameters The requested sync member resource state. + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @reject {Error|ServiceError} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Sets a database's long term retention policy. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -14359,7 +17230,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMember} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14367,20 +17238,21 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a sync member. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14388,13 +17260,7 @@ export interface SyncMembers { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14403,14 +17269,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a sync member. + * Gets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14418,13 +17284,7 @@ export interface SyncMembers { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14438,7 +17298,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14446,19 +17306,21 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Updates an existing sync member. + * Sets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14466,40 +17328,21 @@ export interface SyncMembers { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. - * - * @param {object} parameters The requested sync member resource state. - * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' - * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. - * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @param {string} databaseName The name of the database. * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @param {object} parameters The long term retention policy info. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. * * @param {object} [options] Optional Parameters. * @@ -14508,14 +17351,14 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Updates an existing sync member. + * Sets a database's long term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -14523,40 +17366,104 @@ export interface SyncMembers { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. + * @param {string} databaseName The name of the database. * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. + * @param {object} parameters The long term retention policy info. + * + * @param {string} [parameters.weeklyRetention] The weekly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.monthlyRetention] The montly retention policy + * for an LTR backup in an ISO 8601 format. + * + * @param {string} [parameters.yearlyRetention] The yearly retention policy for + * an LTR backup in an ISO 8601 format. + * + * @param {number} [parameters.weekOfYear] The week of year to take the yearly + * backup in an ISO 8601 format. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {ServiceCallback} [optionalCallback] - The optional callback. + * + * @returns {ServiceCallback|Promise} If a callback was passed as the last + * parameter then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned. + * + * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error|ServiceError} - The error object. + * + * {ServiceCallback} optionalCallback(err, result, request, response) + * + * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. + * + * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link BackupLongTermRetentionPolicy} for more + * information. + * + * {WebResource} [request] - The HTTP Request object if an error did not occur. + * + * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ManagedDatabases + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ManagedDatabases { + + + /** + * Completes the restore operation on a managed database. + * + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {uuid} operationId Management operation id that this request tries to + * complete. * - * @param {string} syncMemberName The name of the sync member. + * @param {object} parameters The definition for completing the restore of this + * managed database. * - * @param {object} parameters The requested sync member resource state. + * @param {string} parameters.lastBackupName The last backup name to apply * - * @param {string} [parameters.databaseType] Database type of the sync member. - * Possible values include: 'AzureSqlDatabase', 'SqlServerDatabase' + * @param {object} [options] Optional Parameters. * - * @param {string} [parameters.syncAgentId] ARM resource id of the sync agent - * in the sync member. + * @param {object} [options.customHeaders] Headers that will be added to the + * request * - * @param {uuid} [parameters.sqlServerDatabaseId] SQL Server database id of the - * sync member. + * @returns {Promise} A promise is returned * - * @param {string} [parameters.serverName] Server name of the member database - * in the sync member + * @resolve {HttpOperationResponse} - The deserialized result object. * - * @param {string} [parameters.databaseName] Database name of the member - * database in the sync member. + * @reject {Error|ServiceError} - The error object. + */ + completeRestoreWithHttpOperationResponse(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Completes the restore operation on a managed database. * - * @param {string} [parameters.userName] User name of the member database in - * the sync member. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} [parameters.password] Password of the member database in the - * sync member. + * @param {uuid} operationId Management operation id that this request tries to + * complete. * - * @param {string} [parameters.syncDirection] Sync direction of the sync - * member. Possible values include: 'Bidirectional', 'OneWayMemberToHub', - * 'OneWayHubToMember' + * @param {object} parameters The definition for completing the restore of this + * managed database. + * + * @param {string} parameters.lastBackupName The last backup name to apply * * @param {object} [options] Optional Parameters. * @@ -14570,7 +17477,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMember} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14578,34 +17485,25 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMember} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMember} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, callback: ServiceCallback): void; - beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, parameters: models.SyncMember, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, callback: ServiceCallback): void; + completeRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Refreshes a sync member database schema. + * Gets a list of managed databases. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -14614,28 +17512,20 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginRefreshMemberSchemaWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByInstanceWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Refreshes a sync member database schema. + * Gets a list of managed databases. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database on which the sync - * group is hosted. - * - * @param {string} syncGroupName The name of the sync group on which the sync - * member is hosted. - * - * @param {string} syncMemberName The name of the sync member. + * @param {string} managedInstanceName The name of the managed instance. * * @param {object} [options] Optional Parameters. * @@ -14649,7 +17539,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ManagedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14657,22 +17547,29 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ManagedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabaseListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, callback: ServiceCallback): void; - beginRefreshMemberSchema(resourceGroupName: string, serverName: string, databaseName: string, syncGroupName: string, syncMemberName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByInstance(resourceGroupName: string, managedInstanceName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByInstance(resourceGroupName: string, managedInstanceName: string, callback: ServiceCallback): void; + listByInstance(resourceGroupName: string, managedInstanceName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists sync members in the given sync group. + * Gets a managed database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14681,17 +17578,22 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listBySyncGroupNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists sync members in the given sync group. + * Gets a managed database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14705,7 +17607,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncMemberListResult} - The deserialized result object. + * @resolve {ManagedDatabase} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14713,23 +17615,64 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncMemberListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncMemberListResult} for more information. + * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabase} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listBySyncGroupNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listBySyncGroupNext(nextPageLink: string, callback: ServiceCallback): void; - listBySyncGroupNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a sync member database schema. + * Creates a new database or updates an existing database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -14738,17 +17681,58 @@ export interface SyncMembers { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listMemberSchemasNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a sync member database schema. + * Creates a new database or updates an existing database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -14762,7 +17746,7 @@ export interface SyncMembers { * * {Promise} A promise is returned. * - * @resolve {SyncFullSchemaPropertiesListResult} - The deserialized result object. + * @resolve {ManagedDatabase} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14770,33 +17754,28 @@ export interface SyncMembers { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SyncFullSchemaPropertiesListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SyncFullSchemaPropertiesListResult} for more - * information. + * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabase} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listMemberSchemasNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listMemberSchemasNext(nextPageLink: string, callback: ServiceCallback): void; - listMemberSchemasNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * SubscriptionUsages - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface SubscriptionUsages { + createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all subscription usage metrics in a given location. + * Deletes the managed database. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14805,17 +17784,22 @@ export interface SubscriptionUsages { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all subscription usage metrics in a given location. + * Deletes the managed database. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -14829,7 +17813,7 @@ export interface SubscriptionUsages { * * {Promise} A promise is returned. * - * @resolve {SubscriptionUsageListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14837,26 +17821,61 @@ export interface SubscriptionUsages { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsageListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocation(locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a subscription usage metric. + * Updates an existing database. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} usageName Name of usage metric to return. + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14865,19 +17884,56 @@ export interface SubscriptionUsages { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a subscription usage metric. + * Updates an existing database. * - * @param {string} locationName The name of the region where the resource is - * located. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} managedInstanceName The name of the managed instance. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. * - * @param {string} usageName Name of usage metric to return. + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -14891,7 +17947,7 @@ export interface SubscriptionUsages { * * {Promise} A promise is returned. * - * @resolve {SubscriptionUsage} - The deserialized result object. + * @resolve {ManagedDatabase} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14899,23 +17955,31 @@ export interface SubscriptionUsages { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SubscriptionUsage} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsage} for more information. + * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabase} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(locationName: string, usageName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(locationName: string, usageName: string, callback: ServiceCallback): void; - get(locationName: string, usageName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, callback: ServiceCallback): void; + update(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets all subscription usage metrics in a given location. + * Completes the restore operation on a managed database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {uuid} operationId Management operation id that this request tries to + * complete. + * + * @param {object} parameters The definition for completing the restore of this + * managed database. + * + * @param {string} parameters.lastBackupName The last backup name to apply * * @param {object} [options] Optional Parameters. * @@ -14924,17 +17988,25 @@ export interface SubscriptionUsages { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCompleteRestoreWithHttpOperationResponse(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets all subscription usage metrics in a given location. + * Completes the restore operation on a managed database. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {uuid} operationId Management operation id that this request tries to + * complete. + * + * @param {object} parameters The definition for completing the restore of this + * managed database. + * + * @param {string} parameters.lastBackupName The last backup name to apply * * @param {object} [options] Optional Parameters. * @@ -14948,7 +18020,7 @@ export interface SubscriptionUsages { * * {Promise} A promise is returned. * - * @resolve {SubscriptionUsageListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -14956,38 +18028,63 @@ export interface SubscriptionUsages { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {SubscriptionUsageListResult} [result] - The deserialized result object if an error did not occur. - * See {@link SubscriptionUsageListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; - listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * VirtualNetworkRules - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface VirtualNetworkRules { + beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, callback: ServiceCallback): void; + beginCompleteRestore(locationName: string, operationId: string, parameters: models.CompleteDatabaseRestoreDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a virtual network rule. + * Creates a new database or updates an existing database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -14996,22 +18093,58 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a virtual network rule. + * Creates a new database or updates an existing database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. + * + * @param {string} parameters.location Resource location. * * @param {object} [options] Optional Parameters. * @@ -15025,7 +18158,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkRule} - The deserialized result object. + * @resolve {ManagedDatabase} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15033,37 +18166,28 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. + * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabase} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabase, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates or updates an existing virtual network rule. + * Deletes the managed database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -15072,31 +18196,22 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates an existing virtual network rule. + * Deletes the managed database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -15110,7 +18225,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkRule} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15118,28 +18233,61 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, managedInstanceName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the virtual network rule with the given name. + * Updates an existing database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -15148,22 +18296,56 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the virtual network rule with the given name. + * Updates an existing database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} managedInstanceName The name of the managed instance. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The requested database resource state. + * + * @param {string} [parameters.collation] Collation of the managed database. + * + * @param {date} [parameters.restorePointInTime] Conditional. If createMode is + * PointInTimeRestore, this value is required. Specifies the point in time + * (ISO8601 format) of the source database that will be restored to create the + * new database. + * + * @param {string} [parameters.catalogCollation] Collation of the metadata + * catalog. Possible values include: 'DATABASE_DEFAULT', + * 'SQL_Latin1_General_CP1_CI_AS' + * + * @param {string} [parameters.createMode] Managed database create mode. + * PointInTimeRestore: Create a database by restoring a point in time backup of + * an existing database. SourceDatabaseName, SourceManagedInstanceName and + * PointInTime must be specified. RestoreExternalBackup: Create a database by + * restoring from external backup files. Collation, StorageContainerUri and + * StorageContainerSasToken must be specified. Possible values include: + * 'Default', 'RestoreExternalBackup', 'PointInTimeRestore' + * + * @param {string} [parameters.storageContainerUri] Conditional. If createMode + * is RestoreExternalBackup, this value is required. Specifies the uri of the + * storage container where backups for this restore are stored. + * + * @param {string} [parameters.sourceDatabaseId] The resource identifier of the + * source database associated with create operation of this database. + * + * @param {string} [parameters.storageContainerSasToken] Conditional. If + * createMode is RestoreExternalBackup, this value is required. Specifies the + * storage container sas token. + * + * @param {object} [parameters.tags] Resource tags. * * @param {object} [options] Optional Parameters. * @@ -15177,7 +18359,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ManagedDatabase} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15185,25 +18367,23 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ManagedDatabase} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabase} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, managedInstanceName: string, databaseName: string, parameters: models.ManagedDatabaseUpdate, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of virtual network rules in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of managed databases. * - * @param {string} serverName The name of the server. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -15212,20 +18392,17 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByInstanceNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of virtual network rules in a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of managed databases. * - * @param {string} serverName The name of the server. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -15239,7 +18416,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. + * @resolve {ManagedDatabaseListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15247,21 +18424,30 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRuleListResult} for more + * {ManagedDatabaseListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ManagedDatabaseListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByInstanceNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByInstanceNext(nextPageLink: string, callback: ServiceCallback): void; + listByInstanceNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ServerAutomaticTuningOperations + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ServerAutomaticTuningOperations { /** - * Creates or updates an existing virtual network rule. + * Retrieves server automatic tuning options. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -15269,17 +18455,6 @@ export interface VirtualNetworkRules { * * @param {string} serverName The name of the server. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. - * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -15287,31 +18462,20 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates or updates an existing virtual network rule. + * Retrieves server automatic tuning options. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. - * - * @param {object} parameters The requested virtual Network Rule Resource - * state. - * - * @param {string} parameters.virtualNetworkSubnetId The ARM resource id of the - * virtual network subnet. - * - * @param {boolean} [parameters.ignoreMissingVnetServiceEndpoint] Create - * firewall rule before the virtual network has vnet service endpoint enabled. + * @param {string} serverName The name of the server. * * @param {object} [options] Optional Parameters. * @@ -15325,7 +18489,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkRule} - The deserialized result object. + * @resolve {ServerAutomaticTuning} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15333,20 +18497,20 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkRule} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRule} for more information. + * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. + * See {@link ServerAutomaticTuning} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, parameters: models.VirtualNetworkRule, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the virtual network rule with the given name. + * Update automatic tuning options on server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -15354,7 +18518,12 @@ export interface VirtualNetworkRules { * * @param {string} serverName The name of the server. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {object} parameters The requested automatic tuning resource state. + * + * @param {string} [parameters.desiredState] Automatic tuning desired state. + * Possible values include: 'Custom', 'Auto', 'Unspecified' + * + * @param {object} [parameters.options] Automatic tuning options definition. * * @param {object} [options] Optional Parameters. * @@ -15363,14 +18532,14 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the virtual network rule with the given name. + * Update automatic tuning options on server. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -15378,7 +18547,12 @@ export interface VirtualNetworkRules { * * @param {string} serverName The name of the server. * - * @param {string} virtualNetworkRuleName The name of the virtual network rule. + * @param {object} parameters The requested automatic tuning resource state. + * + * @param {string} [parameters.desiredState] Automatic tuning desired state. + * Possible values include: 'Custom', 'Auto', 'Unspecified' + * + * @param {object} [parameters.options] Automatic tuning options definition. * * @param {object} [options] Optional Parameters. * @@ -15392,7 +18566,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ServerAutomaticTuning} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15400,22 +18574,38 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. + * See {@link ServerAutomaticTuning} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, virtualNetworkRuleName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ServerDnsAliases + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ServerDnsAliases { /** - * Gets a list of virtual network rules in a server. + * Gets a server DNS alias. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15424,17 +18614,23 @@ export interface VirtualNetworkRules { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of virtual network rules in a server. + * Gets a server DNS alias. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15448,7 +18644,7 @@ export interface VirtualNetworkRules { * * {Promise} A promise is returned. * - * @resolve {VirtualNetworkRuleListResult} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15456,38 +18652,29 @@ export interface VirtualNetworkRules { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {VirtualNetworkRuleListResult} [result] - The deserialized result object if an error did not occur. - * See {@link VirtualNetworkRuleListResult} for more - * information. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * LongTermRetentionBackups - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface LongTermRetentionBackups { + get(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a long term retention backup. - * - * @param {string} locationName The location of the database. + * Creates a server dns alias. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15496,22 +18683,23 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a long term retention backup. - * - * @param {string} locationName The location of the database. + * Creates a server dns alias. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15525,7 +18713,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackup} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15533,29 +18721,29 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackup} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackup} for more - * information. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - get(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database + * Deletes the server DNS alias with the given name. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15568,18 +18756,19 @@ export interface LongTermRetentionBackups { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database + * Deletes the server DNS alias with the given name. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15607,58 +18796,46 @@ export interface LongTermRetentionBackups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - deleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all long term retention backups for a database. - * - * @param {string} locationName The location of the database + * Gets a list of server DNS aliases for a server. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * * @param {object} [options] Optional Parameters. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all long term retention backups for a database. - * - * @param {string} locationName The location of the database + * Gets a list of server DNS aliases for a server. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * * @param {object} [options] Optional Parameters. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. - * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' - * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -15669,7 +18846,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {ServerDnsAliasListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15677,57 +18854,67 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more + * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAliasListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, callback: ServiceCallback): void; - listByDatabase(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; + listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the long term retention backups for a given location. + * Acquires server DNS alias from another server. * - * @param {string} locationName The location of the database + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. + * @param {string} dnsAliasName The name of the server dns alias. * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + acquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given location. + * Acquires server DNS alias from another server. * - * @param {string} locationName The location of the database + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. + * @param {string} dnsAliasName The name of the server dns alias. * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -15739,7 +18926,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15747,61 +18934,55 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocation(locationName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; + acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the long term retention backups for a given server. - * - * @param {string} locationName The location of the database + * Creates a server dns alias. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. + * @param {string} dnsAliasName The name of the server DNS alias. * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given server. - * - * @param {string} locationName The location of the database + * Creates a server dns alias. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {boolean} [options.onlyLatestPerDatabase] Whether or not to only get - * the latest backup for each database. + * @param {string} dnsAliasName The name of the server DNS alias. * - * @param {string} [options.databaseState] Whether to query against just live - * databases, just deleted databases, or all databases. Possible values - * include: 'All', 'Live', 'Deleted' + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -15813,7 +18994,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {ServerDnsAlias} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15821,29 +19002,29 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAlias} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(locationName: string, longTermRetentionServerName: string, options?: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(locationName: string, longTermRetentionServerName: string, callback: ServiceCallback): void; - listByServer(locationName: string, longTermRetentionServerName: string, options: { onlyLatestPerDatabase? : boolean, databaseState? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database + * Deletes the server DNS alias with the given name. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15856,18 +19037,19 @@ export interface LongTermRetentionBackups { * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a long term retention backup. - * - * @param {string} locationName The location of the database + * Deletes the server DNS alias with the given name. * - * @param {string} longTermRetentionServerName + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {string} longTermRetentionDatabaseName + * @param {string} serverName The name of the server that the alias is pointing + * to. * - * @param {string} backupName The backup name. + * @param {string} dnsAliasName The name of the server DNS alias. * * @param {object} [options] Optional Parameters. * @@ -15895,16 +19077,27 @@ export interface LongTermRetentionBackups { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, callback: ServiceCallback): void; - beginDeleteMethod(locationName: string, longTermRetentionServerName: string, longTermRetentionDatabaseName: string, backupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists all long term retention backups for a database. + * Acquires server DNS alias from another server. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -15913,17 +19106,28 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginAcquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists all long term retention backups for a database. + * Acquires server DNS alias from another server. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server that the alias is pointing + * to. + * + * @param {string} dnsAliasName The name of the server dns alias. + * + * @param {object} parameters + * + * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias + * that will be acquired to point to this server instead. * * @param {object} [options] Optional Parameters. * @@ -15937,7 +19141,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -15945,21 +19149,19 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; + beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Lists the long term retention backups for a given location. + * Gets a list of server DNS aliases for a server. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -15971,14 +19173,14 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given location. + * Gets a list of server DNS aliases for a server. * * @param {string} nextPageLink The NextLink from the previous successful call * to List operation. @@ -15995,7 +19197,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {ServerDnsAliasListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16003,24 +19205,38 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more + * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ServerDnsAliasListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; - listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByServerNext(nextPageLink: string, callback: ServiceCallback): void; + listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * RestorePoints + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface RestorePoints { /** - * Lists the long term retention backups for a given server. + * Gets a list of database restore points. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -16029,17 +19245,22 @@ export interface LongTermRetentionBackups { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Lists the long term retention backups for a given server. + * Gets a list of database restore points. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -16053,7 +19274,7 @@ export interface LongTermRetentionBackups { * * {Promise} A promise is returned. * - * @resolve {LongTermRetentionBackupListResult} - The deserialized result object. + * @resolve {RestorePointListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16061,30 +19282,21 @@ export interface LongTermRetentionBackups { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LongTermRetentionBackupListResult} [result] - The deserialized result object if an error did not occur. - * See {@link LongTermRetentionBackupListResult} for more + * {RestorePointListResult} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePointListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * BackupLongTermRetentionPolicies - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface BackupLongTermRetentionPolicies { + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a database's long term retention policy. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16092,7 +19304,13 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} serverName The name of the server. * - * @param {string} databaseName The name of the database. + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -16101,14 +19319,14 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a database's long term retention policy. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16118,6 +19336,12 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * + * @param {object} parameters The definition for creating the restore point of + * this database. + * + * @param {string} parameters.restorePointLabel The restore point label to + * apply + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16130,7 +19354,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16138,21 +19362,20 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; + create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Sets a database's long term retention policy. + * Gets a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16162,19 +19385,7 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -16183,14 +19394,14 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Sets a database's long term retention policy. + * Gets a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16200,19 +19411,7 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} restorePointName The name of the restore point. * * @param {object} [options] Optional Parameters. * @@ -16226,7 +19425,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16234,21 +19433,20 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a database's long term retention policy. + * Deletes a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16258,6 +19456,8 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * + * @param {string} restorePointName The name of the restore point. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16265,14 +19465,14 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a database's long term retention policy. + * Deletes a restore point. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16282,6 +19482,8 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * + * @param {string} restorePointName The name of the restore point. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16294,7 +19496,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16302,21 +19504,19 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Sets a database's long term retention policy. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16326,19 +19526,11 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * @param {object} parameters The definition for creating the restore point of + * this database. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -16347,14 +19539,14 @@ export interface BackupLongTermRetentionPolicies { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Sets a database's long term retention policy. + * Creates a restore point for a data warehouse. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16364,19 +19556,11 @@ export interface BackupLongTermRetentionPolicies { * * @param {string} databaseName The name of the database. * - * @param {object} parameters The long term retention policy info. - * - * @param {string} [parameters.weeklyRetention] The weekly retention policy for - * an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.monthlyRetention] The montly retention policy - * for an LTR backup in an ISO 8601 format. - * - * @param {string} [parameters.yearlyRetention] The yearly retention policy for - * an LTR backup in an ISO 8601 format. + * @param {object} parameters The definition for creating the restore point of + * this database. * - * @param {number} [parameters.weekOfYear] The week of year to take the yearly - * backup in an ISO 8601 format. + * @param {string} parameters.restorePointLabel The restore point label to + * apply * * @param {object} [options] Optional Parameters. * @@ -16390,7 +19574,7 @@ export interface BackupLongTermRetentionPolicies { * * {Promise} A promise is returned. * - * @resolve {BackupLongTermRetentionPolicy} - The deserialized result object. + * @resolve {RestorePoint} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16398,30 +19582,29 @@ export interface BackupLongTermRetentionPolicies { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {BackupLongTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. - * See {@link BackupLongTermRetentionPolicy} for more - * information. + * {RestorePoint} [result] - The deserialized result object if an error did not occur. + * See {@link RestorePoint} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.BackupLongTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; + beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } /** * @class - * ServerAutomaticTuningOperations + * DatabaseOperations * __NOTE__: An instance of this class is automatically created for an * instance of the SqlManagementClient. */ -export interface ServerAutomaticTuningOperations { +export interface DatabaseOperations { /** - * Retrieves server automatic tuning options. + * Cancels the asynchronous operation on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16429,6 +19612,10 @@ export interface ServerAutomaticTuningOperations { * * @param {string} serverName The name of the server. * + * @param {string} databaseName The name of the database. + * + * @param {uuid} operationId The operation identifier. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16436,14 +19623,14 @@ export interface ServerAutomaticTuningOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Retrieves server automatic tuning options. + * Cancels the asynchronous operation on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16451,6 +19638,10 @@ export interface ServerAutomaticTuningOperations { * * @param {string} serverName The name of the server. * + * @param {string} databaseName The name of the database. + * + * @param {uuid} operationId The operation identifier. + * * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the @@ -16463,7 +19654,7 @@ export interface ServerAutomaticTuningOperations { * * {Promise} A promise is returned. * - * @resolve {ServerAutomaticTuning} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16471,20 +19662,19 @@ export interface ServerAutomaticTuningOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. - * See {@link ServerAutomaticTuning} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Update automatic tuning options on server. + * Gets a list of operations performed on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16492,12 +19682,7 @@ export interface ServerAutomaticTuningOperations { * * @param {string} serverName The name of the server. * - * @param {object} parameters The requested automatic tuning resource state. - * - * @param {string} [parameters.desiredState] Automatic tuning desired state. - * Possible values include: 'Custom', 'Auto', 'Unspecified' - * - * @param {object} [parameters.options] Automatic tuning options definition. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -16506,14 +19691,14 @@ export interface ServerAutomaticTuningOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Update automatic tuning options on server. + * Gets a list of operations performed on the database. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -16521,12 +19706,7 @@ export interface ServerAutomaticTuningOperations { * * @param {string} serverName The name of the server. * - * @param {object} parameters The requested automatic tuning resource state. - * - * @param {string} [parameters.desiredState] Automatic tuning desired state. - * Possible values include: 'Custom', 'Auto', 'Unspecified' - * - * @param {object} [parameters.options] Automatic tuning options definition. + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -16540,7 +19720,7 @@ export interface ServerAutomaticTuningOperations { * * {Promise} A promise is returned. * - * @resolve {ServerAutomaticTuning} - The deserialized result object. + * @resolve {DatabaseOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16548,38 +19728,24 @@ export interface ServerAutomaticTuningOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerAutomaticTuning} [result] - The deserialized result object if an error did not occur. - * See {@link ServerAutomaticTuning} for more information. + * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DatabaseOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, callback: ServiceCallback): void; - update(resourceGroupName: string, serverName: string, parameters: models.ServerAutomaticTuning, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ServerDnsAliases - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ServerDnsAliases { + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a server DNS alias. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * Gets a list of operations performed on the database. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16588,23 +19754,17 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; - - /** - * Gets a server DNS alias. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. + listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + + /** + * Gets a list of operations performed on the database. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16618,7 +19778,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {DatabaseOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16626,29 +19786,40 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link DatabaseOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; + listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ElasticPoolOperations + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ElasticPoolOperations { /** - * Creates a server dns alias. + * Cancels the asynchronous operation on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} elasticPoolName + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -16657,23 +19828,24 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a server dns alias. + * Cancels the asynchronous operation on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} elasticPoolName + * + * @param {uuid} operationId The operation identifier. * * @param {object} [options] Optional Parameters. * @@ -16687,7 +19859,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {null} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16695,29 +19867,27 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {null} [result] - The deserialized result object if an error did not occur. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - createOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, callback: ServiceCallback): void; + cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server DNS alias with the given name. + * Gets a list of operations performed on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} elasticPoolName * * @param {object} [options] Optional Parameters. * @@ -16726,23 +19896,22 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByElasticPoolWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server DNS alias with the given name. + * Gets a list of operations performed on the elastic pool. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} serverName The name of the server. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} elasticPoolName * * @param {object} [options] Optional Parameters. * @@ -16756,7 +19925,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ElasticPoolOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16764,26 +19933,24 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ElasticPoolOperationListResult} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, callback: ServiceCallback): void; + listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server DNS aliases for a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of operations performed on the elastic pool. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16792,21 +19959,17 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerWithHttpOperationResponse(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByElasticPoolNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server DNS aliases for a server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. + * Gets a list of operations performed on the elastic pool. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -16820,7 +19983,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAliasListResult} - The deserialized result object. + * @resolve {ElasticPoolOperationListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16828,68 +19991,65 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAliasListResult} for more + * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. + * See {@link ElasticPoolOperationListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServer(resourceGroupName: string, serverName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServer(resourceGroupName: string, serverName: string, callback: ServiceCallback): void; - listByServer(resourceGroupName: string, serverName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByElasticPoolNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByElasticPoolNext(nextPageLink: string, callback: ServiceCallback): void; + listByElasticPoolNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * Capabilities + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface Capabilities { /** - * Acquires server DNS alias from another server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * Gets the subscription capabilities available for the specified location. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} locationName The location name whose capabilities are + * retrieved. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.include] If specified, restricts the response to + * only include the selected item. Possible values include: + * 'supportedEditions', 'supportedElasticPoolEditions', + * 'supportedManagedInstanceVersions' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - acquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationWithHttpOperationResponse(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Acquires server DNS alias from another server. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * Gets the subscription capabilities available for the specified location. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} locationName The location name whose capabilities are + * retrieved. * * @param {object} [options] Optional Parameters. * + * @param {string} [options.include] If specified, restricts the response to + * only include the selected item. Possible values include: + * 'supportedEditions', 'supportedElasticPoolEditions', + * 'supportedManagedInstanceVersions' + * * @param {object} [options.customHeaders] Headers that will be added to the * request * @@ -16900,7 +20060,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {LocationCapabilities} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16908,28 +20068,38 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {LocationCapabilities} [result] - The deserialized result object if an error did not occur. + * See {@link LocationCapabilities} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; - acquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByLocation(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(locationName: string, callback: ServiceCallback): void; + listByLocation(locationName: string, options: { include? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * InstanceFailoverGroups + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface InstanceFailoverGroups { /** - * Creates a server dns alias. + * Gets a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -16938,23 +20108,23 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a server dns alias. + * Gets a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -16968,7 +20138,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAlias} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -16976,29 +20146,58 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAlias} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAlias} for more information. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - beginCreateOrUpdate(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + get(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes the server DNS alias with the given name. + * Creates or updates a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The name of the region where the resource is + * located. + * + * @param {string} failoverGroupName The name of the failover group. + * + * @param {object} parameters The failover group parameters. + * + * @param {object} parameters.readWriteEndpoint Read-write endpoint of the + * failover group instance. + * + * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy + * of the read-write endpoint for the failover group. If failoverPolicy is + * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible + * values include: 'Manual', 'Automatic' + * + * @param {number} + * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace + * period before failover with data loss is attempted for the read-write + * endpoint. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. + * + * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the + * failover group instance. + * + * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy + * of the read-only endpoint for the failover group. Possible values include: + * 'Disabled', 'Enabled' + * + * @param {array} parameters.partnerRegions Partner region information for the + * failover group. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {array} parameters.managedInstancePairs List of managed instance + * pairs in the failover group. * * @param {object} [options] Optional Parameters. * @@ -17007,23 +20206,52 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes the server DNS alias with the given name. + * Creates or updates a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} dnsAliasName The name of the server DNS alias. + * @param {string} failoverGroupName The name of the failover group. + * + * @param {object} parameters The failover group parameters. + * + * @param {object} parameters.readWriteEndpoint Read-write endpoint of the + * failover group instance. + * + * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy + * of the read-write endpoint for the failover group. If failoverPolicy is + * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible + * values include: 'Manual', 'Automatic' + * + * @param {number} + * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace + * period before failover with data loss is attempted for the read-write + * endpoint. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. + * + * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the + * failover group instance. + * + * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy + * of the read-only endpoint for the failover group. Possible values include: + * 'Disabled', 'Enabled' + * + * @param {array} parameters.partnerRegions Partner region information for the + * failover group. + * + * @param {array} parameters.managedInstancePairs List of managed instance + * pairs in the failover group. * * @param {object} [options] Optional Parameters. * @@ -17037,7 +20265,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17045,33 +20273,29 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, callback: ServiceCallback): void; - beginDeleteMethod(resourceGroupName: string, serverName: string, dnsAliasName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Acquires server DNS alias from another server. + * Deletes a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17084,24 +20308,19 @@ export interface ServerDnsAliases { * * @reject {Error|ServiceError} - The error object. */ - beginAcquireWithHttpOperationResponse(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + deleteMethodWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Acquires server DNS alias from another server. + * Deletes a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server that the alias is pointing - * to. - * - * @param {string} dnsAliasName The name of the server dns alias. - * - * @param {object} parameters + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} [parameters.oldServerDnsAliasId] The id of the server alias - * that will be acquired to point to this server instead. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17129,16 +20348,20 @@ export interface ServerDnsAliases { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, callback: ServiceCallback): void; - beginAcquire(resourceGroupName: string, serverName: string, dnsAliasName: string, parameters: models.ServerDnsAliasAcquisition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + deleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of server DNS aliases for a server. + * Lists the failover groups in a location. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -17147,17 +20370,21 @@ export interface ServerDnsAliases { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByServerNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationWithHttpOperationResponse(resourceGroupName: string, locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of server DNS aliases for a server. + * Lists the failover groups in a location. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} locationName The name of the region where the resource is + * located. * * @param {object} [options] Optional Parameters. * @@ -17171,7 +20398,7 @@ export interface ServerDnsAliases { * * {Promise} A promise is returned. * - * @resolve {ServerDnsAliasListResult} - The deserialized result object. + * @resolve {InstanceFailoverGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17179,38 +20406,31 @@ export interface ServerDnsAliases { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ServerDnsAliasListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ServerDnsAliasListResult} for more + * {InstanceFailoverGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByServerNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByServerNext(nextPageLink: string, callback: ServiceCallback): void; - listByServerNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * RestorePoints - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface RestorePoints { + listByLocation(resourceGroupName: string, locationName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocation(resourceGroupName: string, locationName: string, callback: ServiceCallback): void; + listByLocation(resourceGroupName: string, locationName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of database restore points. + * Fails over from the current primary managed instance to this managed + * instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} databaseName The name of the database. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17219,22 +20439,24 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + failoverWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of database restore points. + * Fails over from the current primary managed instance to this managed + * instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} databaseName The name of the database. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17248,7 +20470,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePointListResult} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17256,35 +20478,30 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePointListResult} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePointListResult} for more - * information. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + failover(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + failover(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + failover(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a restore point for a data warehouse. + * Fails over from the current primary managed instance to this managed + * instance. This operation might result in data loss. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17293,28 +20510,24 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - createWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + forceFailoverAllowDataLossWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a restore point for a data warehouse. + * Fails over from the current primary managed instance to this managed + * instance. This operation might result in data loss. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17328,7 +20541,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17336,30 +20549,58 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; - create(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + forceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a restore point. + * Creates or updates a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} databaseName The name of the database. + * @param {string} failoverGroupName The name of the failover group. * - * @param {string} restorePointName The name of the restore point. + * @param {object} parameters The failover group parameters. + * + * @param {object} parameters.readWriteEndpoint Read-write endpoint of the + * failover group instance. + * + * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy + * of the read-write endpoint for the failover group. If failoverPolicy is + * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible + * values include: 'Manual', 'Automatic' + * + * @param {number} + * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace + * period before failover with data loss is attempted for the read-write + * endpoint. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. + * + * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the + * failover group instance. + * + * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy + * of the read-only endpoint for the failover group. Possible values include: + * 'Disabled', 'Enabled' + * + * @param {array} parameters.partnerRegions Partner region information for the + * failover group. + * + * @param {array} parameters.managedInstancePairs List of managed instance + * pairs in the failover group. * * @param {object} [options] Optional Parameters. * @@ -17368,24 +20609,52 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a restore point. + * Creates or updates a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} databaseName The name of the database. + * @param {string} failoverGroupName The name of the failover group. * - * @param {string} restorePointName The name of the restore point. + * @param {object} parameters The failover group parameters. + * + * @param {object} parameters.readWriteEndpoint Read-write endpoint of the + * failover group instance. + * + * @param {string} parameters.readWriteEndpoint.failoverPolicy Failover policy + * of the read-write endpoint for the failover group. If failoverPolicy is + * Automatic then failoverWithDataLossGracePeriodMinutes is required. Possible + * values include: 'Manual', 'Automatic' + * + * @param {number} + * [parameters.readWriteEndpoint.failoverWithDataLossGracePeriodMinutes] Grace + * period before failover with data loss is attempted for the read-write + * endpoint. If failoverPolicy is Automatic then + * failoverWithDataLossGracePeriodMinutes is required. + * + * @param {object} [parameters.readOnlyEndpoint] Read-only endpoint of the + * failover group instance. + * + * @param {string} [parameters.readOnlyEndpoint.failoverPolicy] Failover policy + * of the read-only endpoint for the failover group. Possible values include: + * 'Disabled', 'Enabled' + * + * @param {array} parameters.partnerRegions Partner region information for the + * failover group. + * + * @param {array} parameters.managedInstancePairs List of managed instance + * pairs in the failover group. * * @param {object} [options] Optional Parameters. * @@ -17399,7 +20668,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17407,30 +20676,29 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; - get(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, locationName: string, failoverGroupName: string, parameters: models.InstanceFailoverGroup, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Deletes a restore point. + * Deletes a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} restorePointName The name of the restore point. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17443,20 +20711,19 @@ export interface RestorePoints { * * @reject {Error|ServiceError} - The error object. */ - deleteMethodWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Deletes a restore point. + * Deletes a failover group. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} restorePointName The name of the restore point. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17484,27 +20751,23 @@ export interface RestorePoints { * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, callback: ServiceCallback): void; - deleteMethod(resourceGroupName: string, serverName: string, databaseName: string, restorePointName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + beginDeleteMethod(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Creates a restore point for a data warehouse. + * Fails over from the current primary managed instance to this managed + * instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17513,28 +20776,24 @@ export interface RestorePoints { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - beginCreateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginFailoverWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Creates a restore point for a data warehouse. + * Fails over from the current primary managed instance to this managed + * instance. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. - * - * @param {object} parameters The definition for creating the restore point of - * this database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {string} parameters.restorePointLabel The restore point label to - * apply + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17548,7 +20807,7 @@ export interface RestorePoints { * * {Promise} A promise is returned. * - * @resolve {RestorePoint} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17556,39 +20815,30 @@ export interface RestorePoints { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {RestorePoint} [result] - The deserialized result object if an error did not occur. - * See {@link RestorePoint} for more information. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, callback: ServiceCallback): void; - beginCreate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.CreateDatabaseRestorePointDefinition, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * DatabaseOperations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface DatabaseOperations { + beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + beginFailover(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels the asynchronous operation on the database. + * Fails over from the current primary managed instance to this managed + * instance. This operation might result in data loss. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {uuid} operationId The operation identifier. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17597,24 +20847,24 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginForceFailoverAllowDataLossWithHttpOperationResponse(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels the asynchronous operation on the database. + * Fails over from the current primary managed instance to this managed + * instance. This operation might result in data loss. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource * Manager API or the portal. * - * @param {string} serverName The name of the server. - * - * @param {string} databaseName The name of the database. + * @param {string} locationName The name of the region where the resource is + * located. * - * @param {uuid} operationId The operation identifier. + * @param {string} failoverGroupName The name of the failover group. * * @param {object} [options] Optional Parameters. * @@ -17628,7 +20878,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {InstanceFailoverGroup} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17636,27 +20886,23 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {InstanceFailoverGroup} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroup} for more information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, callback: ServiceCallback): void; - cancel(resourceGroupName: string, serverName: string, databaseName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, callback: ServiceCallback): void; + beginForceFailoverAllowDataLoss(resourceGroupName: string, locationName: string, failoverGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists the failover groups in a location. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17665,22 +20911,17 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + listByLocationNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the database. - * - * @param {string} resourceGroupName The name of the resource group that - * contains the resource. You can obtain this value from the Azure Resource - * Manager API or the portal. - * - * @param {string} serverName The name of the server. + * Lists the failover groups in a location. * - * @param {string} databaseName The name of the database. + * @param {string} nextPageLink The NextLink from the previous successful call + * to List operation. * * @param {object} [options] Optional Parameters. * @@ -17694,7 +20935,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {DatabaseOperationListResult} - The deserialized result object. + * @resolve {InstanceFailoverGroupListResult} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17702,24 +20943,38 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DatabaseOperationListResult} for more + * {InstanceFailoverGroupListResult} [result] - The deserialized result object if an error did not occur. + * See {@link InstanceFailoverGroupListResult} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; - listByDatabase(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + listByLocationNext(nextPageLink: string, callback: ServiceCallback): void; + listByLocationNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; +} + +/** + * @class + * ShortTermRetentionPolicies + * __NOTE__: An instance of this class is automatically created for an + * instance of the SqlManagementClient. + */ +export interface ShortTermRetentionPolicies { /** - * Gets a list of operations performed on the database. + * Gets a database's short term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -17728,17 +20983,22 @@ export interface DatabaseOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByDatabaseNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + getWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the database. + * Gets a database's short term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. * * @param {object} [options] Optional Parameters. * @@ -17752,7 +21012,7 @@ export interface DatabaseOperations { * * {Promise} A promise is returned. * - * @resolve {DatabaseOperationListResult} - The deserialized result object. + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17760,30 +21020,21 @@ export interface DatabaseOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {DatabaseOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link DatabaseOperationListResult} for more + * {ShortTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByDatabaseNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByDatabaseNext(nextPageLink: string, callback: ServiceCallback): void; - listByDatabaseNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * ElasticPoolOperations - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface ElasticPoolOperations { + get(resourceGroupName: string, serverName: string, databaseName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + get(resourceGroupName: string, serverName: string, databaseName: string, callback: ServiceCallback): void; + get(resourceGroupName: string, serverName: string, databaseName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Cancels the asynchronous operation on the elastic pool. + * Updates a database's short term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17791,9 +21042,12 @@ export interface ElasticPoolOperations { * * @param {string} serverName The name of the server. * - * @param {string} elasticPoolName + * @param {string} databaseName The name of the database. * - * @param {uuid} operationId The operation identifier. + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17802,14 +21056,14 @@ export interface ElasticPoolOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - cancelWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + createOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Cancels the asynchronous operation on the elastic pool. + * Updates a database's short term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17817,9 +21071,12 @@ export interface ElasticPoolOperations { * * @param {string} serverName The name of the server. * - * @param {string} elasticPoolName + * @param {string} databaseName The name of the database. * - * @param {uuid} operationId The operation identifier. + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17833,7 +21090,7 @@ export interface ElasticPoolOperations { * * {Promise} A promise is returned. * - * @resolve {null} - The deserialized result object. + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17841,19 +21098,21 @@ export interface ElasticPoolOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {null} [result] - The deserialized result object if an error did not occur. + * {ShortTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, callback: ServiceCallback): void; - cancel(resourceGroupName: string, serverName: string, elasticPoolName: string, operationId: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, callback: ServiceCallback): void; + createOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the elastic pool. + * Updates a database's short term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17861,7 +21120,12 @@ export interface ElasticPoolOperations { * * @param {string} serverName The name of the server. * - * @param {string} elasticPoolName + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17870,14 +21134,14 @@ export interface ElasticPoolOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByElasticPoolWithHttpOperationResponse(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + updateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the elastic pool. + * Updates a database's short term retention policy. * * @param {string} resourceGroupName The name of the resource group that * contains the resource. You can obtain this value from the Azure Resource @@ -17885,7 +21149,12 @@ export interface ElasticPoolOperations { * * @param {string} serverName The name of the server. * - * @param {string} elasticPoolName + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17899,7 +21168,7 @@ export interface ElasticPoolOperations { * * {Promise} A promise is returned. * - * @resolve {ElasticPoolOperationListResult} - The deserialized result object. + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17907,24 +21176,34 @@ export interface ElasticPoolOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ElasticPoolOperationListResult} for more + * {ShortTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, callback: ServiceCallback): void; - listByElasticPool(resourceGroupName: string, serverName: string, elasticPoolName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + update(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, callback: ServiceCallback): void; + update(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets a list of operations performed on the elastic pool. + * Updates a database's short term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17933,17 +21212,27 @@ export interface ElasticPoolOperations { * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByElasticPoolNextWithHttpOperationResponse(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets a list of operations performed on the elastic pool. + * Updates a database's short term retention policy. * - * @param {string} nextPageLink The NextLink from the previous successful call - * to List operation. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. * * @param {object} [options] Optional Parameters. * @@ -17957,7 +21246,7 @@ export interface ElasticPoolOperations { * * {Promise} A promise is returned. * - * @resolve {ElasticPoolOperationListResult} - The deserialized result object. + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -17965,64 +21254,65 @@ export interface ElasticPoolOperations { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {ElasticPoolOperationListResult} [result] - The deserialized result object if an error did not occur. - * See {@link ElasticPoolOperationListResult} for more + * {ShortTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByElasticPoolNext(nextPageLink: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; - listByElasticPoolNext(nextPageLink: string, callback: ServiceCallback): void; - listByElasticPoolNext(nextPageLink: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; -} - -/** - * @class - * Capabilities - * __NOTE__: An instance of this class is automatically created for an - * instance of the SqlManagementClient. - */ -export interface Capabilities { + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, callback: ServiceCallback): void; + beginCreateOrUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; /** - * Gets the subscription capabilities available for the specified location. + * Updates a database's short term retention policy. * - * @param {string} locationName The location name whose capabilities are - * retrieved. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server. * - * @param {string} [options.include] If specified, restricts the response to - * only include the selected item. Possible values include: - * 'supportedEditions', 'supportedElasticPoolEditions', - * 'supportedManagedInstanceVersions' + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request * * @returns {Promise} A promise is returned * - * @resolve {HttpOperationResponse} - The deserialized result object. + * @resolve {HttpOperationResponse} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. */ - listByLocationWithHttpOperationResponse(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise>; + beginUpdateWithHttpOperationResponse(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise>; /** - * Gets the subscription capabilities available for the specified location. + * Updates a database's short term retention policy. * - * @param {string} locationName The location name whose capabilities are - * retrieved. + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. * - * @param {object} [options] Optional Parameters. + * @param {string} serverName The name of the server. * - * @param {string} [options.include] If specified, restricts the response to - * only include the selected item. Possible values include: - * 'supportedEditions', 'supportedElasticPoolEditions', - * 'supportedManagedInstanceVersions' + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. * * @param {object} [options.customHeaders] Headers that will be added to the * request @@ -18034,7 +21324,7 @@ export interface Capabilities { * * {Promise} A promise is returned. * - * @resolve {LocationCapabilities} - The deserialized result object. + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. * * @reject {Error|ServiceError} - The error object. * @@ -18042,14 +21332,15 @@ export interface Capabilities { * * {Error|ServiceError} err - The Error object if an error occurred, null otherwise. * - * {LocationCapabilities} [result] - The deserialized result object if an error did not occur. - * See {@link LocationCapabilities} for more information. + * {ShortTermRetentionPolicy} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. * * {WebResource} [request] - The HTTP Request object if an error did not occur. * * {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. */ - listByLocation(locationName: string, options?: { include? : string, customHeaders? : { [headerName: string]: string; } }): Promise; - listByLocation(locationName: string, callback: ServiceCallback): void; - listByLocation(locationName: string, options: { include? : string, customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options?: { customHeaders? : { [headerName: string]: string; } }): Promise; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, callback: ServiceCallback): void; + beginUpdate(resourceGroupName: string, serverName: string, databaseName: string, parameters: models.ShortTermRetentionPolicy, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback): void; } diff --git a/lib/services/sqlManagement2/lib/operations/index.js b/lib/services/sqlManagement2/lib/operations/index.js index 56d738959a..216e19d49f 100644 --- a/lib/services/sqlManagement2/lib/operations/index.js +++ b/lib/services/sqlManagement2/lib/operations/index.js @@ -41,6 +41,7 @@ exports.DatabaseBlobAuditingPolicies = require('./databaseBlobAuditingPolicies') exports.DatabaseAutomaticTuningOperations = require('./databaseAutomaticTuningOperations'); exports.EncryptionProtectors = require('./encryptionProtectors'); exports.FailoverGroups = require('./failoverGroups'); +exports.ManagedInstances = require('./managedInstances'); exports.Operations = require('./operations'); exports.ServerKeys = require('./serverKeys'); exports.SyncAgents = require('./syncAgents'); @@ -50,9 +51,12 @@ exports.SubscriptionUsages = require('./subscriptionUsages'); exports.VirtualNetworkRules = require('./virtualNetworkRules'); exports.LongTermRetentionBackups = require('./longTermRetentionBackups'); exports.BackupLongTermRetentionPolicies = require('./backupLongTermRetentionPolicies'); +exports.ManagedDatabases = require('./managedDatabases'); exports.ServerAutomaticTuningOperations = require('./serverAutomaticTuningOperations'); exports.ServerDnsAliases = require('./serverDnsAliases'); exports.RestorePoints = require('./restorePoints'); exports.DatabaseOperations = require('./databaseOperations'); exports.ElasticPoolOperations = require('./elasticPoolOperations'); exports.Capabilities = require('./capabilities'); +exports.InstanceFailoverGroups = require('./instanceFailoverGroups'); +exports.ShortTermRetentionPolicies = require('./shortTermRetentionPolicies'); diff --git a/lib/services/sqlManagement2/lib/operations/shortTermRetentionPolicies.js b/lib/services/sqlManagement2/lib/operations/shortTermRetentionPolicies.js new file mode 100644 index 0000000000..1d94f15d13 --- /dev/null +++ b/lib/services/sqlManagement2/lib/operations/shortTermRetentionPolicies.js @@ -0,0 +1,1231 @@ +/* + * 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. + */ + +'use strict'; + +const msRest = require('ms-rest'); +const msRestAzure = require('ms-rest-azure'); +const WebResource = msRest.WebResource; + +/** + * Gets a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _get(resourceGroupName, serverName, databaseName, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let policyName = 'default'; + let apiVersion = '2017-10-01-preview'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (serverName === null || serverName === undefined || typeof serverName.valueOf() !== 'string') { + throw new Error('serverName cannot be null or undefined and it must be of type string.'); + } + if (databaseName === null || databaseName === undefined || typeof databaseName.valueOf() !== 'string') { + throw new Error('databaseName cannot be null or undefined and it must be of type string.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{serverName}', encodeURIComponent(serverName)); + requestUrl = requestUrl.replace('{databaseName}', encodeURIComponent(databaseName)); + requestUrl = requestUrl.replace('{policyName}', encodeURIComponent(policyName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'GET'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + httpRequest.body = null; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + + +/** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _createOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + + +/** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _update(resourceGroupName, serverName, databaseName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + + if (!callback) { + throw new Error('callback cannot be null.'); + } + + // Send request + this.beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, parsedResult, httpRequest, response) => { + if (err) return callback(err); + + let initialResult = new msRest.HttpOperationResponse(); + initialResult.request = httpRequest; + initialResult.response = response; + initialResult.body = response.body; + client.getLongRunningOperationResult(initialResult, options, (err, pollingResult) => { + if (err) return callback(err); + + // Create Result + let result = null; + + httpRequest = pollingResult.request; + response = pollingResult.response; + let responseBody = pollingResult.body; + if (responseBody === '') responseBody = null; + + // Deserialize Response + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + + return callback(null, result, httpRequest, response); + }); + }); +} + +/** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let policyName = 'default'; + let apiVersion = '2017-10-01-preview'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (serverName === null || serverName === undefined || typeof serverName.valueOf() !== 'string') { + throw new Error('serverName cannot be null or undefined and it must be of type string.'); + } + if (databaseName === null || databaseName === undefined || typeof databaseName.valueOf() !== 'string') { + throw new Error('databaseName cannot be null or undefined and it must be of type string.'); + } + if (parameters === null || parameters === undefined) { + throw new Error('parameters cannot be null or undefined.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{serverName}', encodeURIComponent(serverName)); + requestUrl = requestUrl.replace('{databaseName}', encodeURIComponent(databaseName)); + requestUrl = requestUrl.replace('{policyName}', encodeURIComponent(policyName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PUT'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (parameters !== null && parameters !== undefined) { + let requestModelMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + requestModel = client.serialize(requestModelMapper, parameters, 'parameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(parameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} callback - The callback. + * + * @returns {function} callback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ +function _beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, callback) { + /* jshint validthis: true */ + let client = this.client; + if(!callback && typeof options === 'function') { + callback = options; + options = null; + } + if (!callback) { + throw new Error('callback cannot be null.'); + } + let policyName = 'default'; + let apiVersion = '2017-10-01-preview'; + // Validate + try { + if (resourceGroupName === null || resourceGroupName === undefined || typeof resourceGroupName.valueOf() !== 'string') { + throw new Error('resourceGroupName cannot be null or undefined and it must be of type string.'); + } + if (serverName === null || serverName === undefined || typeof serverName.valueOf() !== 'string') { + throw new Error('serverName cannot be null or undefined and it must be of type string.'); + } + if (databaseName === null || databaseName === undefined || typeof databaseName.valueOf() !== 'string') { + throw new Error('databaseName cannot be null or undefined and it must be of type string.'); + } + if (parameters === null || parameters === undefined) { + throw new Error('parameters cannot be null or undefined.'); + } + if (this.client.subscriptionId === null || this.client.subscriptionId === undefined || typeof this.client.subscriptionId.valueOf() !== 'string') { + throw new Error('this.client.subscriptionId cannot be null or undefined and it must be of type string.'); + } + if (this.client.acceptLanguage !== null && this.client.acceptLanguage !== undefined && typeof this.client.acceptLanguage.valueOf() !== 'string') { + throw new Error('this.client.acceptLanguage must be of type string.'); + } + } catch (error) { + return callback(error); + } + + // Construct URL + let baseUrl = this.client.baseUri; + let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/backupShortTermRetentionPolicies/{policyName}'; + requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); + requestUrl = requestUrl.replace('{serverName}', encodeURIComponent(serverName)); + requestUrl = requestUrl.replace('{databaseName}', encodeURIComponent(databaseName)); + requestUrl = requestUrl.replace('{policyName}', encodeURIComponent(policyName)); + requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); + let queryParameters = []; + queryParameters.push('api-version=' + encodeURIComponent(apiVersion)); + if (queryParameters.length > 0) { + requestUrl += '?' + queryParameters.join('&'); + } + + // Create HTTP transport objects + let httpRequest = new WebResource(); + httpRequest.method = 'PATCH'; + httpRequest.url = requestUrl; + httpRequest.headers = {}; + // Set Headers + httpRequest.headers['Content-Type'] = 'application/json; charset=utf-8'; + if (this.client.generateClientRequestId) { + httpRequest.headers['x-ms-client-request-id'] = msRestAzure.generateUuid(); + } + if (this.client.acceptLanguage !== undefined && this.client.acceptLanguage !== null) { + httpRequest.headers['accept-language'] = this.client.acceptLanguage; + } + if(options) { + for(let headerName in options['customHeaders']) { + if (options['customHeaders'].hasOwnProperty(headerName)) { + httpRequest.headers[headerName] = options['customHeaders'][headerName]; + } + } + } + // Serialize Request + let requestContent = null; + let requestModel = null; + try { + if (parameters !== null && parameters !== undefined) { + let requestModelMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + requestModel = client.serialize(requestModelMapper, parameters, 'parameters'); + requestContent = JSON.stringify(requestModel); + } + } catch (error) { + let serializationError = new Error(`Error "${error.message}" occurred in serializing the ` + + `payload - ${JSON.stringify(parameters, null, 2)}.`); + return callback(serializationError); + } + httpRequest.body = requestContent; + // Send Request + return client.pipeline(httpRequest, (err, response, responseBody) => { + if (err) { + return callback(err); + } + let statusCode = response.statusCode; + if (statusCode !== 200 && statusCode !== 202) { + let error = new Error(responseBody); + error.statusCode = response.statusCode; + error.request = msRest.stripRequest(httpRequest); + error.response = msRest.stripResponse(response); + if (responseBody === '') responseBody = null; + let parsedErrorResponse; + try { + parsedErrorResponse = JSON.parse(responseBody); + if (parsedErrorResponse) { + if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; + if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; + if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; + } + if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { + let resultMapper = new client.models['CloudError']().mapper(); + error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); + } + } catch (defaultError) { + error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + + `- "${responseBody}" for the default response.`; + return callback(error); + } + return callback(error); + } + // Create Result + let result = null; + if (responseBody === '') responseBody = null; + // Deserialize Response + if (statusCode === 200) { + let parsedResponse = null; + try { + parsedResponse = JSON.parse(responseBody); + result = JSON.parse(responseBody); + if (parsedResponse !== null && parsedResponse !== undefined) { + let resultMapper = new client.models['ShortTermRetentionPolicy']().mapper(); + result = client.deserialize(resultMapper, parsedResponse, 'result'); + } + } catch (error) { + let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); + deserializationError.request = msRest.stripRequest(httpRequest); + deserializationError.response = msRest.stripResponse(response); + return callback(deserializationError); + } + } + + return callback(null, result, httpRequest, response); + }); +} + +/** Class representing a ShortTermRetentionPolicies. */ +class ShortTermRetentionPolicies { + /** + * Create a ShortTermRetentionPolicies. + * @param {SqlManagementClient} client Reference to the service client. + */ + constructor(client) { + this.client = client; + this._get = _get; + this._createOrUpdate = _createOrUpdate; + this._update = _update; + this._beginCreateOrUpdate = _beginCreateOrUpdate; + this._beginUpdate = _beginUpdate; + } + + /** + * Gets a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + getWithHttpOperationResponse(resourceGroupName, serverName, databaseName, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._get(resourceGroupName, serverName, databaseName, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Gets a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + get(resourceGroupName, serverName, databaseName, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._get(resourceGroupName, serverName, databaseName, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._get(resourceGroupName, serverName, databaseName, options, optionalCallback); + } + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + createOrUpdateWithHttpOperationResponse(resourceGroupName, serverName, databaseName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + createOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._createOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._createOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback); + } + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + updateWithHttpOperationResponse(resourceGroupName, serverName, databaseName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._update(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + update(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._update(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._update(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback); + } + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginCreateOrUpdateWithHttpOperationResponse(resourceGroupName, serverName, databaseName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginCreateOrUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback); + } + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @returns {Promise} A promise is returned + * + * @resolve {HttpOperationResponse} - The deserialized result object. + * + * @reject {Error} - The error object. + */ + beginUpdateWithHttpOperationResponse(resourceGroupName, serverName, databaseName, parameters, options) { + let client = this.client; + let self = this; + return new Promise((resolve, reject) => { + self._beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + let httpOperationResponse = new msRest.HttpOperationResponse(request, response); + httpOperationResponse.body = result; + if (err) { reject(err); } + else { resolve(httpOperationResponse); } + return; + }); + }); + } + + /** + * Updates a database's short term retention policy. + * + * @param {string} resourceGroupName The name of the resource group that + * contains the resource. You can obtain this value from the Azure Resource + * Manager API or the portal. + * + * @param {string} serverName The name of the server. + * + * @param {string} databaseName The name of the database. + * + * @param {object} parameters The short term retention policy info. + * + * @param {number} [parameters.retentionDays] The backup retention period in + * days. This is how many days Point-in-Time Restore will be supported. + * + * @param {object} [options] Optional Parameters. + * + * @param {object} [options.customHeaders] Headers that will be added to the + * request + * + * @param {function} [optionalCallback] - The optional callback. + * + * @returns {function|Promise} If a callback was passed as the last parameter + * then it returns the callback else returns a Promise. + * + * {Promise} A promise is returned + * + * @resolve {ShortTermRetentionPolicy} - The deserialized result object. + * + * @reject {Error} - The error object. + * + * {function} optionalCallback(err, result, request, response) + * + * {Error} err - The Error object if an error occurred, null otherwise. + * + * {object} [result] - The deserialized result object if an error did not occur. + * See {@link ShortTermRetentionPolicy} for more + * information. + * + * {object} [request] - The HTTP Request object if an error did not occur. + * + * {stream} [response] - The HTTP Response stream if an error did not occur. + */ + beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback) { + let client = this.client; + let self = this; + if (!optionalCallback && typeof options === 'function') { + optionalCallback = options; + options = null; + } + if (!optionalCallback) { + return new Promise((resolve, reject) => { + self._beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, (err, result, request, response) => { + if (err) { reject(err); } + else { resolve(result); } + return; + }); + }); + } else { + return self._beginUpdate(resourceGroupName, serverName, databaseName, parameters, options, optionalCallback); + } + } + +} + +module.exports = ShortTermRetentionPolicies; diff --git a/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts b/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts index 951e647e01..9063d7659f 100644 --- a/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts +++ b/lib/services/sqlManagement2/lib/sqlManagementClient.d.ts @@ -81,6 +81,7 @@ export default class SqlManagementClient extends AzureServiceClient { databaseAutomaticTuningOperations: operations.DatabaseAutomaticTuningOperations; encryptionProtectors: operations.EncryptionProtectors; failoverGroups: operations.FailoverGroups; + managedInstances: operations.ManagedInstances; operations: operations.Operations; serverKeys: operations.ServerKeys; syncAgents: operations.SyncAgents; @@ -90,12 +91,15 @@ export default class SqlManagementClient extends AzureServiceClient { virtualNetworkRules: operations.VirtualNetworkRules; longTermRetentionBackups: operations.LongTermRetentionBackups; backupLongTermRetentionPolicies: operations.BackupLongTermRetentionPolicies; + managedDatabases: operations.ManagedDatabases; serverAutomaticTuningOperations: operations.ServerAutomaticTuningOperations; serverDnsAliases: operations.ServerDnsAliases; restorePoints: operations.RestorePoints; databaseOperations: operations.DatabaseOperations; elasticPoolOperations: operations.ElasticPoolOperations; capabilities: operations.Capabilities; + instanceFailoverGroups: operations.InstanceFailoverGroups; + shortTermRetentionPolicies: operations.ShortTermRetentionPolicies; } export { SqlManagementClient, models as SqlManagementModels }; diff --git a/lib/services/sqlManagement2/lib/sqlManagementClient.js b/lib/services/sqlManagement2/lib/sqlManagementClient.js index 4c2f9a8ebd..184fb325a5 100644 --- a/lib/services/sqlManagement2/lib/sqlManagementClient.js +++ b/lib/services/sqlManagement2/lib/sqlManagementClient.js @@ -98,6 +98,7 @@ class SqlManagementClient extends ServiceClient { this.databaseAutomaticTuningOperations = new operations.DatabaseAutomaticTuningOperations(this); this.encryptionProtectors = new operations.EncryptionProtectors(this); this.failoverGroups = new operations.FailoverGroups(this); + this.managedInstances = new operations.ManagedInstances(this); this.operations = new operations.Operations(this); this.serverKeys = new operations.ServerKeys(this); this.syncAgents = new operations.SyncAgents(this); @@ -107,12 +108,15 @@ class SqlManagementClient extends ServiceClient { this.virtualNetworkRules = new operations.VirtualNetworkRules(this); this.longTermRetentionBackups = new operations.LongTermRetentionBackups(this); this.backupLongTermRetentionPolicies = new operations.BackupLongTermRetentionPolicies(this); + this.managedDatabases = new operations.ManagedDatabases(this); this.serverAutomaticTuningOperations = new operations.ServerAutomaticTuningOperations(this); this.serverDnsAliases = new operations.ServerDnsAliases(this); this.restorePoints = new operations.RestorePoints(this); this.databaseOperations = new operations.DatabaseOperations(this); this.elasticPoolOperations = new operations.ElasticPoolOperations(this); this.capabilities = new operations.Capabilities(this); + this.instanceFailoverGroups = new operations.InstanceFailoverGroups(this); + this.shortTermRetentionPolicies = new operations.ShortTermRetentionPolicies(this); this.models = models; msRest.addSerializationMixin(this); }