diff --git a/sdk/cosmosdb/arm-cosmosdb/_meta.json b/sdk/cosmosdb/arm-cosmosdb/_meta.json index 4cf354c6b987..43f47fcd6e1f 100644 --- a/sdk/cosmosdb/arm-cosmosdb/_meta.json +++ b/sdk/cosmosdb/arm-cosmosdb/_meta.json @@ -1,8 +1,8 @@ { - "commit": "ac98588da3cf3c3e043568adc8a6cc122ad8d6a7", + "commit": "7b99d88798aa1ba10cbcc9fd0aa978869ecb5610", "readme": "specification/cosmos-db/resource-manager/readme.md", - "autorest_command": "autorest --version=3.9.3 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\cosmos-db\\resource-manager\\readme.md --use=@autorest/typescript@6.0.2 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/cosmos-db/resource-manager/readme.md --use=@autorest/typescript@^6.0.4", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.7.0", - "use": "@autorest/typescript@6.0.2" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.2", + "use": "@autorest/typescript@^6.0.4" } \ No newline at end of file diff --git a/sdk/cosmosdb/arm-cosmosdb/package.json b/sdk/cosmosdb/arm-cosmosdb/package.json index 0ae66864ff59..44e24bbb16a1 100644 --- a/sdk/cosmosdb/arm-cosmosdb/package.json +++ b/sdk/cosmosdb/arm-cosmosdb/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for CosmosDBManagementClient.", - "version": "16.0.0-beta.7", + "version": "1.0.0-beta.1", "engines": { "node": ">=14.0.0" }, "dependencies": { - "@azure/core-lro": "^2.5.3", + "@azure/core-lro": "^2.5.4", "@azure/abort-controller": "^1.0.0", "@azure/core-paging": "^1.2.0", "@azure/core-client": "^1.7.0", "@azure/core-auth": "^1.3.0", - "@azure/core-rest-pipeline": "^1.8.0", + "@azure/core-rest-pipeline": "^1.12.0", "tslib": "^2.2.0" }, "keywords": [ @@ -38,18 +38,18 @@ "rollup-plugin-sourcemaps": "^0.6.3", "typescript": "~5.0.0", "uglify-js": "^3.4.9", - "rimraf": "^3.0.0", + "rimraf": "^5.0.0", "dotenv": "^16.0.0", - "@azure/identity": "^3.3.0", + "@azure/identity": "^2.0.1", "@azure-tools/test-recorder": "^3.0.0", "@azure-tools/test-credential": "^1.0.0", - "mocha": "^10.0.0", + "mocha": "^7.1.1", "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", "@types/node": "^14.0.0", - "@azure/dev-tool": "^1.0.0", - "ts-node": "^10.0.0" + "ts-node": "^10.0.0", + "@azure/dev-tool": "^1.0.0" }, "repository": { "type": "git", @@ -84,7 +84,7 @@ "extract-api": "api-extractor run --local", "lint": "echo skipped", "audit": "echo skipped", - "clean": "rimraf dist dist-browser dist-esm test-dist temp types *.tgz *.log", + "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", "build:browser": "echo skipped", "build:test": "echo skipped", @@ -112,13 +112,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/cosmosdb/arm-cosmosdb", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-cosmosdb?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/cosmosdb/arm-cosmosdb" +} \ No newline at end of file diff --git a/sdk/cosmosdb/arm-cosmosdb/src/cosmosDBManagementClient.ts b/sdk/cosmosdb/arm-cosmosdb/src/cosmosDBManagementClient.ts index 58a11e9d6b37..d36e1fd82d08 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/cosmosDBManagementClient.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/cosmosDBManagementClient.ts @@ -28,17 +28,14 @@ import { CollectionPartitionImpl, PartitionKeyRangeIdImpl, PartitionKeyRangeIdRegionImpl, - GraphResourcesImpl, SqlResourcesImpl, MongoDBResourcesImpl, TableResourcesImpl, CassandraResourcesImpl, GremlinResourcesImpl, LocationsImpl, - DataTransferJobsImpl, CassandraClustersImpl, CassandraDataCentersImpl, - MongoClustersImpl, NotebookWorkspacesImpl, PrivateEndpointConnectionsImpl, PrivateLinkResourcesImpl, @@ -70,17 +67,14 @@ import { CollectionPartition, PartitionKeyRangeId, PartitionKeyRangeIdRegion, - GraphResources, SqlResources, MongoDBResources, TableResources, CassandraResources, GremlinResources, Locations, - DataTransferJobs, CassandraClusters, CassandraDataCenters, - MongoClusters, NotebookWorkspaces, PrivateEndpointConnections, PrivateLinkResources, @@ -132,7 +126,7 @@ export class CosmosDBManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-cosmosdb/16.0.0-beta.7`; + const packageDetails = `azsdk-js-arm-cosmosdb/1.0.0-beta.1`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -185,7 +179,7 @@ export class CosmosDBManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2023-03-15-preview"; + this.apiVersion = options.apiVersion || "2023-09-15"; this.databaseAccounts = new DatabaseAccountsImpl(this); this.operations = new OperationsImpl(this); this.database = new DatabaseImpl(this); @@ -199,17 +193,14 @@ export class CosmosDBManagementClient extends coreClient.ServiceClient { this.collectionPartition = new CollectionPartitionImpl(this); this.partitionKeyRangeId = new PartitionKeyRangeIdImpl(this); this.partitionKeyRangeIdRegion = new PartitionKeyRangeIdRegionImpl(this); - this.graphResources = new GraphResourcesImpl(this); this.sqlResources = new SqlResourcesImpl(this); this.mongoDBResources = new MongoDBResourcesImpl(this); this.tableResources = new TableResourcesImpl(this); this.cassandraResources = new CassandraResourcesImpl(this); this.gremlinResources = new GremlinResourcesImpl(this); this.locations = new LocationsImpl(this); - this.dataTransferJobs = new DataTransferJobsImpl(this); this.cassandraClusters = new CassandraClustersImpl(this); this.cassandraDataCenters = new CassandraDataCentersImpl(this); - this.mongoClusters = new MongoClustersImpl(this); this.notebookWorkspaces = new NotebookWorkspacesImpl(this); this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this); this.privateLinkResources = new PrivateLinkResourcesImpl(this); @@ -272,17 +263,14 @@ export class CosmosDBManagementClient extends coreClient.ServiceClient { collectionPartition: CollectionPartition; partitionKeyRangeId: PartitionKeyRangeId; partitionKeyRangeIdRegion: PartitionKeyRangeIdRegion; - graphResources: GraphResources; sqlResources: SqlResources; mongoDBResources: MongoDBResources; tableResources: TableResources; cassandraResources: CassandraResources; gremlinResources: GremlinResources; locations: Locations; - dataTransferJobs: DataTransferJobs; cassandraClusters: CassandraClusters; cassandraDataCenters: CassandraDataCenters; - mongoClusters: MongoClusters; notebookWorkspaces: NotebookWorkspaces; privateEndpointConnections: PrivateEndpointConnections; privateLinkResources: PrivateLinkResources; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/models/index.ts b/sdk/cosmosdb/arm-cosmosdb/src/models/index.ts index 78e6584d15b1..17e74650304b 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/models/index.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/models/index.ts @@ -12,12 +12,6 @@ export type BackupPolicyUnion = | BackupPolicy | PeriodicModeBackupPolicy | ContinuousModeBackupPolicy; -export type DataTransferDataSourceSinkUnion = - | DataTransferDataSourceSink - | CosmosCassandraDataTransferDataSourceSink - | CosmosMongoDataTransferDataSourceSink - | CosmosSqlDataTransferDataSourceSink - | AzureBlobDataTransferDataSourceSink; export type ServiceResourcePropertiesUnion = | ServiceResourceProperties | DataTransferServiceResourceProperties @@ -25,6 +19,39 @@ export type ServiceResourcePropertiesUnion = | GraphAPIComputeServiceResourceProperties | MaterializedViewsBuilderServiceResourceProperties; +/** Identity for the resource. */ +export interface ManagedServiceIdentity { + /** + * The principal id of the system assigned identity. This property will only be provided for a system assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The tenant id of the system assigned identity. This property will only be provided for a system assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly tenantId?: string; + /** The type of identity used for the resource. The type 'SystemAssigned,UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the service. */ + type?: ResourceIdentityType; + /** The list of user identities associated with resource. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */ + userAssignedIdentities?: { + [propertyName: string]: Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties; + }; +} + +export interface Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties { + /** + * The principal id of user assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly principalId?: string; + /** + * The client id of user assigned identity. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly clientId?: string; +} + /** IpAddressOrRange object */ export interface IpAddressOrRange { /** A single IPv4 address or a single IPv4 address range in CIDR format. Provided IPs must be well-formatted and cannot be contained in one of the following ranges: 10.0.0.0/8, 100.64.0.0/10, 172.16.0.0/12, 192.168.0.0/16, since these are not enforceable by the IP address filter. Example of valid inputs: “23.40.210.245” or “23.40.210.0/8”. */ @@ -142,6 +169,22 @@ export interface AnalyticalStorageConfiguration { schemaType?: AnalyticalStorageSchemaType; } +/** Parameters to indicate the information about the restore. */ +export interface RestoreParameters { + /** Describes the mode of the restore. */ + restoreMode?: RestoreMode; + /** The id of the restorable database account from which the restore has to be initiated. For example: /subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName} */ + restoreSource?: string; + /** Time to which the account has to be restored (ISO-8601 format). */ + restoreTimestampInUtc?: Date; + /** List of specific databases available for restore. */ + databasesToRestore?: DatabaseRestoreResource[]; + /** List of specific gremlin databases available for restore. */ + gremlinDatabasesToRestore?: GremlinDatabaseRestoreResource[]; + /** List of specific tables available for restore. */ + tablesToRestore?: string[]; +} + /** Specific Databases to restore. */ export interface DatabaseRestoreResource { /** The name of the database available for restore. */ @@ -158,14 +201,6 @@ export interface GremlinDatabaseRestoreResource { graphNames?: string[]; } -/** Parameters to indicate the information about the restore. */ -export interface RestoreParametersBase { - /** The id of the restorable database account from which the restore has to be initiated. For example: /subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName} */ - restoreSource?: string; - /** Time to which the account has to be restored (ISO-8601 format). */ - restoreTimestampInUtc?: Date; -} - /** The object representing the policy for taking backups on an account. */ export interface BackupPolicy { /** Polymorphic discriminator, which specifies the different types this object can be */ @@ -198,12 +233,6 @@ export interface CorsPolicy { maxAgeInSeconds?: number; } -/** Indicates what diagnostic log settings are to be enabled. */ -export interface DiagnosticLogSettings { - /** Describe the level of detail with which queries are to be logged. */ - enableFullTextQuery?: EnableFullTextQuery; -} - /** The object that represents all properties related to capacity enforcement on an account. */ export interface Capacity { /** The total throughput limit imposed on the account. A totalThroughputLimit of 2000 imposes a strict limit of max throughput that can be provisioned on that account to be 2000. A totalThroughputLimit of -1 indicates no limits on provisioning of throughput. */ @@ -280,41 +309,6 @@ export interface ARMResourceProperties { location?: string; /** Tags are a list of key-value pairs that describe the resource. These tags can be used in viewing and grouping this resource (across resource groups). A maximum of 15 tags can be provided for a resource. Each tag must have a key no greater than 128 characters and value no greater than 256 characters. For example, the default experience for a template type is set with "defaultExperience": "Cassandra". Current "defaultExperience" values also include "Table", "Graph", "DocumentDB", and "MongoDB". */ tags?: { [propertyName: string]: string }; - /** Identity for the resource. */ - identity?: ManagedServiceIdentity; -} - -/** Identity for the resource. */ -export interface ManagedServiceIdentity { - /** - * The principal id of the system assigned identity. This property will only be provided for a system assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The tenant id of the system assigned identity. This property will only be provided for a system assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly tenantId?: string; - /** The type of identity used for the resource. The type 'SystemAssigned,UserAssigned' includes both an implicitly created identity and a set of user assigned identities. The type 'None' will remove any identities from the service. */ - type?: ResourceIdentityType; - /** The list of user identities associated with resource. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */ - userAssignedIdentities?: { - [propertyName: string]: Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties; - }; -} - -export interface Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties { - /** - * The principal id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly principalId?: string; - /** - * The client id of user assigned identity. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly clientId?: string; } /** Parameters for patching Azure Cosmos DB database account properties. */ @@ -369,14 +363,10 @@ export interface DatabaseAccountUpdateParameters { networkAclBypass?: NetworkAclBypass; /** An array that contains the Resource Ids for Network Acl Bypass for the Cosmos DB account. */ networkAclBypassResourceIds?: string[]; - /** The Object representing the different Diagnostic log settings for the Cosmos DB Account. */ - diagnosticLogSettings?: DiagnosticLogSettings; /** Opt-out of local authentication and ensure only MSI and AAD can be used exclusively for authentication. */ disableLocalAuth?: boolean; /** The object that represents all properties related to capacity enforcement on an account. */ capacity?: Capacity; - /** Flag to indicate whether to enable MaterializedViews on the Cosmos DB account */ - enableMaterializedViews?: boolean; /** * This property is ignored during the update operation, as the metadata is read-only. The object represents the metadata for the Account Keys of the Cosmos DB account. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -384,10 +374,12 @@ export interface DatabaseAccountUpdateParameters { readonly keysMetadata?: DatabaseAccountKeysMetadata; /** Flag to indicate enabling/disabling of Partition Merge feature on the account */ enablePartitionMerge?: boolean; + /** Indicates the minimum allowed Tls version. The default value is Tls 1.2. Cassandra and Mongo APIs only work with Tls 1.2. */ + minimalTlsVersion?: MinimalTlsVersion; /** Flag to indicate enabling/disabling of Burst Capacity Preview feature on the account */ enableBurstCapacity?: boolean; - /** Indicates the minimum allowed Tls version. The default is Tls 1.0, except for Cassandra and Mongo API's, which only work with Tls 1.2. */ - minimalTlsVersion?: MinimalTlsVersion; + /** Indicates the status of the Customer Managed Key feature on the account. In case there are errors, the property provides troubleshooting guidance. */ + customerManagedKeyStatus?: CustomerManagedKeyStatus; } /** The list of new failover policies for the failover priority change. */ @@ -739,42 +731,6 @@ export interface MetricAvailability { readonly retention?: string; } -/** The List operation response, that contains the Graph resource and their properties. */ -export interface GraphResourcesListResult { - /** - * List of Graph resource and their properties. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: GraphResourceGetResults[]; -} - -/** Cosmos DB Graph resource object */ -export interface GraphResource { - /** Name of the Cosmos DB Graph */ - id: string; -} - -/** Cosmos DB options resource object */ -export interface OptionsResource { - /** Value of the Cosmos DB resource throughput or autoscaleSettings. Use the ThroughputSetting resource when retrieving offer details. */ - throughput?: number; - /** Specifies the Autoscale settings. */ - autoscaleSettings?: AutoscaleSettings; -} - -export interface AutoscaleSettings { - /** Represents maximum throughput, the resource can scale up to. */ - maxThroughput?: number; -} - -/** CreateUpdateOptions are a list of key-value pairs that describe the resource. Supported keys are "If-Match", "If-None-Match", "Session-Token" and "Throughput" */ -export interface CreateUpdateOptions { - /** Request Units per second. For example, "throughput": 10000. */ - throughput?: number; - /** Specifies the Autoscale settings. */ - autoscaleSettings?: AutoscaleSettings; -} - /** The List operation response, that contains the SQL databases and their properties. */ export interface SqlDatabaseListResult { /** @@ -788,10 +744,6 @@ export interface SqlDatabaseListResult { export interface SqlDatabaseResource { /** Name of the Cosmos DB SQL database */ id: string; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** The system generated resource properties associated with SQL databases, SQL containers, Gremlin databases and Gremlin graphs. */ @@ -813,6 +765,27 @@ export interface ExtendedResourceProperties { readonly etag?: string; } +/** Cosmos DB options resource object */ +export interface OptionsResource { + /** Value of the Cosmos DB resource throughput or autoscaleSettings. Use the ThroughputSetting resource when retrieving offer details. */ + throughput?: number; + /** Specifies the Autoscale settings. */ + autoscaleSettings?: AutoscaleSettings; +} + +export interface AutoscaleSettings { + /** Represents maximum throughput, the resource can scale up to. */ + maxThroughput?: number; +} + +/** CreateUpdateOptions are a list of key-value pairs that describe the resource. Supported keys are "If-Match", "If-None-Match", "Session-Token" and "Throughput" */ +export interface CreateUpdateOptions { + /** Request Units per second. For example, "throughput": 10000. */ + throughput?: number; + /** Specifies the Autoscale settings. Note: Either throughput or autoscaleSettings is required, but not both. */ + autoscaleSettings?: AutoscaleSettings; +} + /** Cosmos DB resource throughput object. Either throughput is required or autoscaleSettings is required, but not both. */ export interface ThroughputSettingsResource { /** Value of the Cosmos DB resource throughput. Either throughput is required or autoscaleSettings is required, but not both. */ @@ -829,6 +802,16 @@ export interface ThroughputSettingsResource { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly offerReplacePending?: string; + /** + * The offer throughput value to instantly scale up without triggering splits + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly instantMaximumThroughput?: string; + /** + * The maximum throughput value or the maximum maxThroughput value (for autoscale) that can be specified + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly softAllowedMaximumThroughput?: string; } /** Cosmos DB provisioned throughput settings object */ @@ -864,64 +847,6 @@ export interface CloudError { error?: ErrorResponse; } -/** The List operation response, that contains the client encryption keys and their properties. */ -export interface ClientEncryptionKeysListResult { - /** - * List of client encryption keys and their properties. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: ClientEncryptionKeyGetResults[]; -} - -/** Cosmos DB client encryption key resource object. */ -export interface ClientEncryptionKeyResource { - /** Name of the ClientEncryptionKey */ - id?: string; - /** Encryption algorithm that will be used along with this client encryption key to encrypt/decrypt data. */ - encryptionAlgorithm?: string; - /** Wrapped (encrypted) form of the key represented as a byte array. */ - wrappedDataEncryptionKey?: Uint8Array; - /** Metadata for the wrapping provider that can be used to unwrap the wrapped client encryption key. */ - keyWrapMetadata?: KeyWrapMetadata; -} - -/** Represents key wrap metadata that a key wrapping provider can use to wrap/unwrap a client encryption key. */ -export interface KeyWrapMetadata { - /** The name of associated KeyEncryptionKey (aka CustomerManagedKey). */ - name?: string; - /** ProviderName of KeyStoreProvider. */ - type?: string; - /** Reference / link to the KeyEncryptionKey. */ - value?: string; - /** Algorithm used in wrapping and unwrapping of the data encryption key. */ - algorithm?: string; -} - -/** The resource model definition for a ARM proxy resource. It will have everything other than required location and tags */ -export interface ARMProxyResource { - /** - * The unique resource identifier of the database account. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; - /** - * The name of the database account. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** - * The type of Azure resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; -} - -/** Parameters to create and update ClientEncryptionKey. */ -export interface ClientEncryptionKeyCreateUpdateParameters { - /** The standard JSON format of a ClientEncryptionKey */ - resource: ClientEncryptionKeyResource; -} - /** The List operation response, that contains the containers and their properties. */ export interface SqlContainerListResult { /** @@ -949,12 +874,6 @@ export interface SqlContainerResource { clientEncryptionPolicy?: ClientEncryptionPolicy; /** Analytical TTL. */ analyticalStorageTtl?: number; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; - /** The configuration for defining Materialized Views. This must be specified only for creating a Materialized View container. */ - materializedViewDefinition?: MaterializedViewDefinition; } /** Cosmos DB indexing policy */ @@ -1067,82 +986,62 @@ export interface ClientEncryptionIncludedPath { encryptionAlgorithm: string; } -/** Materialized View definition for the container. */ -export interface MaterializedViewDefinition { +/** The List operation response, that contains the client encryption keys and their properties. */ +export interface ClientEncryptionKeysListResult { /** - * An unique identifier for the source collection. This is a system generated property. + * List of client encryption keys and their properties. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly sourceCollectionRid?: string; - /** The name of the source container on which the Materialized View will be created. */ - sourceCollectionId: string; - /** The definition should be an SQL query which would be used to fetch data from the source container to populate into the Materialized View container. */ - definition: string; + readonly value?: ClientEncryptionKeyGetResults[]; } -/** The properties of an Azure Cosmos DB merge operations */ -export interface MergeParameters { - /** Specifies whether the operation is a real merge operation or a simulation. */ - isDryRun?: boolean; +/** Cosmos DB client encryption key resource object. */ +export interface ClientEncryptionKeyResource { + /** Name of the ClientEncryptionKey */ + id?: string; + /** Encryption algorithm that will be used along with this client encryption key to encrypt/decrypt data. */ + encryptionAlgorithm?: string; + /** Wrapped (encrypted) form of the key represented as a byte array. */ + wrappedDataEncryptionKey?: Uint8Array; + /** Metadata for the wrapping provider that can be used to unwrap the wrapped client encryption key. */ + keyWrapMetadata?: KeyWrapMetadata; } -/** List of physical partitions and their properties returned by a merge operation. */ -export interface PhysicalPartitionStorageInfoCollection { - /** - * List of physical partitions and their properties. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly physicalPartitionStorageInfoCollection?: PhysicalPartitionStorageInfo[]; +/** Represents key wrap metadata that a key wrapping provider can use to wrap/unwrap a client encryption key. */ +export interface KeyWrapMetadata { + /** The name of associated KeyEncryptionKey (aka CustomerManagedKey). */ + name?: string; + /** ProviderName of KeyStoreProvider. */ + type?: string; + /** Reference / link to the KeyEncryptionKey. */ + value?: string; + /** Algorithm used in wrapping and unwrapping of the data encryption key. */ + algorithm?: string; } -/** The storage of a physical partition */ -export interface PhysicalPartitionStorageInfo { +/** The resource model definition for a ARM proxy resource. It will have everything other than required location and tags */ +export interface ARMProxyResource { /** - * The unique identifier of the partition. + * The unique resource identifier of the database account. * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly id?: string; /** - * The storage in KB for the physical partition. + * The name of the database account. * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly storageInKB?: number; -} - -/** Resource to retrieve throughput information for Cosmos DB resource */ -export interface RetrieveThroughputPropertiesResource { - /** Array of PhysicalPartitionId objects. */ - physicalPartitionIds: PhysicalPartitionId[]; -} - -/** PhysicalPartitionId object */ -export interface PhysicalPartitionId { - /** Id of a physical partition */ - id: string; -} - -/** The properties of an Azure Cosmos DB PhysicalPartitionThroughputInfoProperties object */ -export interface PhysicalPartitionThroughputInfoProperties { - /** Array of physical partition throughput info objects */ - physicalPartitionThroughputInfo?: PhysicalPartitionThroughputInfoResource[]; -} - -/** PhysicalPartitionThroughputInfo object */ -export interface PhysicalPartitionThroughputInfoResource { - /** Id of a physical partition */ - id: string; - /** Throughput of a physical partition */ - throughput?: number; + readonly name?: string; + /** + * The type of Azure resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; } -/** Resource to redistribute throughput for Azure Cosmos DB resource */ -export interface RedistributeThroughputPropertiesResource { - /** ThroughputPolicy to apply for throughput redistribution */ - throughputPolicy: ThroughputPolicyType; - /** Array of PhysicalPartitionThroughputInfoResource objects. */ - targetPhysicalPartitionThroughputInfo: PhysicalPartitionThroughputInfoResource[]; - /** Array of PhysicalPartitionThroughputInfoResource objects. */ - sourcePhysicalPartitionThroughputInfo: PhysicalPartitionThroughputInfoResource[]; +/** Parameters to create and update ClientEncryptionKey. */ +export interface ClientEncryptionKeyCreateUpdateParameters { + /** The standard JSON format of a ClientEncryptionKey */ + resource: ClientEncryptionKeyResource; } /** The List operation response, that contains the storedProcedures and their properties. */ @@ -1213,10 +1112,6 @@ export interface MongoDBDatabaseListResult { export interface MongoDBDatabaseResource { /** Name of the Cosmos DB MongoDB database */ id: string; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** The List operation response, that contains the MongoDB collections and their properties. */ @@ -1238,10 +1133,6 @@ export interface MongoDBCollectionResource { indexes?: MongoIndex[]; /** Analytical TTL. */ analyticalStorageTtl?: number; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** Cosmos DB MongoDB collection index key */ @@ -1279,10 +1170,6 @@ export interface TableListResult { export interface TableResource { /** Name of the Cosmos DB table */ id: string; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** The List operation response, that contains the Cassandra keyspaces and their properties. */ @@ -1366,10 +1253,6 @@ export interface GremlinDatabaseListResult { export interface GremlinDatabaseResource { /** Name of the Cosmos DB Gremlin database */ id: string; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** The List operation response, that contains the graphs and their properties. */ @@ -1397,10 +1280,6 @@ export interface GremlinGraphResource { conflictResolutionPolicy?: ConflictResolutionPolicy; /** Analytical TTL. */ analyticalStorageTtl?: number; - /** Parameters to indicate the information about the restore */ - restoreParameters?: ResourceRestoreParameters; - /** Enum to indicate the mode of resource creation. */ - createMode?: CreateMode; } /** The List operation response, that contains Cosmos DB locations and their properties. */ @@ -1446,87 +1325,6 @@ export interface LocationProperties { readonly status?: Status; } -/** The List operation response, that contains the Cassandra views and their properties. */ -export interface CassandraViewListResult { - /** - * List of Cassandra views and their properties. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: CassandraViewGetResults[]; -} - -/** Cosmos DB Cassandra view resource object */ -export interface CassandraViewResource { - /** Name of the Cosmos DB Cassandra view */ - id: string; - /** View Definition of the Cosmos DB Cassandra view */ - viewDefinition: string; -} - -/** The properties of a DataTransfer Job */ -export interface DataTransferJobProperties { - /** - * Job Name - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly jobName?: string; - /** Source DataStore details */ - source: DataTransferDataSourceSinkUnion; - /** Destination DataStore details */ - destination: DataTransferDataSourceSinkUnion; - /** - * Job Status - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly status?: string; - /** - * Processed Count. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly processedCount?: number; - /** - * Total Count. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly totalCount?: number; - /** - * Last Updated Time (ISO-8601 format). - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly lastUpdatedUtcTime?: Date; - /** Worker count */ - workerCount?: number; - /** - * Error response for Faulted job - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly error?: ErrorResponse; -} - -/** Base class for all DataTransfer source/sink */ -export interface DataTransferDataSourceSink { - /** Polymorphic discriminator, which specifies the different types this object can be */ - component: - | "CosmosDBCassandra" - | "CosmosDBMongo" - | "CosmosDBSql" - | "AzureBlobStorage"; -} - -/** The List operation response, that contains the Data Transfer jobs and their properties. */ -export interface DataTransferJobFeedResults { - /** - * List of Data Transfer jobs and their properties. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: DataTransferJobGetResults[]; - /** - * URL to get the next set of Data Transfer job list results if there are any. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - /** List of managed Cassandra clusters. */ export interface ListClusters { /** Container for the array of clusters. */ @@ -1661,20 +1459,6 @@ export interface CommandOutput { commandOutput?: string; } -/** List of restorable backups for a Cassandra cluster. */ -export interface ListBackups { - /** - * Container for array of backups. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly value?: BackupResource[]; -} - -export interface BackupResourceProperties { - /** The time this backup was taken, formatted like 2021-01-21T17:35:21 */ - timestamp?: Date; -} - /** List of managed Cassandra data centers and their properties. */ export interface ListDataCenters { /** @@ -1785,230 +1569,35 @@ export interface ComponentsM9L909SchemasCassandraclusterpublicstatusPropertiesDa /** The node's IP address. */ address?: string; /** The state of the node in Cassandra ring. */ - state?: NodeState; - status?: string; - /** Cassandra service status on this node */ - cassandraProcessStatus?: string; - /** The amount of file system data in the data directory (e.g., 47.66 kB), excluding all content in the snapshots subdirectories. Because all SSTable data files are included, any data that is not cleaned up (such as TTL-expired cells or tombstones) is counted. */ - load?: string; - /** List of tokens this node covers. */ - tokens?: string[]; - size?: number; - /** The network ID of the node. */ - hostID?: string; - /** The rack this node is part of. */ - rack?: string; - /** The timestamp when these statistics were captured. */ - timestamp?: string; - /** The amount of disk used, in kB, of the directory /var/lib/cassandra. */ - diskUsedKB?: number; - /** The amount of disk free, in kB, of the directory /var/lib/cassandra. */ - diskFreeKB?: number; - /** Used memory (calculated as total - free - buffers - cache), in kB. */ - memoryUsedKB?: number; - /** Memory used by kernel buffers (Buffers in /proc/meminfo) and page cache and slabs (Cached and SReclaimable in /proc/meminfo), in kB. */ - memoryBuffersAndCachedKB?: number; - /** Unused memory (MemFree and SwapFree in /proc/meminfo), in kB. */ - memoryFreeKB?: number; - /** Total installed memory (MemTotal and SwapTotal in /proc/meminfo), in kB. */ - memoryTotalKB?: number; - /** A float representing the current system-wide CPU utilization as a percentage. */ - cpuUsage?: number; -} - -/** A list of mongo clusters. */ -export interface MongoClusterListResult { - /** The list of mongo clusters */ - value?: MongoCluster[]; - /** - * The link used to get the next page of results. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Parameters used for restore operations */ -export interface MongoClusterRestoreParameters { - /** UTC point in time to restore a mongo cluster */ - pointInTimeUTC?: Date; - /** Resource ID to locate the source cluster to restore */ - sourceResourceId?: string; -} - -/** The properties of the node group on a cluster. */ -export interface NodeGroupProperties { - /** The resource sku for the node group. This defines the size of CPU and memory that is provisioned for each node. Example values: 'M30', 'M40'. */ - sku?: string; - /** The disk storage size for the node group in GB. Example values: 128, 256, 512, 1024. */ - diskSizeGB?: number; - /** Whether high availability is enabled on the node group. */ - enableHa?: boolean; -} - -/** Common fields that are returned in the response for all Azure Resource Manager resources */ -export interface ResourceAutoGenerated { - /** - * Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly id?: string; - /** - * The name of the resource - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly name?: string; - /** - * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * Azure Resource Manager metadata containing createdBy and modifiedBy information. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; -} - -/** Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.). */ -export interface ErrorResponseAutoGenerated { - /** The error object. */ - error?: ErrorDetail; -} - -/** The error detail. */ -export interface ErrorDetail { - /** - * The error code. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly code?: string; - /** - * The error message. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly message?: string; - /** - * The error target. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly target?: string; - /** - * The error details. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly details?: ErrorDetail[]; - /** - * The error additional info. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly additionalInfo?: ErrorAdditionalInfo[]; -} - -/** The resource management error additional info. */ -export interface ErrorAdditionalInfo { - /** - * The additional info type. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly type?: string; - /** - * The additional info. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly info?: Record; -} - -/** Represents a mongo cluster resource for updates. */ -export interface MongoClusterUpdate { - /** Application-specific metadata in the form of key-value pairs. */ - tags?: { [propertyName: string]: string }; - /** The mode to create a mongo cluster. */ - createMode?: CreateMode; - /** Parameters used for restore operations */ - restoreParameters?: MongoClusterRestoreParameters; - /** The administrator's login for the mongo cluster. */ - administratorLogin?: string; - /** - * The password of the administrator login. - * This value contains a credential. Consider obscuring before showing to users - */ - administratorLoginPassword?: string; - /** The Mongo DB server version. Defaults to the latest available version if not specified. */ - serverVersion?: string; - /** - * The default mongo connection string for the cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly connectionString?: string; - /** - * Earliest restore timestamp in UTC ISO8601 format. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly earliestRestoreTime?: string; - /** - * A provisioning state of the mongo cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: ProvisioningState; - /** - * A status of the mongo cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly clusterStatus?: MongoClusterStatus; - /** The list of node group specs in the cluster. */ - nodeGroupSpecs?: NodeGroupSpec[]; -} - -/** A list of firewall rules. */ -export interface FirewallRuleListResult { - /** The list of firewall rules in a mongo cluster. */ - value?: FirewallRule[]; - /** - * The link used to get the next page of results. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** The check availability request body. */ -export interface CheckNameAvailabilityRequest { - /** The name of the resource for which availability needs to be checked. */ - name?: string; - /** The resource type. */ - type?: string; -} - -/** The check availability result. */ -export interface CheckNameAvailabilityResponse { - /** Indicates if the resource name is available. */ - nameAvailable?: boolean; - /** The reason why the given name is not available. */ - reason?: CheckNameAvailabilityReason; - /** Detailed reason why the given name is available. */ - message?: string; -} - -/** The connection strings for the given mongo cluster. */ -export interface ListConnectionStringsResult { - /** - * An array that contains the connection strings for a mongo cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly connectionStrings?: ConnectionString[]; -} - -/** Connection string for the mongo cluster */ -export interface ConnectionString { - /** - * Value of the connection string - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly connectionString?: string; - /** - * Description of the connection string - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly description?: string; + state?: NodeState; + status?: string; + /** Cassandra service status on this node */ + cassandraProcessStatus?: string; + /** The amount of file system data in the data directory (e.g., 47.66 kB), excluding all content in the snapshots subdirectories. Because all SSTable data files are included, any data that is not cleaned up (such as TTL-expired cells or tombstones) is counted. */ + load?: string; + /** List of tokens this node covers. */ + tokens?: string[]; + size?: number; + /** The network ID of the node. */ + hostID?: string; + /** The rack this node is part of. */ + rack?: string; + /** The timestamp when these statistics were captured. */ + timestamp?: string; + /** The amount of disk used, in kB, of the directory /var/lib/cassandra. */ + diskUsedKB?: number; + /** The amount of disk free, in kB, of the directory /var/lib/cassandra. */ + diskFreeKB?: number; + /** Used memory (calculated as total - free - buffers - cache), in kB. */ + memoryUsedKB?: number; + /** Memory used by kernel buffers (Buffers in /proc/meminfo) and page cache and slabs (Cached and SReclaimable in /proc/meminfo), in kB. */ + memoryBuffersAndCachedKB?: number; + /** Unused memory (MemFree and SwapFree in /proc/meminfo), in kB. */ + memoryFreeKB?: number; + /** Total installed memory (MemTotal and SwapTotal in /proc/meminfo), in kB. */ + memoryTotalKB?: number; + /** A float representing the current system-wide CPU utilization as a percentage. */ + cpuUsage?: number; } /** The set of data plane operations permitted through this Role Definition. */ @@ -2195,10 +1784,10 @@ export interface RestorableDatabaseAccountGetResult { accountName?: string; /** The creation time of the restorable database account (ISO-8601 format). */ creationTime?: Date; - /** The least recent time at which the database account can be restored to (ISO-8601 format). */ - oldestRestorableTime?: Date; /** The time at which the restorable database account has been deleted (ISO-8601 format). */ deletionTime?: Date; + /** The least recent time at which the database account can be restored to (ISO-8601 format). */ + oldestRestorableTime?: Date; /** * The API type of the restorable database account. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -2854,7 +2443,7 @@ export interface PeriodicModeProperties { /** Configuration values for periodic mode backup */ export interface ContinuousModeProperties { - /** Enum to indicate type of Continuos backup mode */ + /** Enum to indicate type of Continuous backup mode */ tier?: ContinuousTier; } @@ -2904,23 +2493,6 @@ export interface MaterializedViewsBuilderServiceResource { /** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ export interface ProxyResource extends Resource {} -/** Parameters to indicate the information about the restore. */ -export interface RestoreParameters extends RestoreParametersBase { - /** Describes the mode of the restore. */ - restoreMode?: RestoreMode; - /** List of specific databases available for restore. */ - databasesToRestore?: DatabaseRestoreResource[]; - /** List of specific gremlin databases available for restore. */ - gremlinDatabasesToRestore?: GremlinDatabaseRestoreResource[]; - /** List of specific tables available for restore. */ - tablesToRestore?: string[]; - /** The source backup location for restore. */ - sourceBackupLocation?: string; -} - -/** Parameters to indicate the information about the restore. */ -export interface ResourceRestoreParameters extends RestoreParametersBase {} - /** The object representing periodic mode backup policy. */ export interface PeriodicModeBackupPolicy extends BackupPolicy { /** Polymorphic discriminator, which specifies the different types this object can be */ @@ -2941,6 +2513,8 @@ export interface ContinuousModeBackupPolicy extends BackupPolicy { export interface DatabaseAccountGetResults extends ARMResourceProperties { /** Indicates the type of database account. This can only be set at database account creation. */ kind?: DatabaseAccountKind; + /** Identity for the resource. */ + identity?: ManagedServiceIdentity; /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -3037,14 +2611,10 @@ export interface DatabaseAccountGetResults extends ARMResourceProperties { networkAclBypass?: NetworkAclBypass; /** An array that contains the Resource Ids for Network Acl Bypass for the Cosmos DB account. */ networkAclBypassResourceIds?: string[]; - /** The Object representing the different Diagnostic log settings for the Cosmos DB Account. */ - diagnosticLogSettings?: DiagnosticLogSettings; /** Opt-out of local authentication and ensure only MSI and AAD can be used exclusively for authentication. */ disableLocalAuth?: boolean; /** The object that represents all properties related to capacity enforcement on an account. */ capacity?: Capacity; - /** Flag to indicate whether to enable MaterializedViews on the Cosmos DB account */ - enableMaterializedViews?: boolean; /** * The object that represents the metadata for the Account Keys of the Cosmos DB account. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -3052,10 +2622,12 @@ export interface DatabaseAccountGetResults extends ARMResourceProperties { readonly keysMetadata?: DatabaseAccountKeysMetadata; /** Flag to indicate enabling/disabling of Partition Merge feature on the account */ enablePartitionMerge?: boolean; + /** Indicates the minimum allowed Tls version. The default value is Tls 1.2. Cassandra and Mongo APIs only work with Tls 1.2. */ + minimalTlsVersion?: MinimalTlsVersion; /** Flag to indicate enabling/disabling of Burst Capacity Preview feature on the account */ enableBurstCapacity?: boolean; - /** Indicates the minimum allowed Tls version. The default is Tls 1.0, except for Cassandra and Mongo API's, which only work with Tls 1.2. */ - minimalTlsVersion?: MinimalTlsVersion; + /** Indicates the status of the Customer Managed Key feature on the account. In case there are errors, the property provides troubleshooting guidance. */ + customerManagedKeyStatus?: CustomerManagedKeyStatus; } /** Parameters to create and update Cosmos DB database accounts. */ @@ -3063,6 +2635,8 @@ export interface DatabaseAccountCreateUpdateParameters extends ARMResourceProperties { /** Indicates the type of database account. This can only be set at database account creation. */ kind?: DatabaseAccountKind; + /** Identity for the resource. */ + identity?: ManagedServiceIdentity; /** The consistency policy for the Cosmos DB account. */ consistencyPolicy?: ConsistencyPolicy; /** An array that contains the georeplication locations enabled for the Cosmos DB account. */ @@ -3111,16 +2685,12 @@ export interface DatabaseAccountCreateUpdateParameters networkAclBypass?: NetworkAclBypass; /** An array that contains the Resource Ids for Network Acl Bypass for the Cosmos DB account. */ networkAclBypassResourceIds?: string[]; - /** The Object representing the different Diagnostic log settings for the Cosmos DB Account. */ - diagnosticLogSettings?: DiagnosticLogSettings; /** Opt-out of local authentication and ensure only MSI and AAD can be used exclusively for authentication. */ disableLocalAuth?: boolean; /** Parameters to indicate the information about the restore. */ restoreParameters?: RestoreParameters; /** The object that represents all properties related to capacity enforcement on an account. */ capacity?: Capacity; - /** Flag to indicate whether to enable MaterializedViews on the Cosmos DB account */ - enableMaterializedViews?: boolean; /** * This property is ignored during the update/create operation, as the metadata is read-only. The object represents the metadata for the Account Keys of the Cosmos DB account. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -3128,25 +2698,12 @@ export interface DatabaseAccountCreateUpdateParameters readonly keysMetadata?: DatabaseAccountKeysMetadata; /** Flag to indicate enabling/disabling of Partition Merge feature on the account */ enablePartitionMerge?: boolean; + /** Indicates the minimum allowed Tls version. The default value is Tls 1.2. Cassandra and Mongo APIs only work with Tls 1.2. */ + minimalTlsVersion?: MinimalTlsVersion; /** Flag to indicate enabling/disabling of Burst Capacity Preview feature on the account */ enableBurstCapacity?: boolean; - /** Indicates the minimum allowed Tls version. The default is Tls 1.0, except for Cassandra and Mongo API's, which only work with Tls 1.2. */ - minimalTlsVersion?: MinimalTlsVersion; -} - -/** An Azure Cosmos DB Graph resource. */ -export interface GraphResourceGetResults extends ARMResourceProperties { - resource?: GraphResourceGetPropertiesResource; - options?: GraphResourceGetPropertiesOptions; -} - -/** Parameters to create and update Cosmos DB Graph resource. */ -export interface GraphResourceCreateUpdateParameters - extends ARMResourceProperties { - /** The standard JSON format of a Graph resource */ - resource: GraphResource; - /** A key-value pair of options to be applied for the request. This corresponds to the headers sent with the request. */ - options?: CreateUpdateOptions; + /** Indicates the status of the Customer Managed Key feature on the account. In case there are errors, the property provides troubleshooting guidance. */ + customerManagedKeyStatus?: CustomerManagedKeyStatus; } /** An Azure Cosmos DB SQL database. */ @@ -3191,26 +2748,6 @@ export interface SqlContainerCreateUpdateParameters options?: CreateUpdateOptions; } -/** Cosmos DB retrieve throughput parameters object */ -export interface RetrieveThroughputParameters extends ARMResourceProperties { - /** The standard JSON format of a resource throughput */ - resource: RetrieveThroughputPropertiesResource; -} - -/** An Azure Cosmos DB PhysicalPartitionThroughputInfoResult object. */ -export interface PhysicalPartitionThroughputInfoResult - extends ARMResourceProperties { - /** properties of physical partition throughput info */ - resource?: PhysicalPartitionThroughputInfoResultPropertiesResource; -} - -/** Cosmos DB redistribute throughput parameters object */ -export interface RedistributeThroughputParameters - extends ARMResourceProperties { - /** The standard JSON format of a resource throughput */ - resource: RedistributeThroughputPropertiesResource; -} - /** An Azure Cosmos DB storedProcedure. */ export interface SqlStoredProcedureGetResults extends ARMResourceProperties { resource?: SqlStoredProcedureGetPropertiesResource; @@ -3358,21 +2895,6 @@ export interface GremlinGraphCreateUpdateParameters options?: CreateUpdateOptions; } -/** An Azure Cosmos DB Cassandra view. */ -export interface CassandraViewGetResults extends ARMResourceProperties { - resource?: CassandraViewGetPropertiesResource; - options?: CassandraViewGetPropertiesOptions; -} - -/** Parameters to create and update Cosmos DB Cassandra view. */ -export interface CassandraViewCreateUpdateParameters - extends ARMResourceProperties { - /** The standard JSON format of a Cassandra view */ - resource: CassandraViewResource; - /** A key-value pair of options to be applied for the request. This corresponds to the headers sent with the request. */ - options?: CreateUpdateOptions; -} - /** The access keys for the given database account. */ export interface DatabaseAccountListKeysResult extends DatabaseAccountListReadOnlyKeysResult { @@ -3455,32 +2977,6 @@ export interface PartitionUsage extends Usage { readonly partitionKeyRangeId?: string; } -export interface GraphResourceGetPropertiesResource extends GraphResource {} - -export interface GraphResourceGetPropertiesOptions extends OptionsResource {} - -export interface SqlDatabaseGetPropertiesOptions extends OptionsResource {} - -export interface SqlContainerGetPropertiesOptions extends OptionsResource {} - -export interface MongoDBDatabaseGetPropertiesOptions extends OptionsResource {} - -export interface MongoDBCollectionGetPropertiesOptions - extends OptionsResource {} - -export interface TableGetPropertiesOptions extends OptionsResource {} - -export interface CassandraKeyspaceGetPropertiesOptions - extends OptionsResource {} - -export interface CassandraTableGetPropertiesOptions extends OptionsResource {} - -export interface GremlinDatabaseGetPropertiesOptions extends OptionsResource {} - -export interface GremlinGraphGetPropertiesOptions extends OptionsResource {} - -export interface CassandraViewGetPropertiesOptions extends OptionsResource {} - export interface SqlDatabaseGetPropertiesResource extends SqlDatabaseResource, ExtendedResourceProperties { @@ -3515,14 +3011,14 @@ export interface ThroughputSettingsGetPropertiesResource extends ThroughputSettingsResource, ExtendedResourceProperties {} -export interface ClientEncryptionKeyGetPropertiesResource - extends ClientEncryptionKeyResource, - ExtendedResourceProperties {} - export interface SqlContainerGetPropertiesResource extends SqlContainerResource, ExtendedResourceProperties {} +export interface ClientEncryptionKeyGetPropertiesResource + extends ClientEncryptionKeyResource, + ExtendedResourceProperties {} + export interface SqlStoredProcedureGetPropertiesResource extends SqlStoredProcedureResource, ExtendedResourceProperties {} @@ -3563,10 +3059,6 @@ export interface GremlinGraphGetPropertiesResource extends GremlinGraphResource, ExtendedResourceProperties {} -export interface CassandraViewGetPropertiesResource - extends CassandraViewResource, - ExtendedResourceProperties {} - /** Cosmos DB SQL container resource object */ export interface RestorableSqlContainerPropertiesResourceContainer extends SqlContainerResource, @@ -3578,6 +3070,26 @@ export interface RestorableSqlContainerPropertiesResourceContainer readonly self?: string; } +export interface SqlDatabaseGetPropertiesOptions extends OptionsResource {} + +export interface SqlContainerGetPropertiesOptions extends OptionsResource {} + +export interface MongoDBDatabaseGetPropertiesOptions extends OptionsResource {} + +export interface MongoDBCollectionGetPropertiesOptions + extends OptionsResource {} + +export interface TableGetPropertiesOptions extends OptionsResource {} + +export interface CassandraKeyspaceGetPropertiesOptions + extends OptionsResource {} + +export interface CassandraTableGetPropertiesOptions extends OptionsResource {} + +export interface GremlinDatabaseGetPropertiesOptions extends OptionsResource {} + +export interface GremlinGraphGetPropertiesOptions extends OptionsResource {} + /** Client Encryption Key. */ export interface ClientEncryptionKeyGetResults extends ARMProxyResource { resource?: ClientEncryptionKeyGetPropertiesResource; @@ -3589,57 +3101,6 @@ export interface LocationGetResult extends ARMProxyResource { properties?: LocationProperties; } -/** Parameters to create Data Transfer Job */ -export interface CreateJobRequest extends ARMProxyResource { - /** Data Transfer Create Job Properties */ - properties: DataTransferJobProperties; -} - -/** A Cosmos DB Data Transfer Job */ -export interface DataTransferJobGetResults extends ARMProxyResource { - /** - * Job Name - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly jobName?: string; - /** Source DataStore details */ - source?: DataTransferDataSourceSinkUnion; - /** Destination DataStore details */ - destination?: DataTransferDataSourceSinkUnion; - /** - * Job Status - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly status?: string; - /** - * Processed Count. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly processedCount?: number; - /** - * Total Count. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly totalCount?: number; - /** - * Last Updated Time (ISO-8601 format). - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly lastUpdatedUtcTime?: Date; - /** Worker count */ - workerCount?: number; - /** - * Error response for Faulted job - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly error?: ErrorResponse; -} - -/** A restorable backup of a Cassandra cluster. */ -export interface BackupResource extends ARMProxyResource { - properties?: BackupResourceProperties; -} - /** A managed Cassandra data center. */ export interface DataCenterResource extends ARMProxyResource { /** Properties of a managed Cassandra data center. */ @@ -3741,71 +3202,12 @@ export interface ServiceResource extends ARMProxyResource { properties?: ServiceResourcePropertiesUnion; } -/** properties of physical partition throughput info */ -export interface PhysicalPartitionThroughputInfoResultPropertiesResource - extends PhysicalPartitionThroughputInfoProperties {} - -/** A CosmosDB Cassandra API data source/sink */ -export interface CosmosCassandraDataTransferDataSourceSink - extends DataTransferDataSourceSink { - /** Polymorphic discriminator, which specifies the different types this object can be */ - component: "CosmosDBCassandra"; - keyspaceName: string; - tableName: string; -} - -/** A CosmosDB Cassandra API data source/sink */ -export interface CosmosMongoDataTransferDataSourceSink - extends DataTransferDataSourceSink { - /** Polymorphic discriminator, which specifies the different types this object can be */ - component: "CosmosDBMongo"; - databaseName: string; - collectionName: string; -} - -/** A CosmosDB Cassandra API data source/sink */ -export interface CosmosSqlDataTransferDataSourceSink - extends DataTransferDataSourceSink { - /** Polymorphic discriminator, which specifies the different types this object can be */ - component: "CosmosDBSql"; - databaseName: string; - containerName: string; -} - -/** An Azure Blob Storage data source/sink */ -export interface AzureBlobDataTransferDataSourceSink - extends DataTransferDataSourceSink { - /** Polymorphic discriminator, which specifies the different types this object can be */ - component: "AzureBlobStorage"; - containerName: string; - endpointUrl?: string; -} - /** Representation of a managed Cassandra cluster. */ export interface ClusterResource extends ManagedCassandraARMResourceProperties { /** Properties of a managed Cassandra cluster. */ properties?: ClusterResourceProperties; } -/** Specification for a node group. */ -export interface NodeGroupSpec extends NodeGroupProperties { - /** The node type deployed in the node group. */ - kind?: NodeKind; - /** The number of nodes in the node group. */ - nodeCount?: number; -} - -/** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */ -export interface TrackedResource extends ResourceAutoGenerated { - /** Resource tags. */ - tags?: { [propertyName: string]: string }; - /** The geo-location where the resource lives */ - location: string; -} - -/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ -export interface ProxyResourceAutoGenerated extends ResourceAutoGenerated {} - /** Properties for DataTransferServiceResource. */ export interface DataTransferServiceResourceProperties extends ServiceResourceProperties { @@ -3898,58 +3300,6 @@ export interface PrivateEndpointConnection extends ProxyResource { provisioningState?: string; } -/** Represents a mongo cluster resource. */ -export interface MongoCluster extends TrackedResource { - /** The mode to create a mongo cluster. */ - createMode?: CreateMode; - /** Parameters used for restore operations */ - restoreParameters?: MongoClusterRestoreParameters; - /** The administrator's login for the mongo cluster. */ - administratorLogin?: string; - /** - * The password of the administrator login. - * This value contains a credential. Consider obscuring before showing to users - */ - administratorLoginPassword?: string; - /** The Mongo DB server version. Defaults to the latest available version if not specified. */ - serverVersion?: string; - /** - * The default mongo connection string for the cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly connectionString?: string; - /** - * Earliest restore timestamp in UTC ISO8601 format. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly earliestRestoreTime?: string; - /** - * A provisioning state of the mongo cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: ProvisioningState; - /** - * A status of the mongo cluster. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly clusterStatus?: MongoClusterStatus; - /** The list of node group specs in the cluster. */ - nodeGroupSpecs?: NodeGroupSpec[]; -} - -/** Represents a mongo cluster firewall rule. */ -export interface FirewallRule extends ProxyResourceAutoGenerated { - /** - * The provisioning state of the firewall rule. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly provisioningState?: ProvisioningState; - /** The start IP address of the mongo cluster firewall rule. Must be IPv4 format. */ - startIpAddress: string; - /** The end IP address of the mongo cluster firewall rule. Must be IPv4 format. */ - endIpAddress: string; -} - /** Defines headers for DatabaseAccounts_delete operation. */ export interface DatabaseAccountsDeleteHeaders { /** URI to poll for completion status. */ @@ -3990,22 +3340,6 @@ export interface DatabaseAccountsRegenerateKeyHeaders { location?: string; } -/** Defines headers for GraphResources_createUpdateGraph operation. */ -export interface GraphResourcesCreateUpdateGraphHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for GraphResources_deleteGraphResource operation. */ -export interface GraphResourcesDeleteGraphResourceHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - /** Defines headers for SqlResources_createUpdateSqlDatabase operation. */ export interface SqlResourcesCreateUpdateSqlDatabaseHeaders { /** URI to poll for completion status. */ @@ -4046,14 +3380,6 @@ export interface SqlResourcesMigrateSqlDatabaseToManualThroughputHeaders { location?: string; } -/** Defines headers for SqlResources_createUpdateClientEncryptionKey operation. */ -export interface SqlResourcesCreateUpdateClientEncryptionKeyHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - /** Defines headers for SqlResources_createUpdateSqlContainer operation. */ export interface SqlResourcesCreateUpdateSqlContainerHeaders { /** URI to poll for completion status. */ @@ -4062,80 +3388,40 @@ export interface SqlResourcesCreateUpdateSqlContainerHeaders { location?: string; } -/** Defines headers for SqlResources_deleteSqlContainer operation. */ -export interface SqlResourcesDeleteSqlContainerHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for SqlResources_sqlDatabasePartitionMerge operation. */ -export interface SqlResourcesSqlDatabasePartitionMergeHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for SqlResources_listSqlContainerPartitionMerge operation. */ -export interface SqlResourcesListSqlContainerPartitionMergeHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for SqlResources_updateSqlContainerThroughput operation. */ -export interface SqlResourcesUpdateSqlContainerThroughputHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for SqlResources_migrateSqlContainerToAutoscale operation. */ -export interface SqlResourcesMigrateSqlContainerToAutoscaleHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for SqlResources_migrateSqlContainerToManualThroughput operation. */ -export interface SqlResourcesMigrateSqlContainerToManualThroughputHeaders { +/** Defines headers for SqlResources_deleteSqlContainer operation. */ +export interface SqlResourcesDeleteSqlContainerHeaders { /** URI to poll for completion status. */ azureAsyncOperation?: string; /** URI to poll for completion status. */ location?: string; } -/** Defines headers for SqlResources_sqlDatabaseRetrieveThroughputDistribution operation. */ -export interface SqlResourcesSqlDatabaseRetrieveThroughputDistributionHeaders { +/** Defines headers for SqlResources_updateSqlContainerThroughput operation. */ +export interface SqlResourcesUpdateSqlContainerThroughputHeaders { /** URI to poll for completion status. */ azureAsyncOperation?: string; /** URI to poll for completion status. */ location?: string; } -/** Defines headers for SqlResources_sqlDatabaseRedistributeThroughput operation. */ -export interface SqlResourcesSqlDatabaseRedistributeThroughputHeaders { +/** Defines headers for SqlResources_migrateSqlContainerToAutoscale operation. */ +export interface SqlResourcesMigrateSqlContainerToAutoscaleHeaders { /** URI to poll for completion status. */ azureAsyncOperation?: string; /** URI to poll for completion status. */ location?: string; } -/** Defines headers for SqlResources_sqlContainerRetrieveThroughputDistribution operation. */ -export interface SqlResourcesSqlContainerRetrieveThroughputDistributionHeaders { +/** Defines headers for SqlResources_migrateSqlContainerToManualThroughput operation. */ +export interface SqlResourcesMigrateSqlContainerToManualThroughputHeaders { /** URI to poll for completion status. */ azureAsyncOperation?: string; /** URI to poll for completion status. */ location?: string; } -/** Defines headers for SqlResources_sqlContainerRedistributeThroughput operation. */ -export interface SqlResourcesSqlContainerRedistributeThroughputHeaders { +/** Defines headers for SqlResources_createUpdateClientEncryptionKey operation. */ +export interface SqlResourcesCreateUpdateClientEncryptionKeyHeaders { /** URI to poll for completion status. */ azureAsyncOperation?: string; /** URI to poll for completion status. */ @@ -4230,38 +3516,6 @@ export interface MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders location?: string; } -/** Defines headers for MongoDBResources_mongoDBDatabaseRetrieveThroughputDistribution operation. */ -export interface MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for MongoDBResources_mongoDBDatabaseRedistributeThroughput operation. */ -export interface MongoDBResourcesMongoDBDatabaseRedistributeThroughputHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for MongoDBResources_mongoDBContainerRetrieveThroughputDistribution operation. */ -export interface MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for MongoDBResources_mongoDBContainerRedistributeThroughput operation. */ -export interface MongoDBResourcesMongoDBContainerRedistributeThroughputHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - /** Defines headers for MongoDBResources_createUpdateMongoDBCollection operation. */ export interface MongoDBResourcesCreateUpdateMongoDBCollectionHeaders { /** URI to poll for completion status. */ @@ -4278,22 +3532,6 @@ export interface MongoDBResourcesDeleteMongoDBCollectionHeaders { location?: string; } -/** Defines headers for MongoDBResources_mongoDBDatabasePartitionMerge operation. */ -export interface MongoDBResourcesMongoDBDatabasePartitionMergeHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for MongoDBResources_listMongoDBCollectionPartitionMerge operation. */ -export interface MongoDBResourcesListMongoDBCollectionPartitionMergeHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - /** Defines headers for MongoDBResources_updateMongoDBCollectionThroughput operation. */ export interface MongoDBResourcesUpdateMongoDBCollectionThroughputHeaders { /** URI to poll for completion status. */ @@ -4438,46 +3676,6 @@ export interface CassandraResourcesMigrateCassandraTableToManualThroughputHeader location?: string; } -/** Defines headers for CassandraResources_createUpdateCassandraView operation. */ -export interface CassandraResourcesCreateUpdateCassandraViewHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for CassandraResources_deleteCassandraView operation. */ -export interface CassandraResourcesDeleteCassandraViewHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for CassandraResources_updateCassandraViewThroughput operation. */ -export interface CassandraResourcesUpdateCassandraViewThroughputHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for CassandraResources_migrateCassandraViewToAutoscale operation. */ -export interface CassandraResourcesMigrateCassandraViewToAutoscaleHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - -/** Defines headers for CassandraResources_migrateCassandraViewToManualThroughput operation. */ -export interface CassandraResourcesMigrateCassandraViewToManualThroughputHeaders { - /** URI to poll for completion status. */ - azureAsyncOperation?: string; - /** URI to poll for completion status. */ - location?: string; -} - /** Defines headers for GremlinResources_createUpdateGremlinDatabase operation. */ export interface GremlinResourcesCreateUpdateGremlinDatabaseHeaders { /** URI to poll for completion status. */ @@ -4558,18 +3756,11 @@ export interface GremlinResourcesMigrateGremlinGraphToManualThroughputHeaders { location?: string; } -/** Defines headers for MongoClusters_delete operation. */ -export interface MongoClustersDeleteHeaders { - location?: string; -} - -/** Defines headers for MongoClusters_update operation. */ -export interface MongoClustersUpdateHeaders { - location?: string; -} - -/** Defines headers for MongoClusters_deleteFirewallRule operation. */ -export interface MongoClustersDeleteFirewallRuleHeaders { +/** Defines headers for Service_create operation. */ +export interface ServiceCreateHeaders { + /** URI to poll for completion status. */ + azureAsyncOperation?: string; + /** URI to poll for completion status. */ location?: string; } @@ -4622,7 +3813,9 @@ export enum KnownPublicNetworkAccess { /** Enabled */ Enabled = "Enabled", /** Disabled */ - Disabled = "Disabled" + Disabled = "Disabled", + /** SecuredByPerimeter */ + SecuredByPerimeter = "SecuredByPerimeter" } /** @@ -4631,7 +3824,8 @@ export enum KnownPublicNetworkAccess { * this enum contains the known values that the service supports. * ### Known values supported by the service * **Enabled** \ - * **Disabled** + * **Disabled** \ + * **SecuredByPerimeter** */ export type PublicNetworkAccess = string; @@ -4682,9 +3876,7 @@ export enum KnownCreateMode { /** Default */ Default = "Default", /** Restore */ - Restore = "Restore", - /** PointInTimeRestore */ - PointInTimeRestore = "PointInTimeRestore" + Restore = "Restore" } /** @@ -4693,8 +3885,7 @@ export enum KnownCreateMode { * this enum contains the known values that the service supports. * ### Known values supported by the service * **Default** \ - * **Restore** \ - * **PointInTimeRestore** + * **Restore** */ export type CreateMode = string; @@ -4776,6 +3967,51 @@ export enum KnownMinimalTlsVersion { */ export type MinimalTlsVersion = string; +/** Known values of {@link CustomerManagedKeyStatus} that the service accepts. */ +export enum KnownCustomerManagedKeyStatus { + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBServiceIsUnableToObtainTheAADAuthenticationTokenForTheAccountSDefaultIdentityForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureActiveDirectoryTokenAcquisitionError4000 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBServiceIsUnableToObtainTheAADAuthenticationTokenForTheAccountSDefaultIdentityForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureActiveDirectoryTokenAcquisitionError4000 = "Access to your account is currently revoked because the Azure Cosmos DB service is unable to obtain the AAD authentication token for the account's default identity; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#azure-active-directory-token-acquisition-error (4000).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBAccountSKeyVaultKeyURIDoesNotFollowTheExpectedFormatForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideImproperSyntaxDetectedOnTheKeyVaultUriProperty4006 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBAccountSKeyVaultKeyURIDoesNotFollowTheExpectedFormatForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideImproperSyntaxDetectedOnTheKeyVaultUriProperty4006 = "Access to your account is currently revoked because the Azure Cosmos DB account's key vault key URI does not follow the expected format; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#improper-syntax-detected-on-the-key-vault-uri-property (4006).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheCurrentDefaultIdentityNoLongerHasPermissionToTheAssociatedKeyVaultKeyForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideDefaultIdentityIsUnauthorizedToAccessTheAzureKeyVaultKey4002 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheCurrentDefaultIdentityNoLongerHasPermissionToTheAssociatedKeyVaultKeyForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideDefaultIdentityIsUnauthorizedToAccessTheAzureKeyVaultKey4002 = "Access to your account is currently revoked because the current default identity no longer has permission to the associated Key Vault key; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#default-identity-is-unauthorized-to-access-the-azure-key-vault-key (4002).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureKeyVaultDNSNameSpecifiedByTheAccountSKeyvaultkeyuriPropertyCouldNotBeResolvedForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideUnableToResolveTheKeyVaultsDns4009 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureKeyVaultDNSNameSpecifiedByTheAccountSKeyvaultkeyuriPropertyCouldNotBeResolvedForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideUnableToResolveTheKeyVaultsDns4009 = "Access to your account is currently revoked because the Azure Key Vault DNS name specified by the account's keyvaultkeyuri property could not be resolved; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#unable-to-resolve-the-key-vaults-dns (4009).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheCorrespondentKeyIsNotFoundOnTheSpecifiedKeyVaultForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureKeyVaultResourceNotFound4003 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheCorrespondentKeyIsNotFoundOnTheSpecifiedKeyVaultForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureKeyVaultResourceNotFound4003 = "Access to your account is currently revoked because the correspondent key is not found on the specified Key Vault; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#azure-key-vault-resource-not-found (4003).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBServiceIsUnableToWrapOrUnwrapTheKeyForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideInternalUnwrappingProcedureError4005 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBServiceIsUnableToWrapOrUnwrapTheKeyForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideInternalUnwrappingProcedureError4005 = "Access to your account is currently revoked because the Azure Cosmos DB service is unable to wrap or unwrap the key; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#internal-unwrapping-procedure-error (4005).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBAccountHasAnUndefinedDefaultIdentityForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideInvalidAzureCosmosDbDefaultIdentity4015 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAzureCosmosDBAccountHasAnUndefinedDefaultIdentityForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideInvalidAzureCosmosDbDefaultIdentity4015 = "Access to your account is currently revoked because the Azure Cosmos DB account has an undefined default identity; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#invalid-azure-cosmos-db-default-identity (4015).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheAccessRulesAreBlockingOutboundRequestsToTheAzureKeyVaultServiceForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuide4016 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheAccessRulesAreBlockingOutboundRequestsToTheAzureKeyVaultServiceForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuide4016 = "Access to your account is currently revoked because the access rules are blocking outbound requests to the Azure Key Vault service; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide (4016).", + /** AccessToYourAccountIsCurrentlyRevokedBecauseTheCorrespondentAzureKeyVaultWasNotFoundForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureKeyVaultResourceNotFound4017 */ + AccessToYourAccountIsCurrentlyRevokedBecauseTheCorrespondentAzureKeyVaultWasNotFoundForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuideAzureKeyVaultResourceNotFound4017 = "Access to your account is currently revoked because the correspondent Azure Key Vault was not found; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide#azure-key-vault-resource-not-found (4017).", + /** AccessToYourAccountIsCurrentlyRevokedForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuide */ + AccessToYourAccountIsCurrentlyRevokedForMoreDetailsAboutThisErrorAndHowToRestoreAccessToYourAccountPleaseVisitHttpsLearnMicrosoftComEnUsAzureCosmosDbCmkTroubleshootingGuide = "Access to your account is currently revoked; for more details about this error and how to restore access to your account please visit https://learn.microsoft.com/en-us/azure/cosmos-db/cmk-troubleshooting-guide", + /** AccessToTheConfiguredCustomerManagedKeyConfirmed */ + AccessToTheConfiguredCustomerManagedKeyConfirmed = "Access to the configured customer managed key confirmed." +} + +/** + * Defines values for CustomerManagedKeyStatus. \ + * {@link KnownCustomerManagedKeyStatus} can be used interchangeably with CustomerManagedKeyStatus, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Access to your account is currently revoked because the Azure Cosmos DB service is unable to obtain the AAD authentication token for the account's default identity; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#azure-active-directory-token-acquisition-error (4000).** \ + * **Access to your account is currently revoked because the Azure Cosmos DB account's key vault key URI does not follow the expected format; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#improper-syntax-detected-on-the-key-vault-uri-property (4006).** \ + * **Access to your account is currently revoked because the current default identity no longer has permission to the associated Key Vault key; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#default-identity-is-unauthorized-to-access-the-azure-key-vault-key (4002).** \ + * **Access to your account is currently revoked because the Azure Key Vault DNS name specified by the account's keyvaultkeyuri property could not be resolved; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#unable-to-resolve-the-key-vaults-dns (4009).** \ + * **Access to your account is currently revoked because the correspondent key is not found on the specified Key Vault; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#azure-key-vault-resource-not-found (4003).** \ + * **Access to your account is currently revoked because the Azure Cosmos DB service is unable to wrap or unwrap the key; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#internal-unwrapping-procedure-error (4005).** \ + * **Access to your account is currently revoked because the Azure Cosmos DB account has an undefined default identity; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#invalid-azure-cosmos-db-default-identity (4015).** \ + * **Access to your account is currently revoked because the access rules are blocking outbound requests to the Azure Key Vault service; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide (4016).** \ + * **Access to your account is currently revoked because the correspondent Azure Key Vault was not found; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide#azure-key-vault-resource-not-found (4017).** \ + * **Access to your account is currently revoked; for more details about this error and how to restore access to your account please visit https:\//learn.microsoft.com\/en-us\/azure\/cosmos-db\/cmk-troubleshooting-guide** \ + * **Access to the configured customer managed key confirmed.** + */ +export type CustomerManagedKeyStatus = string; + /** Known values of {@link CreatedByType} that the service accepts. */ export enum KnownCreatedByType { /** User */ @@ -5103,27 +4339,6 @@ export enum KnownConflictResolutionMode { */ export type ConflictResolutionMode = string; -/** Known values of {@link ThroughputPolicyType} that the service accepts. */ -export enum KnownThroughputPolicyType { - /** None */ - None = "none", - /** Equal */ - Equal = "equal", - /** Custom */ - Custom = "custom" -} - -/** - * Defines values for ThroughputPolicyType. \ - * {@link KnownThroughputPolicyType} can be used interchangeably with ThroughputPolicyType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **none** \ - * **equal** \ - * **custom** - */ -export type ThroughputPolicyType = string; - /** Known values of {@link TriggerType} that the service accepts. */ export enum KnownTriggerType { /** Pre */ @@ -5217,30 +4432,6 @@ export enum KnownStatus { */ export type Status = string; -/** Known values of {@link DataTransferComponent} that the service accepts. */ -export enum KnownDataTransferComponent { - /** CosmosDBCassandra */ - CosmosDBCassandra = "CosmosDBCassandra", - /** CosmosDBMongo */ - CosmosDBMongo = "CosmosDBMongo", - /** CosmosDBSql */ - CosmosDBSql = "CosmosDBSql", - /** AzureBlobStorage */ - AzureBlobStorage = "AzureBlobStorage" -} - -/** - * Defines values for DataTransferComponent. \ - * {@link KnownDataTransferComponent} can be used interchangeably with DataTransferComponent, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **CosmosDBCassandra** \ - * **CosmosDBMongo** \ - * **CosmosDBSql** \ - * **AzureBlobStorage** - */ -export type DataTransferComponent = string; - /** Known values of {@link ManagedCassandraProvisioningState} that the service accepts. */ export enum KnownManagedCassandraProvisioningState { /** Creating */ @@ -5367,102 +4558,6 @@ export enum KnownNodeState { */ export type NodeState = string; -/** Known values of {@link ProvisioningState} that the service accepts. */ -export enum KnownProvisioningState { - /** Succeeded */ - Succeeded = "Succeeded", - /** Failed */ - Failed = "Failed", - /** Canceled */ - Canceled = "Canceled", - /** InProgress */ - InProgress = "InProgress", - /** Updating */ - Updating = "Updating", - /** Dropping */ - Dropping = "Dropping" -} - -/** - * Defines values for ProvisioningState. \ - * {@link KnownProvisioningState} can be used interchangeably with ProvisioningState, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Succeeded** \ - * **Failed** \ - * **Canceled** \ - * **InProgress** \ - * **Updating** \ - * **Dropping** - */ -export type ProvisioningState = string; - -/** Known values of {@link MongoClusterStatus} that the service accepts. */ -export enum KnownMongoClusterStatus { - /** Ready */ - Ready = "Ready", - /** Provisioning */ - Provisioning = "Provisioning", - /** Updating */ - Updating = "Updating", - /** Starting */ - Starting = "Starting", - /** Stopping */ - Stopping = "Stopping", - /** Stopped */ - Stopped = "Stopped", - /** Dropping */ - Dropping = "Dropping" -} - -/** - * Defines values for MongoClusterStatus. \ - * {@link KnownMongoClusterStatus} can be used interchangeably with MongoClusterStatus, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Ready** \ - * **Provisioning** \ - * **Updating** \ - * **Starting** \ - * **Stopping** \ - * **Stopped** \ - * **Dropping** - */ -export type MongoClusterStatus = string; - -/** Known values of {@link NodeKind} that the service accepts. */ -export enum KnownNodeKind { - /** Shard */ - Shard = "Shard" -} - -/** - * Defines values for NodeKind. \ - * {@link KnownNodeKind} can be used interchangeably with NodeKind, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Shard** - */ -export type NodeKind = string; - -/** Known values of {@link CheckNameAvailabilityReason} that the service accepts. */ -export enum KnownCheckNameAvailabilityReason { - /** Invalid */ - Invalid = "Invalid", - /** AlreadyExists */ - AlreadyExists = "AlreadyExists" -} - -/** - * Defines values for CheckNameAvailabilityReason. \ - * {@link KnownCheckNameAvailabilityReason} can be used interchangeably with CheckNameAvailabilityReason, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **Invalid** \ - * **AlreadyExists** - */ -export type CheckNameAvailabilityReason = string; - /** Known values of {@link NotebookWorkspaceName} that the service accepts. */ export enum KnownNotebookWorkspaceName { /** Default */ @@ -5516,8 +4611,6 @@ export enum KnownOperationType { Replace = "Replace", /** Delete */ Delete = "Delete", - /** Recreate */ - Recreate = "Recreate", /** SystemOperation */ SystemOperation = "SystemOperation" } @@ -5530,7 +4623,6 @@ export enum KnownOperationType { * **Create** \ * **Replace** \ * **Delete** \ - * **Recreate** \ * **SystemOperation** */ export type OperationType = string; @@ -5645,6 +4737,12 @@ export enum KnownNodeStatus { * **Down** */ export type NodeStatus = string; +/** Defines values for ResourceIdentityType. */ +export type ResourceIdentityType = + | "SystemAssigned" + | "UserAssigned" + | "SystemAssigned,UserAssigned" + | "None"; /** Defines values for DefaultConsistencyLevel. */ export type DefaultConsistencyLevel = | "Eventual" @@ -5654,14 +4752,6 @@ export type DefaultConsistencyLevel = | "ConsistentPrefix"; /** Defines values for NetworkAclBypass. */ export type NetworkAclBypass = "None" | "AzureServices"; -/** Defines values for EnableFullTextQuery. */ -export type EnableFullTextQuery = "None" | "True" | "False"; -/** Defines values for ResourceIdentityType. */ -export type ResourceIdentityType = - | "SystemAssigned" - | "UserAssigned" - | "SystemAssigned,UserAssigned" - | "None"; /** Defines values for MongoRoleDefinitionType. */ export type MongoRoleDefinitionType = "BuiltInRole" | "CustomRole"; /** Defines values for RoleDefinitionType. */ @@ -5959,41 +5049,6 @@ export interface PartitionKeyRangeIdRegionListMetricsOptionalParams /** Contains response data for the listMetrics operation. */ export type PartitionKeyRangeIdRegionListMetricsResponse = PartitionMetricListResult; -/** Optional parameters. */ -export interface GraphResourcesListGraphsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listGraphs operation. */ -export type GraphResourcesListGraphsResponse = GraphResourcesListResult; - -/** Optional parameters. */ -export interface GraphResourcesGetGraphOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getGraph operation. */ -export type GraphResourcesGetGraphResponse = GraphResourceGetResults; - -/** Optional parameters. */ -export interface GraphResourcesCreateUpdateGraphOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createUpdateGraph operation. */ -export type GraphResourcesCreateUpdateGraphResponse = GraphResourceGetResults; - -/** Optional parameters. */ -export interface GraphResourcesDeleteGraphResourceOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - /** Optional parameters. */ export interface SqlResourcesListSqlDatabasesOptionalParams extends coreClient.OperationOptions {} @@ -6075,32 +5130,6 @@ export interface SqlResourcesMigrateSqlDatabaseToManualThroughputOptionalParams /** Contains response data for the migrateSqlDatabaseToManualThroughput operation. */ export type SqlResourcesMigrateSqlDatabaseToManualThroughputResponse = ThroughputSettingsGetResults; -/** Optional parameters. */ -export interface SqlResourcesListClientEncryptionKeysOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listClientEncryptionKeys operation. */ -export type SqlResourcesListClientEncryptionKeysResponse = ClientEncryptionKeysListResult; - -/** Optional parameters. */ -export interface SqlResourcesGetClientEncryptionKeyOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getClientEncryptionKey operation. */ -export type SqlResourcesGetClientEncryptionKeyResponse = ClientEncryptionKeyGetResults; - -/** Optional parameters. */ -export interface SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createUpdateClientEncryptionKey operation. */ -export type SqlResourcesCreateUpdateClientEncryptionKeyResponse = ClientEncryptionKeyGetResults; - /** Optional parameters. */ export interface SqlResourcesListSqlContainersOptionalParams extends coreClient.OperationOptions {} @@ -6139,30 +5168,6 @@ export interface SqlResourcesDeleteSqlContainerOptionalParams /** Contains response data for the deleteSqlContainer operation. */ export type SqlResourcesDeleteSqlContainerResponse = SqlResourcesDeleteSqlContainerHeaders; -/** Optional parameters. */ -export interface SqlResourcesSqlDatabasePartitionMergeOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the sqlDatabasePartitionMerge operation. */ -export type SqlResourcesSqlDatabasePartitionMergeResponse = PhysicalPartitionStorageInfoCollection; - -/** Optional parameters. */ -export interface SqlResourcesListSqlContainerPartitionMergeOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the listSqlContainerPartitionMerge operation. */ -export type SqlResourcesListSqlContainerPartitionMergeResponse = PhysicalPartitionStorageInfoCollection; - /** Optional parameters. */ export interface SqlResourcesGetSqlContainerThroughputOptionalParams extends coreClient.OperationOptions {} @@ -6207,43 +5212,21 @@ export interface SqlResourcesMigrateSqlContainerToManualThroughputOptionalParams export type SqlResourcesMigrateSqlContainerToManualThroughputResponse = ThroughputSettingsGetResults; /** Optional parameters. */ -export interface SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the sqlDatabaseRetrieveThroughputDistribution operation. */ -export type SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse = PhysicalPartitionThroughputInfoResult; - -/** Optional parameters. */ -export interface SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} +export interface SqlResourcesListClientEncryptionKeysOptionalParams + extends coreClient.OperationOptions {} -/** Contains response data for the sqlDatabaseRedistributeThroughput operation. */ -export type SqlResourcesSqlDatabaseRedistributeThroughputResponse = PhysicalPartitionThroughputInfoResult; +/** Contains response data for the listClientEncryptionKeys operation. */ +export type SqlResourcesListClientEncryptionKeysResponse = ClientEncryptionKeysListResult; /** Optional parameters. */ -export interface SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} +export interface SqlResourcesGetClientEncryptionKeyOptionalParams + extends coreClient.OperationOptions {} -/** Contains response data for the sqlContainerRetrieveThroughputDistribution operation. */ -export type SqlResourcesSqlContainerRetrieveThroughputDistributionResponse = PhysicalPartitionThroughputInfoResult; +/** Contains response data for the getClientEncryptionKey operation. */ +export type SqlResourcesGetClientEncryptionKeyResponse = ClientEncryptionKeyGetResults; /** Optional parameters. */ -export interface SqlResourcesSqlContainerRedistributeThroughputOptionalParams +export interface SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams extends coreClient.OperationOptions { /** Delay to wait until next poll, in milliseconds. */ updateIntervalInMs?: number; @@ -6251,8 +5234,8 @@ export interface SqlResourcesSqlContainerRedistributeThroughputOptionalParams resumeFrom?: string; } -/** Contains response data for the sqlContainerRedistributeThroughput operation. */ -export type SqlResourcesSqlContainerRedistributeThroughputResponse = PhysicalPartitionThroughputInfoResult; +/** Contains response data for the createUpdateClientEncryptionKey operation. */ +export type SqlResourcesCreateUpdateClientEncryptionKeyResponse = ClientEncryptionKeyGetResults; /** Optional parameters. */ export interface SqlResourcesListSqlStoredProceduresOptionalParams @@ -6531,54 +5514,6 @@ export interface MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputOptiona /** Contains response data for the migrateMongoDBDatabaseToManualThroughput operation. */ export type MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputResponse = ThroughputSettingsGetResults; -/** Optional parameters. */ -export interface MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the mongoDBDatabaseRetrieveThroughputDistribution operation. */ -export type MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse = PhysicalPartitionThroughputInfoResult; - -/** Optional parameters. */ -export interface MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the mongoDBDatabaseRedistributeThroughput operation. */ -export type MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse = PhysicalPartitionThroughputInfoResult; - -/** Optional parameters. */ -export interface MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the mongoDBContainerRetrieveThroughputDistribution operation. */ -export type MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse = PhysicalPartitionThroughputInfoResult; - -/** Optional parameters. */ -export interface MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the mongoDBContainerRedistributeThroughput operation. */ -export type MongoDBResourcesMongoDBContainerRedistributeThroughputResponse = PhysicalPartitionThroughputInfoResult; - /** Optional parameters. */ export interface MongoDBResourcesListMongoDBCollectionsOptionalParams extends coreClient.OperationOptions {} @@ -6617,30 +5552,6 @@ export interface MongoDBResourcesDeleteMongoDBCollectionOptionalParams /** Contains response data for the deleteMongoDBCollection operation. */ export type MongoDBResourcesDeleteMongoDBCollectionResponse = MongoDBResourcesDeleteMongoDBCollectionHeaders; -/** Optional parameters. */ -export interface MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the mongoDBDatabasePartitionMerge operation. */ -export type MongoDBResourcesMongoDBDatabasePartitionMergeResponse = PhysicalPartitionStorageInfoCollection; - -/** Optional parameters. */ -export interface MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the listMongoDBCollectionPartitionMerge operation. */ -export type MongoDBResourcesListMongoDBCollectionPartitionMergeResponse = PhysicalPartitionStorageInfoCollection; - /** Optional parameters. */ export interface MongoDBResourcesGetMongoDBCollectionThroughputOptionalParams extends coreClient.OperationOptions {} @@ -7021,84 +5932,6 @@ export interface CassandraResourcesMigrateCassandraTableToManualThroughputOption /** Contains response data for the migrateCassandraTableToManualThroughput operation. */ export type CassandraResourcesMigrateCassandraTableToManualThroughputResponse = ThroughputSettingsGetResults; -/** Optional parameters. */ -export interface CassandraResourcesListCassandraViewsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listCassandraViews operation. */ -export type CassandraResourcesListCassandraViewsResponse = CassandraViewListResult; - -/** Optional parameters. */ -export interface CassandraResourcesGetCassandraViewOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getCassandraView operation. */ -export type CassandraResourcesGetCassandraViewResponse = CassandraViewGetResults; - -/** Optional parameters. */ -export interface CassandraResourcesCreateUpdateCassandraViewOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createUpdateCassandraView operation. */ -export type CassandraResourcesCreateUpdateCassandraViewResponse = CassandraViewGetResults; - -/** Optional parameters. */ -export interface CassandraResourcesDeleteCassandraViewOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Optional parameters. */ -export interface CassandraResourcesGetCassandraViewThroughputOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getCassandraViewThroughput operation. */ -export type CassandraResourcesGetCassandraViewThroughputResponse = ThroughputSettingsGetResults; - -/** Optional parameters. */ -export interface CassandraResourcesUpdateCassandraViewThroughputOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the updateCassandraViewThroughput operation. */ -export type CassandraResourcesUpdateCassandraViewThroughputResponse = ThroughputSettingsGetResults; - -/** Optional parameters. */ -export interface CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the migrateCassandraViewToAutoscale operation. */ -export type CassandraResourcesMigrateCassandraViewToAutoscaleResponse = ThroughputSettingsGetResults; - -/** Optional parameters. */ -export interface CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the migrateCassandraViewToManualThroughput operation. */ -export type CassandraResourcesMigrateCassandraViewToManualThroughputResponse = ThroughputSettingsGetResults; - /** Optional parameters. */ export interface GremlinResourcesListGremlinDatabasesOptionalParams extends coreClient.OperationOptions {} @@ -7287,55 +6120,6 @@ export interface LocationsGetOptionalParams /** Contains response data for the get operation. */ export type LocationsGetResponse = LocationGetResult; -/** Optional parameters. */ -export interface DataTransferJobsCreateOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the create operation. */ -export type DataTransferJobsCreateResponse = DataTransferJobGetResults; - -/** Optional parameters. */ -export interface DataTransferJobsGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type DataTransferJobsGetResponse = DataTransferJobGetResults; - -/** Optional parameters. */ -export interface DataTransferJobsPauseOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the pause operation. */ -export type DataTransferJobsPauseResponse = DataTransferJobGetResults; - -/** Optional parameters. */ -export interface DataTransferJobsResumeOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the resume operation. */ -export type DataTransferJobsResumeResponse = DataTransferJobGetResults; - -/** Optional parameters. */ -export interface DataTransferJobsCancelOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the cancel operation. */ -export type DataTransferJobsCancelResponse = DataTransferJobGetResults; - -/** Optional parameters. */ -export interface DataTransferJobsListByDatabaseAccountOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByDatabaseAccount operation. */ -export type DataTransferJobsListByDatabaseAccountResponse = DataTransferJobFeedResults; - -/** Optional parameters. */ -export interface DataTransferJobsListByDatabaseAccountNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByDatabaseAccountNext operation. */ -export type DataTransferJobsListByDatabaseAccountNextResponse = DataTransferJobFeedResults; - /** Optional parameters. */ export interface CassandraClustersListBySubscriptionOptionalParams extends coreClient.OperationOptions {} @@ -7402,20 +6186,6 @@ export interface CassandraClustersInvokeCommandOptionalParams /** Contains response data for the invokeCommand operation. */ export type CassandraClustersInvokeCommandResponse = CommandOutput; -/** Optional parameters. */ -export interface CassandraClustersListBackupsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listBackups operation. */ -export type CassandraClustersListBackupsResponse = ListBackups; - -/** Optional parameters. */ -export interface CassandraClustersGetBackupOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getBackup operation. */ -export type CassandraClustersGetBackupResponse = BackupResource; - /** Optional parameters. */ export interface CassandraClustersDeallocateOptionalParams extends coreClient.OperationOptions { @@ -7488,136 +6258,6 @@ export interface CassandraDataCentersUpdateOptionalParams /** Contains response data for the update operation. */ export type CassandraDataCentersUpdateResponse = DataCenterResource; -/** Optional parameters. */ -export interface MongoClustersListOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the list operation. */ -export type MongoClustersListResponse = MongoClusterListResult; - -/** Optional parameters. */ -export interface MongoClustersListByResourceGroupOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroup operation. */ -export type MongoClustersListByResourceGroupResponse = MongoClusterListResult; - -/** Optional parameters. */ -export interface MongoClustersCreateOrUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdate operation. */ -export type MongoClustersCreateOrUpdateResponse = MongoCluster; - -/** Optional parameters. */ -export interface MongoClustersGetOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the get operation. */ -export type MongoClustersGetResponse = MongoCluster; - -/** Optional parameters. */ -export interface MongoClustersDeleteOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the delete operation. */ -export type MongoClustersDeleteResponse = MongoClustersDeleteHeaders; - -/** Optional parameters. */ -export interface MongoClustersUpdateOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the update operation. */ -export type MongoClustersUpdateResponse = MongoCluster; - -/** Optional parameters. */ -export interface MongoClustersCreateOrUpdateFirewallRuleOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the createOrUpdateFirewallRule operation. */ -export type MongoClustersCreateOrUpdateFirewallRuleResponse = FirewallRule; - -/** Optional parameters. */ -export interface MongoClustersDeleteFirewallRuleOptionalParams - extends coreClient.OperationOptions { - /** Delay to wait until next poll, in milliseconds. */ - updateIntervalInMs?: number; - /** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */ - resumeFrom?: string; -} - -/** Contains response data for the deleteFirewallRule operation. */ -export type MongoClustersDeleteFirewallRuleResponse = MongoClustersDeleteFirewallRuleHeaders; - -/** Optional parameters. */ -export interface MongoClustersGetFirewallRuleOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the getFirewallRule operation. */ -export type MongoClustersGetFirewallRuleResponse = FirewallRule; - -/** Optional parameters. */ -export interface MongoClustersListFirewallRulesOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listFirewallRules operation. */ -export type MongoClustersListFirewallRulesResponse = FirewallRuleListResult; - -/** Optional parameters. */ -export interface MongoClustersCheckNameAvailabilityOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the checkNameAvailability operation. */ -export type MongoClustersCheckNameAvailabilityResponse = CheckNameAvailabilityResponse; - -/** Optional parameters. */ -export interface MongoClustersListConnectionStringsOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listConnectionStrings operation. */ -export type MongoClustersListConnectionStringsResponse = ListConnectionStringsResult; - -/** Optional parameters. */ -export interface MongoClustersListNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listNext operation. */ -export type MongoClustersListNextResponse = MongoClusterListResult; - -/** Optional parameters. */ -export interface MongoClustersListByResourceGroupNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listByResourceGroupNext operation. */ -export type MongoClustersListByResourceGroupNextResponse = MongoClusterListResult; - -/** Optional parameters. */ -export interface MongoClustersListFirewallRulesNextOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the listFirewallRulesNext operation. */ -export type MongoClustersListFirewallRulesNextResponse = FirewallRuleListResult; - /** Optional parameters. */ export interface NotebookWorkspacesListByDatabaseAccountOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/cosmosdb/arm-cosmosdb/src/models/mappers.ts b/sdk/cosmosdb/arm-cosmosdb/src/models/mappers.ts index cbe5a40cd9b2..2b104cd2d71e 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/models/mappers.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/models/mappers.ts @@ -8,6 +8,78 @@ import * as coreClient from "@azure/core-client"; +export const ManagedServiceIdentity: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ManagedServiceIdentity", + modelProperties: { + principalId: { + serializedName: "principalId", + readOnly: true, + type: { + name: "String" + } + }, + tenantId: { + serializedName: "tenantId", + readOnly: true, + type: { + name: "String" + } + }, + type: { + serializedName: "type", + type: { + name: "Enum", + allowedValues: [ + "SystemAssigned", + "UserAssigned", + "SystemAssigned,UserAssigned", + "None" + ] + } + }, + userAssignedIdentities: { + serializedName: "userAssignedIdentities", + type: { + name: "Dictionary", + value: { + type: { + name: "Composite", + className: + "Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties" + } + } + } + } + } + } +}; + +export const Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: + "Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties", + modelProperties: { + principalId: { + serializedName: "principalId", + readOnly: true, + type: { + name: "String" + } + }, + clientId: { + serializedName: "clientId", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + export const IpAddressOrRange: coreClient.CompositeMapper = { type: { name: "Composite", @@ -287,19 +359,55 @@ export const AnalyticalStorageConfiguration: coreClient.CompositeMapper = { } }; -export const DatabaseRestoreResource: coreClient.CompositeMapper = { +export const RestoreParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DatabaseRestoreResource", + className: "RestoreParameters", modelProperties: { - databaseName: { - serializedName: "databaseName", + restoreMode: { + serializedName: "restoreMode", type: { name: "String" } }, - collectionNames: { - serializedName: "collectionNames", + restoreSource: { + serializedName: "restoreSource", + type: { + name: "String" + } + }, + restoreTimestampInUtc: { + serializedName: "restoreTimestampInUtc", + type: { + name: "DateTime" + } + }, + databasesToRestore: { + serializedName: "databasesToRestore", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DatabaseRestoreResource" + } + } + } + }, + gremlinDatabasesToRestore: { + serializedName: "gremlinDatabasesToRestore", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "GremlinDatabaseRestoreResource" + } + } + } + }, + tablesToRestore: { + serializedName: "tablesToRestore", type: { name: "Sequence", element: { @@ -313,10 +421,10 @@ export const DatabaseRestoreResource: coreClient.CompositeMapper = { } }; -export const GremlinDatabaseRestoreResource: coreClient.CompositeMapper = { +export const DatabaseRestoreResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GremlinDatabaseRestoreResource", + className: "DatabaseRestoreResource", modelProperties: { databaseName: { serializedName: "databaseName", @@ -324,8 +432,8 @@ export const GremlinDatabaseRestoreResource: coreClient.CompositeMapper = { name: "String" } }, - graphNames: { - serializedName: "graphNames", + collectionNames: { + serializedName: "collectionNames", type: { name: "Sequence", element: { @@ -339,21 +447,26 @@ export const GremlinDatabaseRestoreResource: coreClient.CompositeMapper = { } }; -export const RestoreParametersBase: coreClient.CompositeMapper = { +export const GremlinDatabaseRestoreResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestoreParametersBase", + className: "GremlinDatabaseRestoreResource", modelProperties: { - restoreSource: { - serializedName: "restoreSource", + databaseName: { + serializedName: "databaseName", type: { name: "String" } }, - restoreTimestampInUtc: { - serializedName: "restoreTimestampInUtc", + graphNames: { + serializedName: "graphNames", type: { - name: "DateTime" + name: "Sequence", + element: { + type: { + name: "String" + } + } } } } @@ -459,22 +572,6 @@ export const CorsPolicy: coreClient.CompositeMapper = { } }; -export const DiagnosticLogSettings: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DiagnosticLogSettings", - modelProperties: { - enableFullTextQuery: { - serializedName: "enableFullTextQuery", - type: { - name: "Enum", - allowedValues: ["None", "True", "False"] - } - } - } - } -}; - export const Capacity: coreClient.CompositeMapper = { type: { name: "Composite", @@ -629,85 +726,6 @@ export const ARMResourceProperties: coreClient.CompositeMapper = { name: "Dictionary", value: { type: { name: "String" } } } - }, - identity: { - serializedName: "identity", - type: { - name: "Composite", - className: "ManagedServiceIdentity" - } - } - } - } -}; - -export const ManagedServiceIdentity: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ManagedServiceIdentity", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, - type: { - name: "String" - } - }, - tenantId: { - serializedName: "tenantId", - readOnly: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - type: { - name: "Enum", - allowedValues: [ - "SystemAssigned", - "UserAssigned", - "SystemAssigned,UserAssigned", - "None" - ] - } - }, - userAssignedIdentities: { - serializedName: "userAssignedIdentities", - type: { - name: "Dictionary", - value: { - type: { - name: "Composite", - className: - "Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties" - } - } - } - } - } - } -}; - -export const Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: - "Components1Jq1T4ISchemasManagedserviceidentityPropertiesUserassignedidentitiesAdditionalproperties", - modelProperties: { - principalId: { - serializedName: "principalId", - readOnly: true, - type: { - name: "String" - } - }, - clientId: { - serializedName: "clientId", - readOnly: true, - type: { - name: "String" - } } } } @@ -910,13 +928,6 @@ export const DatabaseAccountUpdateParameters: coreClient.CompositeMapper = { } } }, - diagnosticLogSettings: { - serializedName: "properties.diagnosticLogSettings", - type: { - name: "Composite", - className: "DiagnosticLogSettings" - } - }, disableLocalAuth: { serializedName: "properties.disableLocalAuth", type: { @@ -930,12 +941,6 @@ export const DatabaseAccountUpdateParameters: coreClient.CompositeMapper = { className: "Capacity" } }, - enableMaterializedViews: { - serializedName: "properties.enableMaterializedViews", - type: { - name: "Boolean" - } - }, keysMetadata: { serializedName: "properties.keysMetadata", type: { @@ -949,14 +954,20 @@ export const DatabaseAccountUpdateParameters: coreClient.CompositeMapper = { name: "Boolean" } }, + minimalTlsVersion: { + serializedName: "properties.minimalTlsVersion", + type: { + name: "String" + } + }, enableBurstCapacity: { serializedName: "properties.enableBurstCapacity", type: { name: "Boolean" } }, - minimalTlsVersion: { - serializedName: "properties.minimalTlsVersion", + customerManagedKeyStatus: { + serializedName: "properties.customerManagedKeyStatus", type: { name: "String" } @@ -1662,10 +1673,10 @@ export const MetricAvailability: coreClient.CompositeMapper = { } }; -export const GraphResourcesListResult: coreClient.CompositeMapper = { +export const SqlDatabaseListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GraphResourcesListResult", + className: "SqlDatabaseListResult", modelProperties: { value: { serializedName: "value", @@ -1675,7 +1686,7 @@ export const GraphResourcesListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "GraphResourceGetResults" + className: "SqlDatabaseGetResults" } } } @@ -1684,10 +1695,10 @@ export const GraphResourcesListResult: coreClient.CompositeMapper = { } }; -export const GraphResource: coreClient.CompositeMapper = { +export const SqlDatabaseResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GraphResource", + className: "SqlDatabaseResource", modelProperties: { id: { serializedName: "id", @@ -1700,47 +1711,40 @@ export const GraphResource: coreClient.CompositeMapper = { } }; -export const OptionsResource: coreClient.CompositeMapper = { +export const ExtendedResourceProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "OptionsResource", + className: "ExtendedResourceProperties", modelProperties: { - throughput: { - serializedName: "throughput", + rid: { + serializedName: "_rid", + readOnly: true, type: { - name: "Number" + name: "String" } }, - autoscaleSettings: { - serializedName: "autoscaleSettings", + ts: { + serializedName: "_ts", + readOnly: true, type: { - name: "Composite", - className: "AutoscaleSettings" + name: "Number" } - } - } - } -}; - -export const AutoscaleSettings: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AutoscaleSettings", - modelProperties: { - maxThroughput: { - serializedName: "maxThroughput", + }, + etag: { + serializedName: "_etag", + readOnly: true, type: { - name: "Number" + name: "String" } } } } }; -export const CreateUpdateOptions: coreClient.CompositeMapper = { +export const OptionsResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CreateUpdateOptions", + className: "OptionsResource", modelProperties: { throughput: { serializedName: "throughput", @@ -1759,81 +1763,37 @@ export const CreateUpdateOptions: coreClient.CompositeMapper = { } }; -export const SqlDatabaseListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlDatabaseListResult", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SqlDatabaseGetResults" - } - } - } - } - } - } -}; - -export const SqlDatabaseResource: coreClient.CompositeMapper = { +export const AutoscaleSettings: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlDatabaseResource", + className: "AutoscaleSettings", modelProperties: { - id: { - serializedName: "id", - required: true, - type: { - name: "String" - } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", + maxThroughput: { + serializedName: "maxThroughput", type: { - name: "String" + name: "Number" } } } } }; -export const ExtendedResourceProperties: coreClient.CompositeMapper = { +export const CreateUpdateOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ExtendedResourceProperties", + className: "CreateUpdateOptions", modelProperties: { - rid: { - serializedName: "_rid", - readOnly: true, - type: { - name: "String" - } - }, - ts: { - serializedName: "_ts", - readOnly: true, + throughput: { + serializedName: "throughput", type: { name: "Number" } }, - etag: { - serializedName: "_etag", - readOnly: true, + autoscaleSettings: { + serializedName: "autoscaleSettings", type: { - name: "String" + name: "Composite", + className: "AutoscaleSettings" } } } @@ -1871,6 +1831,20 @@ export const ThroughputSettingsResource: coreClient.CompositeMapper = { type: { name: "String" } + }, + instantMaximumThroughput: { + serializedName: "instantMaximumThroughput", + readOnly: true, + type: { + name: "String" + } + }, + softAllowedMaximumThroughput: { + serializedName: "softAllowedMaximumThroughput", + readOnly: true, + type: { + name: "String" + } } } } @@ -1959,141 +1933,6 @@ export const CloudError: coreClient.CompositeMapper = { } }; -export const ClientEncryptionKeysListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClientEncryptionKeysListResult", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ClientEncryptionKeyGetResults" - } - } - } - } - } - } -}; - -export const ClientEncryptionKeyResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClientEncryptionKeyResource", - modelProperties: { - id: { - serializedName: "id", - type: { - name: "String" - } - }, - encryptionAlgorithm: { - serializedName: "encryptionAlgorithm", - type: { - name: "String" - } - }, - wrappedDataEncryptionKey: { - serializedName: "wrappedDataEncryptionKey", - type: { - name: "ByteArray" - } - }, - keyWrapMetadata: { - serializedName: "keyWrapMetadata", - type: { - name: "Composite", - className: "KeyWrapMetadata" - } - } - } - } -}; - -export const KeyWrapMetadata: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "KeyWrapMetadata", - modelProperties: { - name: { - serializedName: "name", - type: { - name: "String" - } - }, - type: { - serializedName: "type", - type: { - name: "String" - } - }, - value: { - serializedName: "value", - type: { - name: "String" - } - }, - algorithm: { - serializedName: "algorithm", - type: { - name: "String" - } - } - } - } -}; - -export const ARMProxyResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ARMProxyResource", - modelProperties: { - id: { - serializedName: "id", - readOnly: true, - type: { - name: "String" - } - }, - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const ClientEncryptionKeyCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClientEncryptionKeyCreateUpdateParameters", - modelProperties: { - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "ClientEncryptionKeyResource" - } - } - } - } -}; - export const SqlContainerListResult: coreClient.CompositeMapper = { type: { name: "Composite", @@ -2174,26 +2013,6 @@ export const SqlContainerResource: coreClient.CompositeMapper = { type: { name: "Number" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } - }, - materializedViewDefinition: { - serializedName: "materializedViewDefinition", - type: { - name: "Composite", - className: "MaterializedViewDefinition" - } } } } @@ -2575,65 +2394,20 @@ export const ClientEncryptionIncludedPath: coreClient.CompositeMapper = { } }; -export const MaterializedViewDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MaterializedViewDefinition", - modelProperties: { - sourceCollectionRid: { - serializedName: "sourceCollectionRid", - readOnly: true, - type: { - name: "String" - } - }, - sourceCollectionId: { - serializedName: "sourceCollectionId", - required: true, - type: { - name: "String" - } - }, - definition: { - serializedName: "definition", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const MergeParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MergeParameters", - modelProperties: { - isDryRun: { - serializedName: "isDryRun", - type: { - name: "Boolean" - } - } - } - } -}; - -export const PhysicalPartitionStorageInfoCollection: coreClient.CompositeMapper = { +export const ClientEncryptionKeysListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PhysicalPartitionStorageInfoCollection", + className: "ClientEncryptionKeysListResult", modelProperties: { - physicalPartitionStorageInfoCollection: { - serializedName: "physicalPartitionStorageInfoCollection", + value: { + serializedName: "value", readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "PhysicalPartitionStorageInfo" + className: "ClientEncryptionKeyGetResults" } } } @@ -2642,146 +2416,113 @@ export const PhysicalPartitionStorageInfoCollection: coreClient.CompositeMapper } }; -export const PhysicalPartitionStorageInfo: coreClient.CompositeMapper = { +export const ClientEncryptionKeyResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PhysicalPartitionStorageInfo", + className: "ClientEncryptionKeyResource", modelProperties: { id: { serializedName: "id", - readOnly: true, type: { name: "String" } }, - storageInKB: { - serializedName: "storageInKB", - readOnly: true, + encryptionAlgorithm: { + serializedName: "encryptionAlgorithm", type: { - name: "Number" + name: "String" } - } - } - } -}; - -export const RetrieveThroughputPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RetrieveThroughputPropertiesResource", - modelProperties: { - physicalPartitionIds: { - serializedName: "physicalPartitionIds", - required: true, + }, + wrappedDataEncryptionKey: { + serializedName: "wrappedDataEncryptionKey", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PhysicalPartitionId" - } - } + name: "ByteArray" + } + }, + keyWrapMetadata: { + serializedName: "keyWrapMetadata", + type: { + name: "Composite", + className: "KeyWrapMetadata" } } } } }; -export const PhysicalPartitionId: coreClient.CompositeMapper = { +export const KeyWrapMetadata: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PhysicalPartitionId", + className: "KeyWrapMetadata", modelProperties: { - id: { - serializedName: "id", - required: true, + name: { + serializedName: "name", type: { name: "String" } - } - } - } -}; - -export const PhysicalPartitionThroughputInfoProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoProperties", - modelProperties: { - physicalPartitionThroughputInfo: { - serializedName: "physicalPartitionThroughputInfo", + }, + type: { + serializedName: "type", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResource" - } - } + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "String" + } + }, + algorithm: { + serializedName: "algorithm", + type: { + name: "String" } } } } }; -export const PhysicalPartitionThroughputInfoResource: coreClient.CompositeMapper = { +export const ARMProxyResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PhysicalPartitionThroughputInfoResource", + className: "ARMProxyResource", modelProperties: { id: { serializedName: "id", - required: true, + readOnly: true, type: { name: "String" } }, - throughput: { - serializedName: "throughput", + name: { + serializedName: "name", + readOnly: true, type: { - name: "Number" + name: "String" + } + }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String" } } } } }; -export const RedistributeThroughputPropertiesResource: coreClient.CompositeMapper = { +export const ClientEncryptionKeyCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RedistributeThroughputPropertiesResource", + className: "ClientEncryptionKeyCreateUpdateParameters", modelProperties: { - throughputPolicy: { - serializedName: "throughputPolicy", - required: true, - type: { - name: "String" - } - }, - targetPhysicalPartitionThroughputInfo: { - serializedName: "targetPhysicalPartitionThroughputInfo", - required: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResource" - } - } - } - }, - sourcePhysicalPartitionThroughputInfo: { - serializedName: "sourcePhysicalPartitionThroughputInfo", - required: true, + resource: { + serializedName: "properties.resource", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResource" - } - } + name: "Composite", + className: "ClientEncryptionKeyResource" } } } @@ -2965,19 +2706,6 @@ export const MongoDBDatabaseResource: coreClient.CompositeMapper = { type: { name: "String" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } } } } @@ -3041,19 +2769,6 @@ export const MongoDBCollectionResource: coreClient.CompositeMapper = { type: { name: "Number" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } } } } @@ -3156,19 +2871,6 @@ export const TableResource: coreClient.CompositeMapper = { type: { name: "String" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } } } } @@ -3404,19 +3106,6 @@ export const GremlinDatabaseResource: coreClient.CompositeMapper = { type: { name: "String" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } } } } @@ -3495,19 +3184,6 @@ export const GremlinGraphResource: coreClient.CompositeMapper = { type: { name: "Number" } - }, - restoreParameters: { - serializedName: "restoreParameters", - type: { - name: "Composite", - className: "ResourceRestoreParameters" - } - }, - createMode: { - serializedName: "createMode", - type: { - name: "String" - } } } } @@ -3591,20 +3267,19 @@ export const LocationProperties: coreClient.CompositeMapper = { } }; -export const CassandraViewListResult: coreClient.CompositeMapper = { +export const ListClusters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CassandraViewListResult", + className: "ListClusters", modelProperties: { value: { serializedName: "value", - readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "CassandraViewGetResults" + className: "ClusterResource" } } } @@ -3613,208 +3288,39 @@ export const CassandraViewListResult: coreClient.CompositeMapper = { } }; -export const CassandraViewResource: coreClient.CompositeMapper = { +export const ClusterResourceProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CassandraViewResource", + className: "ClusterResourceProperties", modelProperties: { - id: { - serializedName: "id", - required: true, + provisioningState: { + serializedName: "provisioningState", type: { name: "String" } }, - viewDefinition: { - serializedName: "viewDefinition", - required: true, + restoreFromBackupId: { + serializedName: "restoreFromBackupId", type: { name: "String" } - } - } - } -}; - -export const DataTransferJobProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataTransferJobProperties", - modelProperties: { - jobName: { - serializedName: "jobName", - readOnly: true, + }, + delegatedManagementSubnetId: { + serializedName: "delegatedManagementSubnetId", type: { name: "String" } }, - source: { - serializedName: "source", + cassandraVersion: { + serializedName: "cassandraVersion", type: { - name: "Composite", - className: "DataTransferDataSourceSink" + name: "String" } }, - destination: { - serializedName: "destination", + clusterNameOverride: { + serializedName: "clusterNameOverride", type: { - name: "Composite", - className: "DataTransferDataSourceSink" - } - }, - status: { - serializedName: "status", - readOnly: true, - type: { - name: "String" - } - }, - processedCount: { - serializedName: "processedCount", - readOnly: true, - type: { - name: "Number" - } - }, - totalCount: { - serializedName: "totalCount", - readOnly: true, - type: { - name: "Number" - } - }, - lastUpdatedUtcTime: { - serializedName: "lastUpdatedUtcTime", - readOnly: true, - type: { - name: "DateTime" - } - }, - workerCount: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "workerCount", - type: { - name: "Number" - } - }, - error: { - serializedName: "error", - type: { - name: "Composite", - className: "ErrorResponse" - } - } - } - } -}; - -export const DataTransferDataSourceSink: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataTransferDataSourceSink", - uberParent: "DataTransferDataSourceSink", - polymorphicDiscriminator: { - serializedName: "component", - clientName: "component" - }, - modelProperties: { - component: { - defaultValue: "CosmosDBCassandra", - serializedName: "component", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const DataTransferJobFeedResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataTransferJobFeedResults", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DataTransferJobGetResults" - } - } - } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const ListClusters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ListClusters", - modelProperties: { - value: { - serializedName: "value", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ClusterResource" - } - } - } - } - } - } -}; - -export const ClusterResourceProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClusterResourceProperties", - modelProperties: { - provisioningState: { - serializedName: "provisioningState", - type: { - name: "String" - } - }, - restoreFromBackupId: { - serializedName: "restoreFromBackupId", - type: { - name: "String" - } - }, - delegatedManagementSubnetId: { - serializedName: "delegatedManagementSubnetId", - type: { - name: "String" - } - }, - cassandraVersion: { - serializedName: "cassandraVersion", - type: { - name: "String" - } - }, - clusterNameOverride: { - serializedName: "clusterNameOverride", - type: { - name: "String" + name: "String" } }, authenticationMethod: { @@ -4132,43 +3638,6 @@ export const CommandOutput: coreClient.CompositeMapper = { } }; -export const ListBackups: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ListBackups", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "BackupResource" - } - } - } - } - } - } -}; - -export const BackupResourceProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BackupResourceProperties", - modelProperties: { - timestamp: { - serializedName: "timestamp", - type: { - name: "DateTime" - } - } - } - } -}; - export const ListDataCenters: coreClient.CompositeMapper = { type: { name: "Composite", @@ -4644,47 +4113,46 @@ export const ComponentsM9L909SchemasCassandraclusterpublicstatusPropertiesDatace } }; -export const MongoClusterListResult: coreClient.CompositeMapper = { +export const Privilege: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoClusterListResult", + className: "Privilege", modelProperties: { - value: { - serializedName: "value", + resource: { + serializedName: "resource", + type: { + name: "Composite", + className: "PrivilegeResource" + } + }, + actions: { + serializedName: "actions", type: { name: "Sequence", element: { type: { - name: "Composite", - className: "MongoCluster" + name: "String" } } } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } } } } }; -export const MongoClusterRestoreParameters: coreClient.CompositeMapper = { +export const PrivilegeResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoClusterRestoreParameters", + className: "PrivilegeResource", modelProperties: { - pointInTimeUTC: { - serializedName: "pointInTimeUTC", + db: { + serializedName: "db", type: { - name: "DateTime" + name: "String" } }, - sourceResourceId: { - serializedName: "sourceResourceId", + collection: { + serializedName: "collection", type: { name: "String" } @@ -4693,134 +4161,166 @@ export const MongoClusterRestoreParameters: coreClient.CompositeMapper = { } }; -export const NodeGroupProperties: coreClient.CompositeMapper = { +export const Role: coreClient.CompositeMapper = { type: { name: "Composite", - className: "NodeGroupProperties", + className: "Role", modelProperties: { - sku: { - serializedName: "sku", + db: { + serializedName: "db", type: { name: "String" } }, - diskSizeGB: { - serializedName: "diskSizeGB", - type: { - name: "Number" - } - }, - enableHa: { - serializedName: "enableHa", + role: { + serializedName: "role", type: { - name: "Boolean" + name: "String" } } } } }; -export const ResourceAutoGenerated: coreClient.CompositeMapper = { +export const MongoRoleDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ResourceAutoGenerated", + className: "MongoRoleDefinitionCreateUpdateParameters", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + roleName: { + serializedName: "properties.roleName", type: { name: "String" } }, - name: { - serializedName: "name", - readOnly: true, + type: { + serializedName: "properties.type", type: { - name: "String" + name: "Enum", + allowedValues: ["BuiltInRole", "CustomRole"] } }, - type: { - serializedName: "type", - readOnly: true, + databaseName: { + serializedName: "properties.databaseName", type: { name: "String" } }, - systemData: { - serializedName: "systemData", + privileges: { + serializedName: "properties.privileges", type: { - name: "Composite", - className: "SystemData" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Privilege" + } + } + } + }, + roles: { + serializedName: "properties.roles", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Role" + } + } } } } } }; -export const ErrorResponseAutoGenerated: coreClient.CompositeMapper = { +export const MongoRoleDefinitionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorResponseAutoGenerated", + className: "MongoRoleDefinitionListResult", modelProperties: { - error: { - serializedName: "error", + value: { + serializedName: "value", + readOnly: true, type: { - name: "Composite", - className: "ErrorDetail" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MongoRoleDefinitionGetResults" + } + } } } } } }; -export const ErrorDetail: coreClient.CompositeMapper = { +export const MongoUserDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorDetail", + className: "MongoUserDefinitionCreateUpdateParameters", modelProperties: { - code: { - serializedName: "code", - readOnly: true, + userName: { + serializedName: "properties.userName", type: { name: "String" } }, - message: { - serializedName: "message", - readOnly: true, + password: { + serializedName: "properties.password", type: { name: "String" } }, - target: { - serializedName: "target", - readOnly: true, + databaseName: { + serializedName: "properties.databaseName", type: { name: "String" } }, - details: { - serializedName: "details", - readOnly: true, + customData: { + serializedName: "properties.customData", + type: { + name: "String" + } + }, + roles: { + serializedName: "properties.roles", type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorDetail" + className: "Role" } } } }, - additionalInfo: { - serializedName: "additionalInfo", + mechanisms: { + serializedName: "properties.mechanisms", + type: { + name: "String" + } + } + } + } +}; + +export const MongoUserDefinitionListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "MongoUserDefinitionListResult", + modelProperties: { + value: { + serializedName: "value", readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ErrorAdditionalInfo" + className: "MongoUserDefinitionGetResults" } } } @@ -4829,112 +4329,63 @@ export const ErrorDetail: coreClient.CompositeMapper = { } }; -export const ErrorAdditionalInfo: coreClient.CompositeMapper = { +export const NotebookWorkspaceListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ErrorAdditionalInfo", + className: "NotebookWorkspaceListResult", modelProperties: { - type: { - serializedName: "type", - readOnly: true, - type: { - name: "String" - } - }, - info: { - serializedName: "info", - readOnly: true, + value: { + serializedName: "value", type: { - name: "Dictionary", - value: { type: { name: "any" } } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "NotebookWorkspace" + } + } } } } } }; -export const MongoClusterUpdate: coreClient.CompositeMapper = { +export const NotebookWorkspaceConnectionInfoResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoClusterUpdate", + className: "NotebookWorkspaceConnectionInfoResult", modelProperties: { - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } } - } - }, - createMode: { - serializedName: "properties.createMode", - type: { - name: "String" - } - }, - restoreParameters: { - serializedName: "properties.restoreParameters", - type: { - name: "Composite", - className: "MongoClusterRestoreParameters" - } - }, - administratorLogin: { - serializedName: "properties.administratorLogin", - type: { - name: "String" - } - }, - administratorLoginPassword: { - serializedName: "properties.administratorLoginPassword", - type: { - name: "String" - } - }, - serverVersion: { - serializedName: "properties.serverVersion", - type: { - name: "String" - } - }, - connectionString: { - serializedName: "properties.connectionString", - readOnly: true, - type: { - name: "String" - } - }, - earliestRestoreTime: { - serializedName: "properties.earliestRestoreTime", - readOnly: true, - type: { - name: "String" - } - }, - provisioningState: { - serializedName: "properties.provisioningState", + authToken: { + serializedName: "authToken", readOnly: true, type: { name: "String" } }, - clusterStatus: { - serializedName: "properties.clusterStatus", + notebookServerEndpoint: { + serializedName: "notebookServerEndpoint", readOnly: true, type: { name: "String" } - }, - nodeGroupSpecs: { - constraints: { - MinItems: 1 - }, - serializedName: "properties.nodeGroupSpecs", + } + } + } +}; + +export const PrivateEndpointConnectionListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "PrivateEndpointConnectionListResult", + modelProperties: { + value: { + serializedName: "value", type: { name: "Sequence", element: { type: { name: "Composite", - className: "NodeGroupSpec" + className: "PrivateEndpointConnection" } } } @@ -4943,10 +4394,10 @@ export const MongoClusterUpdate: coreClient.CompositeMapper = { } }; -export const FirewallRuleListResult: coreClient.CompositeMapper = { +export const PrivateLinkResourceListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "FirewallRuleListResult", + className: "PrivateLinkResourceListResult", modelProperties: { value: { serializedName: "value", @@ -4955,84 +4406,105 @@ export const FirewallRuleListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "FirewallRule" + className: "PrivateLinkResource" } } } - }, - nextLink: { - serializedName: "nextLink", - readOnly: true, - type: { - name: "String" - } } } } }; -export const CheckNameAvailabilityRequest: coreClient.CompositeMapper = { +export const Permission: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CheckNameAvailabilityRequest", + className: "Permission", modelProperties: { - name: { - serializedName: "name", + dataActions: { + serializedName: "dataActions", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - type: { - serializedName: "type", + notDataActions: { + serializedName: "notDataActions", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } } } } }; -export const CheckNameAvailabilityResponse: coreClient.CompositeMapper = { +export const SqlRoleDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CheckNameAvailabilityResponse", + className: "SqlRoleDefinitionCreateUpdateParameters", modelProperties: { - nameAvailable: { - serializedName: "nameAvailable", + roleName: { + serializedName: "properties.roleName", type: { - name: "Boolean" + name: "String" } }, - reason: { - serializedName: "reason", + type: { + serializedName: "properties.type", type: { - name: "String" + name: "Enum", + allowedValues: ["BuiltInRole", "CustomRole"] } }, - message: { - serializedName: "message", + assignableScopes: { + serializedName: "properties.assignableScopes", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + permissions: { + serializedName: "properties.permissions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Permission" + } + } } } } } }; -export const ListConnectionStringsResult: coreClient.CompositeMapper = { +export const SqlRoleDefinitionListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ListConnectionStringsResult", + className: "SqlRoleDefinitionListResult", modelProperties: { - connectionStrings: { - serializedName: "connectionStrings", + value: { + serializedName: "value", readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "ConnectionString" + className: "SqlRoleDefinitionGetResults" } } } @@ -5041,21 +4513,25 @@ export const ListConnectionStringsResult: coreClient.CompositeMapper = { } }; -export const ConnectionString: coreClient.CompositeMapper = { +export const SqlRoleAssignmentCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ConnectionString", + className: "SqlRoleAssignmentCreateUpdateParameters", modelProperties: { - connectionString: { - serializedName: "connectionString", - readOnly: true, + roleDefinitionId: { + serializedName: "properties.roleDefinitionId", type: { name: "String" } }, - description: { - serializedName: "description", - readOnly: true, + scope: { + serializedName: "properties.scope", + type: { + name: "String" + } + }, + principalId: { + serializedName: "properties.principalId", type: { name: "String" } @@ -5064,25 +4540,20 @@ export const ConnectionString: coreClient.CompositeMapper = { } }; -export const Privilege: coreClient.CompositeMapper = { +export const SqlRoleAssignmentListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Privilege", + className: "SqlRoleAssignmentListResult", modelProperties: { - resource: { - serializedName: "resource", - type: { - name: "Composite", - className: "PrivilegeResource" - } - }, - actions: { - serializedName: "actions", + value: { + serializedName: "value", + readOnly: true, type: { name: "Sequence", element: { type: { - name: "String" + name: "Composite", + className: "SqlRoleAssignmentGetResults" } } } @@ -5091,114 +4562,100 @@ export const Privilege: coreClient.CompositeMapper = { } }; -export const PrivilegeResource: coreClient.CompositeMapper = { +export const RestorableDatabaseAccountsListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivilegeResource", + className: "RestorableDatabaseAccountsListResult", modelProperties: { - db: { - serializedName: "db", - type: { - name: "String" - } - }, - collection: { - serializedName: "collection", + value: { + serializedName: "value", + readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RestorableDatabaseAccountGetResult" + } + } } } } } }; -export const Role: coreClient.CompositeMapper = { +export const RestorableDatabaseAccountGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "Role", + className: "RestorableDatabaseAccountGetResult", modelProperties: { - db: { - serializedName: "db", + id: { + serializedName: "id", + readOnly: true, type: { name: "String" } }, - role: { - serializedName: "role", + name: { + serializedName: "name", + readOnly: true, type: { name: "String" } - } - } - } -}; - -export const MongoRoleDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoRoleDefinitionCreateUpdateParameters", - modelProperties: { - roleName: { - serializedName: "properties.roleName", + }, + type: { + serializedName: "type", + readOnly: true, type: { name: "String" } }, - type: { - serializedName: "properties.type", + location: { + serializedName: "location", type: { - name: "Enum", - allowedValues: ["BuiltInRole", "CustomRole"] + name: "String" } }, - databaseName: { - serializedName: "properties.databaseName", + accountName: { + serializedName: "properties.accountName", type: { name: "String" } }, - privileges: { - serializedName: "properties.privileges", + creationTime: { + serializedName: "properties.creationTime", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Privilege" - } - } + name: "DateTime" } }, - roles: { - serializedName: "properties.roles", + deletionTime: { + serializedName: "properties.deletionTime", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Role" - } - } + name: "DateTime" } - } - } - } -}; - -export const MongoRoleDefinitionListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoRoleDefinitionListResult", - modelProperties: { - value: { - serializedName: "value", + }, + oldestRestorableTime: { + serializedName: "properties.oldestRestorableTime", + type: { + name: "DateTime" + } + }, + apiType: { + serializedName: "properties.apiType", + readOnly: true, + type: { + name: "String" + } + }, + restorableLocations: { + serializedName: "properties.restorableLocations", readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "MongoRoleDefinitionGetResults" + className: "RestorableLocationResource" } } } @@ -5207,115 +4664,81 @@ export const MongoRoleDefinitionListResult: coreClient.CompositeMapper = { } }; -export const MongoUserDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { +export const RestorableLocationResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoUserDefinitionCreateUpdateParameters", + className: "RestorableLocationResource", modelProperties: { - userName: { - serializedName: "properties.userName", - type: { - name: "String" - } - }, - password: { - serializedName: "properties.password", - type: { - name: "String" - } - }, - databaseName: { - serializedName: "properties.databaseName", + locationName: { + serializedName: "locationName", + readOnly: true, type: { name: "String" } }, - customData: { - serializedName: "properties.customData", + regionalDatabaseAccountInstanceId: { + serializedName: "regionalDatabaseAccountInstanceId", + readOnly: true, type: { name: "String" } }, - roles: { - serializedName: "properties.roles", + creationTime: { + serializedName: "creationTime", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Role" - } - } + name: "DateTime" } }, - mechanisms: { - serializedName: "properties.mechanisms", + deletionTime: { + serializedName: "deletionTime", + readOnly: true, type: { - name: "String" + name: "DateTime" } } } } }; -export const MongoUserDefinitionListResult: coreClient.CompositeMapper = { +export const ContinuousBackupRestoreLocation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoUserDefinitionListResult", + className: "ContinuousBackupRestoreLocation", modelProperties: { - value: { - serializedName: "value", - readOnly: true, + location: { + serializedName: "location", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "MongoUserDefinitionGetResults" - } - } + name: "String" } } } } }; -export const NotebookWorkspaceListResult: coreClient.CompositeMapper = { +export const BackupInformation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "NotebookWorkspaceListResult", + className: "BackupInformation", modelProperties: { - value: { - serializedName: "value", + continuousBackupInformation: { + serializedName: "continuousBackupInformation", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "NotebookWorkspace" - } - } + name: "Composite", + className: "ContinuousBackupInformation" } } } } }; -export const NotebookWorkspaceConnectionInfoResult: coreClient.CompositeMapper = { +export const ContinuousBackupInformation: coreClient.CompositeMapper = { type: { name: "Composite", - className: "NotebookWorkspaceConnectionInfoResult", + className: "ContinuousBackupInformation", modelProperties: { - authToken: { - serializedName: "authToken", - readOnly: true, - type: { - name: "String" - } - }, - notebookServerEndpoint: { - serializedName: "notebookServerEndpoint", - readOnly: true, + latestRestorableTimestamp: { + serializedName: "latestRestorableTimestamp", type: { name: "String" } @@ -5324,19 +4747,20 @@ export const NotebookWorkspaceConnectionInfoResult: coreClient.CompositeMapper = } }; -export const PrivateEndpointConnectionListResult: coreClient.CompositeMapper = { +export const RestorableSqlDatabasesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateEndpointConnectionListResult", + className: "RestorableSqlDatabasesListResult", modelProperties: { value: { serializedName: "value", + readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "PrivateEndpointConnection" + className: "RestorableSqlDatabaseGetResult" } } } @@ -5345,107 +4769,98 @@ export const PrivateEndpointConnectionListResult: coreClient.CompositeMapper = { } }; -export const PrivateLinkResourceListResult: coreClient.CompositeMapper = { +export const RestorableSqlDatabaseGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateLinkResourceListResult", + className: "RestorableSqlDatabaseGetResult", modelProperties: { - value: { - serializedName: "value", + id: { + serializedName: "id", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "PrivateLinkResource" - } - } + name: "String" } - } - } - } -}; - -export const Permission: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "Permission", - modelProperties: { - dataActions: { - serializedName: "dataActions", + }, + name: { + serializedName: "name", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } }, - notDataActions: { - serializedName: "notDataActions", + type: { + serializedName: "type", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" + } + }, + resource: { + serializedName: "properties.resource", + type: { + name: "Composite", + className: "RestorableSqlDatabasePropertiesResource" } } } } }; -export const SqlRoleDefinitionCreateUpdateParameters: coreClient.CompositeMapper = { +export const RestorableSqlDatabasePropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlRoleDefinitionCreateUpdateParameters", + className: "RestorableSqlDatabasePropertiesResource", modelProperties: { - roleName: { - serializedName: "properties.roleName", + rid: { + serializedName: "_rid", + readOnly: true, type: { name: "String" } }, - type: { - serializedName: "properties.type", + operationType: { + serializedName: "operationType", + readOnly: true, type: { - name: "Enum", - allowedValues: ["BuiltInRole", "CustomRole"] + name: "String" } }, - assignableScopes: { - serializedName: "properties.assignableScopes", + eventTimestamp: { + serializedName: "eventTimestamp", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } + name: "String" } }, - permissions: { - serializedName: "properties.permissions", + ownerId: { + serializedName: "ownerId", + readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Permission" - } - } + name: "String" + } + }, + ownerResourceId: { + serializedName: "ownerResourceId", + readOnly: true, + type: { + name: "String" + } + }, + database: { + serializedName: "database", + type: { + name: "Composite", + className: "RestorableSqlDatabasePropertiesResourceDatabase" } } } } }; -export const SqlRoleDefinitionListResult: coreClient.CompositeMapper = { +export const RestorableSqlContainersListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlRoleDefinitionListResult", + className: "RestorableSqlContainersListResult", modelProperties: { value: { serializedName: "value", @@ -5455,7 +4870,7 @@ export const SqlRoleDefinitionListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "SqlRoleDefinitionGetResults" + className: "RestorableSqlContainerGetResult" } } } @@ -5464,59 +4879,98 @@ export const SqlRoleDefinitionListResult: coreClient.CompositeMapper = { } }; -export const SqlRoleAssignmentCreateUpdateParameters: coreClient.CompositeMapper = { +export const RestorableSqlContainerGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlRoleAssignmentCreateUpdateParameters", + className: "RestorableSqlContainerGetResult", modelProperties: { - roleDefinitionId: { - serializedName: "properties.roleDefinitionId", + id: { + serializedName: "id", + readOnly: true, type: { name: "String" } }, - scope: { - serializedName: "properties.scope", + name: { + serializedName: "name", + readOnly: true, type: { name: "String" } }, - principalId: { - serializedName: "properties.principalId", + type: { + serializedName: "type", + readOnly: true, type: { name: "String" } + }, + resource: { + serializedName: "properties.resource", + type: { + name: "Composite", + className: "RestorableSqlContainerPropertiesResource" + } } } } }; -export const SqlRoleAssignmentListResult: coreClient.CompositeMapper = { +export const RestorableSqlContainerPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlRoleAssignmentListResult", + className: "RestorableSqlContainerPropertiesResource", modelProperties: { - value: { - serializedName: "value", + rid: { + serializedName: "_rid", readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SqlRoleAssignmentGetResults" - } - } + name: "String" + } + }, + operationType: { + serializedName: "operationType", + readOnly: true, + type: { + name: "String" + } + }, + eventTimestamp: { + serializedName: "eventTimestamp", + readOnly: true, + type: { + name: "String" + } + }, + ownerId: { + serializedName: "ownerId", + readOnly: true, + type: { + name: "String" + } + }, + ownerResourceId: { + serializedName: "ownerResourceId", + readOnly: true, + type: { + name: "String" + } + }, + container: { + serializedName: "container", + type: { + name: "Composite", + className: "RestorableSqlContainerPropertiesResourceContainer" } } } } }; -export const RestorableDatabaseAccountsListResult: coreClient.CompositeMapper = { +export const RestorableSqlResourcesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableDatabaseAccountsListResult", + className: "RestorableSqlResourcesListResult", modelProperties: { value: { serializedName: "value", @@ -5526,7 +4980,7 @@ export const RestorableDatabaseAccountsListResult: coreClient.CompositeMapper = element: { type: { name: "Composite", - className: "RestorableDatabaseAccountGetResult" + className: "RestorableSqlResourcesGetResult" } } } @@ -5535,10 +4989,10 @@ export const RestorableDatabaseAccountsListResult: coreClient.CompositeMapper = } }; -export const RestorableDatabaseAccountGetResult: coreClient.CompositeMapper = { +export const RestorableSqlResourcesGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableDatabaseAccountGetResult", + className: "RestorableSqlResourcesGetResult", modelProperties: { id: { serializedName: "id", @@ -5561,52 +5015,41 @@ export const RestorableDatabaseAccountGetResult: coreClient.CompositeMapper = { name: "String" } }, - location: { - serializedName: "location", - type: { - name: "String" - } - }, - accountName: { - serializedName: "properties.accountName", + databaseName: { + serializedName: "databaseName", type: { name: "String" } }, - creationTime: { - serializedName: "properties.creationTime", - type: { - name: "DateTime" - } - }, - oldestRestorableTime: { - serializedName: "properties.oldestRestorableTime", - type: { - name: "DateTime" - } - }, - deletionTime: { - serializedName: "properties.deletionTime", - type: { - name: "DateTime" - } - }, - apiType: { - serializedName: "properties.apiType", - readOnly: true, + collectionNames: { + serializedName: "collectionNames", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } - }, - restorableLocations: { - serializedName: "properties.restorableLocations", + } + } + } +}; + +export const RestorableMongodbDatabasesListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "RestorableMongodbDatabasesListResult", + modelProperties: { + value: { + serializedName: "value", readOnly: true, type: { name: "Sequence", element: { type: { name: "Composite", - className: "RestorableLocationResource" + className: "RestorableMongodbDatabaseGetResult" } } } @@ -5615,152 +5058,47 @@ export const RestorableDatabaseAccountGetResult: coreClient.CompositeMapper = { } }; -export const RestorableLocationResource: coreClient.CompositeMapper = { +export const RestorableMongodbDatabaseGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableLocationResource", + className: "RestorableMongodbDatabaseGetResult", modelProperties: { - locationName: { - serializedName: "locationName", + id: { + serializedName: "id", readOnly: true, type: { name: "String" } }, - regionalDatabaseAccountInstanceId: { - serializedName: "regionalDatabaseAccountInstanceId", + name: { + serializedName: "name", readOnly: true, type: { name: "String" } }, - creationTime: { - serializedName: "creationTime", + type: { + serializedName: "type", readOnly: true, type: { - name: "DateTime" + name: "String" } }, - deletionTime: { - serializedName: "deletionTime", - readOnly: true, + resource: { + serializedName: "properties.resource", type: { - name: "DateTime" + name: "Composite", + className: "RestorableMongodbDatabasePropertiesResource" } } } } }; -export const ContinuousBackupRestoreLocation: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContinuousBackupRestoreLocation", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const BackupInformation: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BackupInformation", - modelProperties: { - continuousBackupInformation: { - serializedName: "continuousBackupInformation", - type: { - name: "Composite", - className: "ContinuousBackupInformation" - } - } - } - } -}; - -export const ContinuousBackupInformation: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContinuousBackupInformation", - modelProperties: { - latestRestorableTimestamp: { - serializedName: "latestRestorableTimestamp", - type: { - name: "String" - } - } - } - } -}; - -export const RestorableSqlDatabasesListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestorableSqlDatabasesListResult", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "RestorableSqlDatabaseGetResult" - } - } - } - } - } - } -}; - -export const RestorableSqlDatabaseGetResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestorableSqlDatabaseGetResult", - modelProperties: { - id: { - serializedName: "id", - readOnly: true, - type: { - name: "String" - } - }, - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String" - } - }, - type: { - serializedName: "type", - readOnly: true, - type: { - name: "String" - } - }, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "RestorableSqlDatabasePropertiesResource" - } - } - } - } -}; - -export const RestorableSqlDatabasePropertiesResource: coreClient.CompositeMapper = { +export const RestorableMongodbDatabasePropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlDatabasePropertiesResource", + className: "RestorableMongodbDatabasePropertiesResource", modelProperties: { rid: { serializedName: "_rid", @@ -5796,22 +5134,15 @@ export const RestorableSqlDatabasePropertiesResource: coreClient.CompositeMapper type: { name: "String" } - }, - database: { - serializedName: "database", - type: { - name: "Composite", - className: "RestorableSqlDatabasePropertiesResourceDatabase" - } } } } }; -export const RestorableSqlContainersListResult: coreClient.CompositeMapper = { +export const RestorableMongodbCollectionsListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlContainersListResult", + className: "RestorableMongodbCollectionsListResult", modelProperties: { value: { serializedName: "value", @@ -5821,7 +5152,7 @@ export const RestorableSqlContainersListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "RestorableSqlContainerGetResult" + className: "RestorableMongodbCollectionGetResult" } } } @@ -5830,10 +5161,10 @@ export const RestorableSqlContainersListResult: coreClient.CompositeMapper = { } }; -export const RestorableSqlContainerGetResult: coreClient.CompositeMapper = { +export const RestorableMongodbCollectionGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlContainerGetResult", + className: "RestorableMongodbCollectionGetResult", modelProperties: { id: { serializedName: "id", @@ -5860,17 +5191,17 @@ export const RestorableSqlContainerGetResult: coreClient.CompositeMapper = { serializedName: "properties.resource", type: { name: "Composite", - className: "RestorableSqlContainerPropertiesResource" + className: "RestorableMongodbCollectionPropertiesResource" } } } } }; -export const RestorableSqlContainerPropertiesResource: coreClient.CompositeMapper = { +export const RestorableMongodbCollectionPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlContainerPropertiesResource", + className: "RestorableMongodbCollectionPropertiesResource", modelProperties: { rid: { serializedName: "_rid", @@ -5906,22 +5237,15 @@ export const RestorableSqlContainerPropertiesResource: coreClient.CompositeMappe type: { name: "String" } - }, - container: { - serializedName: "container", - type: { - name: "Composite", - className: "RestorableSqlContainerPropertiesResourceContainer" - } } } } }; -export const RestorableSqlResourcesListResult: coreClient.CompositeMapper = { +export const RestorableMongodbResourcesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlResourcesListResult", + className: "RestorableMongodbResourcesListResult", modelProperties: { value: { serializedName: "value", @@ -5931,7 +5255,7 @@ export const RestorableSqlResourcesListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "RestorableSqlResourcesGetResult" + className: "RestorableMongodbResourcesGetResult" } } } @@ -5940,10 +5264,10 @@ export const RestorableSqlResourcesListResult: coreClient.CompositeMapper = { } }; -export const RestorableSqlResourcesGetResult: coreClient.CompositeMapper = { +export const RestorableMongodbResourcesGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableSqlResourcesGetResult", + className: "RestorableMongodbResourcesGetResult", modelProperties: { id: { serializedName: "id", @@ -5987,10 +5311,10 @@ export const RestorableSqlResourcesGetResult: coreClient.CompositeMapper = { } }; -export const RestorableMongodbDatabasesListResult: coreClient.CompositeMapper = { +export const RestorableGremlinDatabasesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbDatabasesListResult", + className: "RestorableGremlinDatabasesListResult", modelProperties: { value: { serializedName: "value", @@ -6000,7 +5324,7 @@ export const RestorableMongodbDatabasesListResult: coreClient.CompositeMapper = element: { type: { name: "Composite", - className: "RestorableMongodbDatabaseGetResult" + className: "RestorableGremlinDatabaseGetResult" } } } @@ -6009,10 +5333,10 @@ export const RestorableMongodbDatabasesListResult: coreClient.CompositeMapper = } }; -export const RestorableMongodbDatabaseGetResult: coreClient.CompositeMapper = { +export const RestorableGremlinDatabaseGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbDatabaseGetResult", + className: "RestorableGremlinDatabaseGetResult", modelProperties: { id: { serializedName: "id", @@ -6039,17 +5363,17 @@ export const RestorableMongodbDatabaseGetResult: coreClient.CompositeMapper = { serializedName: "properties.resource", type: { name: "Composite", - className: "RestorableMongodbDatabasePropertiesResource" + className: "RestorableGremlinDatabasePropertiesResource" } } } } }; -export const RestorableMongodbDatabasePropertiesResource: coreClient.CompositeMapper = { +export const RestorableGremlinDatabasePropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbDatabasePropertiesResource", + className: "RestorableGremlinDatabasePropertiesResource", modelProperties: { rid: { serializedName: "_rid", @@ -6090,10 +5414,10 @@ export const RestorableMongodbDatabasePropertiesResource: coreClient.CompositeMa } }; -export const RestorableMongodbCollectionsListResult: coreClient.CompositeMapper = { +export const RestorableGremlinGraphsListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbCollectionsListResult", + className: "RestorableGremlinGraphsListResult", modelProperties: { value: { serializedName: "value", @@ -6103,7 +5427,7 @@ export const RestorableMongodbCollectionsListResult: coreClient.CompositeMapper element: { type: { name: "Composite", - className: "RestorableMongodbCollectionGetResult" + className: "RestorableGremlinGraphGetResult" } } } @@ -6112,10 +5436,10 @@ export const RestorableMongodbCollectionsListResult: coreClient.CompositeMapper } }; -export const RestorableMongodbCollectionGetResult: coreClient.CompositeMapper = { +export const RestorableGremlinGraphGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbCollectionGetResult", + className: "RestorableGremlinGraphGetResult", modelProperties: { id: { serializedName: "id", @@ -6142,17 +5466,17 @@ export const RestorableMongodbCollectionGetResult: coreClient.CompositeMapper = serializedName: "properties.resource", type: { name: "Composite", - className: "RestorableMongodbCollectionPropertiesResource" + className: "RestorableGremlinGraphPropertiesResource" } } } } }; -export const RestorableMongodbCollectionPropertiesResource: coreClient.CompositeMapper = { +export const RestorableGremlinGraphPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbCollectionPropertiesResource", + className: "RestorableGremlinGraphPropertiesResource", modelProperties: { rid: { serializedName: "_rid", @@ -6193,10 +5517,10 @@ export const RestorableMongodbCollectionPropertiesResource: coreClient.Composite } }; -export const RestorableMongodbResourcesListResult: coreClient.CompositeMapper = { +export const RestorableGremlinResourcesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbResourcesListResult", + className: "RestorableGremlinResourcesListResult", modelProperties: { value: { serializedName: "value", @@ -6206,7 +5530,7 @@ export const RestorableMongodbResourcesListResult: coreClient.CompositeMapper = element: { type: { name: "Composite", - className: "RestorableMongodbResourcesGetResult" + className: "RestorableGremlinResourcesGetResult" } } } @@ -6215,10 +5539,10 @@ export const RestorableMongodbResourcesListResult: coreClient.CompositeMapper = } }; -export const RestorableMongodbResourcesGetResult: coreClient.CompositeMapper = { +export const RestorableGremlinResourcesGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableMongodbResourcesGetResult", + className: "RestorableGremlinResourcesGetResult", modelProperties: { id: { serializedName: "id", @@ -6247,8 +5571,8 @@ export const RestorableMongodbResourcesGetResult: coreClient.CompositeMapper = { name: "String" } }, - collectionNames: { - serializedName: "collectionNames", + graphNames: { + serializedName: "graphNames", type: { name: "Sequence", element: { @@ -6262,10 +5586,10 @@ export const RestorableMongodbResourcesGetResult: coreClient.CompositeMapper = { } }; -export const RestorableGremlinDatabasesListResult: coreClient.CompositeMapper = { +export const RestorableTablesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinDatabasesListResult", + className: "RestorableTablesListResult", modelProperties: { value: { serializedName: "value", @@ -6275,7 +5599,7 @@ export const RestorableGremlinDatabasesListResult: coreClient.CompositeMapper = element: { type: { name: "Composite", - className: "RestorableGremlinDatabaseGetResult" + className: "RestorableTableGetResult" } } } @@ -6284,10 +5608,10 @@ export const RestorableGremlinDatabasesListResult: coreClient.CompositeMapper = } }; -export const RestorableGremlinDatabaseGetResult: coreClient.CompositeMapper = { +export const RestorableTableGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinDatabaseGetResult", + className: "RestorableTableGetResult", modelProperties: { id: { serializedName: "id", @@ -6314,17 +5638,17 @@ export const RestorableGremlinDatabaseGetResult: coreClient.CompositeMapper = { serializedName: "properties.resource", type: { name: "Composite", - className: "RestorableGremlinDatabasePropertiesResource" + className: "RestorableTablePropertiesResource" } } } } }; -export const RestorableGremlinDatabasePropertiesResource: coreClient.CompositeMapper = { +export const RestorableTablePropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinDatabasePropertiesResource", + className: "RestorableTablePropertiesResource", modelProperties: { rid: { serializedName: "_rid", @@ -6365,10 +5689,10 @@ export const RestorableGremlinDatabasePropertiesResource: coreClient.CompositeMa } }; -export const RestorableGremlinGraphsListResult: coreClient.CompositeMapper = { +export const RestorableTableResourcesListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinGraphsListResult", + className: "RestorableTableResourcesListResult", modelProperties: { value: { serializedName: "value", @@ -6378,7 +5702,7 @@ export const RestorableGremlinGraphsListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "RestorableGremlinGraphGetResult" + className: "RestorableTableResourcesGetResult" } } } @@ -6387,10 +5711,10 @@ export const RestorableGremlinGraphsListResult: coreClient.CompositeMapper = { } }; -export const RestorableGremlinGraphGetResult: coreClient.CompositeMapper = { +export const RestorableTableResourcesGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinGraphGetResult", + className: "RestorableTableResourcesGetResult", modelProperties: { id: { serializedName: "id", @@ -6412,226 +5736,155 @@ export const RestorableGremlinGraphGetResult: coreClient.CompositeMapper = { type: { name: "String" } - }, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "RestorableGremlinGraphPropertiesResource" - } } } } }; -export const RestorableGremlinGraphPropertiesResource: coreClient.CompositeMapper = { +export const ServiceResourceListResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableGremlinGraphPropertiesResource", + className: "ServiceResourceListResult", modelProperties: { - rid: { - serializedName: "_rid", - readOnly: true, - type: { - name: "String" - } - }, - operationType: { - serializedName: "operationType", + value: { + serializedName: "value", readOnly: true, type: { - name: "String" - } - }, - eventTimestamp: { - serializedName: "eventTimestamp", - readOnly: true, - type: { - name: "String" - } - }, - ownerId: { - serializedName: "ownerId", - readOnly: true, - type: { - name: "String" - } - }, - ownerResourceId: { - serializedName: "ownerResourceId", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const RestorableGremlinResourcesListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestorableGremlinResourcesListResult", - modelProperties: { - value: { - serializedName: "value", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "RestorableGremlinResourcesGetResult" - } - } + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ServiceResource" + } + } } } } } }; -export const RestorableGremlinResourcesGetResult: coreClient.CompositeMapper = { +export const ServiceResourceProperties: coreClient.CompositeMapper = { + serializedName: "ServiceResourceProperties", type: { name: "Composite", - className: "RestorableGremlinResourcesGetResult", + className: "ServiceResourceProperties", + uberParent: "ServiceResourceProperties", + additionalProperties: { type: { name: "Object" } }, + polymorphicDiscriminator: { + serializedName: "serviceType", + clientName: "serviceType" + }, modelProperties: { - id: { - serializedName: "id", + creationTime: { + serializedName: "creationTime", readOnly: true, type: { - name: "String" + name: "DateTime" } }, - name: { - serializedName: "name", - readOnly: true, + instanceSize: { + serializedName: "instanceSize", type: { name: "String" } }, - type: { - serializedName: "type", - readOnly: true, + instanceCount: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "instanceCount", type: { - name: "String" + name: "Number" } }, - databaseName: { - serializedName: "databaseName", + serviceType: { + serializedName: "serviceType", + required: true, type: { name: "String" } }, - graphNames: { - serializedName: "graphNames", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } -}; - -export const RestorableTablesListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestorableTablesListResult", - modelProperties: { - value: { - serializedName: "value", + status: { + serializedName: "status", readOnly: true, type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "RestorableTableGetResult" - } - } + name: "String" } } } } }; -export const RestorableTableGetResult: coreClient.CompositeMapper = { +export const ServiceResourceCreateUpdateParameters: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableTableGetResult", + className: "ServiceResourceCreateUpdateParameters", modelProperties: { - id: { - serializedName: "id", - readOnly: true, + instanceSize: { + serializedName: "properties.instanceSize", type: { name: "String" } }, - name: { - serializedName: "name", - readOnly: true, + instanceCount: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "properties.instanceCount", type: { - name: "String" + name: "Number" } }, - type: { - serializedName: "type", - readOnly: true, + serviceType: { + serializedName: "properties.serviceType", type: { name: "String" } - }, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "RestorableTablePropertiesResource" - } } } } }; -export const RestorableTablePropertiesResource: coreClient.CompositeMapper = { +export const PeriodicModeProperties: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableTablePropertiesResource", + className: "PeriodicModeProperties", modelProperties: { - rid: { - serializedName: "_rid", - readOnly: true, - type: { - name: "String" - } - }, - operationType: { - serializedName: "operationType", - readOnly: true, + backupIntervalInMinutes: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "backupIntervalInMinutes", type: { - name: "String" + name: "Number" } }, - eventTimestamp: { - serializedName: "eventTimestamp", - readOnly: true, + backupRetentionIntervalInHours: { + constraints: { + InclusiveMinimum: 0 + }, + serializedName: "backupRetentionIntervalInHours", type: { - name: "String" + name: "Number" } }, - ownerId: { - serializedName: "ownerId", - readOnly: true, + backupStorageRedundancy: { + serializedName: "backupStorageRedundancy", type: { name: "String" } - }, - ownerResourceId: { - serializedName: "ownerResourceId", - readOnly: true, + } + } + } +}; + +export const ContinuousModeProperties: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ContinuousModeProperties", + modelProperties: { + tier: { + serializedName: "tier", type: { name: "String" } @@ -6640,49 +5893,43 @@ export const RestorableTablePropertiesResource: coreClient.CompositeMapper = { } }; -export const RestorableTableResourcesListResult: coreClient.CompositeMapper = { +export const DataTransferServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableTableResourcesListResult", + className: "DataTransferServiceResource", modelProperties: { - value: { - serializedName: "value", - readOnly: true, + properties: { + serializedName: "properties", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "RestorableTableResourcesGetResult" - } - } + name: "Composite", + className: "DataTransferServiceResourceProperties" } } } } }; -export const RestorableTableResourcesGetResult: coreClient.CompositeMapper = { +export const RegionalServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "RestorableTableResourcesGetResult", + className: "RegionalServiceResource", modelProperties: { - id: { - serializedName: "id", + name: { + serializedName: "name", readOnly: true, type: { name: "String" } }, - name: { - serializedName: "name", + location: { + serializedName: "location", readOnly: true, type: { name: "String" } }, - type: { - serializedName: "type", + status: { + serializedName: "status", readOnly: true, type: { name: "String" @@ -6692,224 +5939,26 @@ export const RestorableTableResourcesGetResult: coreClient.CompositeMapper = { } }; -export const ServiceResourceListResult: coreClient.CompositeMapper = { +export const SqlDedicatedGatewayServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ServiceResourceListResult", + className: "SqlDedicatedGatewayServiceResource", modelProperties: { - value: { - serializedName: "value", - readOnly: true, + properties: { + serializedName: "properties", type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "ServiceResource" - } - } + name: "Composite", + className: "SqlDedicatedGatewayServiceResourceProperties" } } } } }; -export const ServiceResourceProperties: coreClient.CompositeMapper = { - serializedName: "ServiceResourceProperties", +export const GraphAPIComputeServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ServiceResourceProperties", - uberParent: "ServiceResourceProperties", - additionalProperties: { type: { name: "Object" } }, - polymorphicDiscriminator: { - serializedName: "serviceType", - clientName: "serviceType" - }, - modelProperties: { - creationTime: { - serializedName: "creationTime", - readOnly: true, - type: { - name: "DateTime" - } - }, - instanceSize: { - serializedName: "instanceSize", - type: { - name: "String" - } - }, - instanceCount: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "instanceCount", - type: { - name: "Number" - } - }, - serviceType: { - serializedName: "serviceType", - required: true, - type: { - name: "String" - } - }, - status: { - serializedName: "status", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const ServiceResourceCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ServiceResourceCreateUpdateParameters", - modelProperties: { - instanceSize: { - serializedName: "properties.instanceSize", - type: { - name: "String" - } - }, - instanceCount: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "properties.instanceCount", - type: { - name: "Number" - } - }, - serviceType: { - serializedName: "properties.serviceType", - type: { - name: "String" - } - } - } - } -}; - -export const PeriodicModeProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PeriodicModeProperties", - modelProperties: { - backupIntervalInMinutes: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "backupIntervalInMinutes", - type: { - name: "Number" - } - }, - backupRetentionIntervalInHours: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "backupRetentionIntervalInHours", - type: { - name: "Number" - } - }, - backupStorageRedundancy: { - serializedName: "backupStorageRedundancy", - type: { - name: "String" - } - } - } - } -}; - -export const ContinuousModeProperties: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContinuousModeProperties", - modelProperties: { - tier: { - serializedName: "tier", - type: { - name: "String" - } - } - } - } -}; - -export const DataTransferServiceResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataTransferServiceResource", - modelProperties: { - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "DataTransferServiceResourceProperties" - } - } - } - } -}; - -export const RegionalServiceResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RegionalServiceResource", - modelProperties: { - name: { - serializedName: "name", - readOnly: true, - type: { - name: "String" - } - }, - location: { - serializedName: "location", - readOnly: true, - type: { - name: "String" - } - }, - status: { - serializedName: "status", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const SqlDedicatedGatewayServiceResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlDedicatedGatewayServiceResource", - modelProperties: { - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "SqlDedicatedGatewayServiceResourceProperties" - } - } - } - } -}; - -export const GraphAPIComputeServiceResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "GraphAPIComputeServiceResource", + className: "GraphAPIComputeServiceResource", modelProperties: { properties: { serializedName: "properties", @@ -6948,73 +5997,6 @@ export const ProxyResource: coreClient.CompositeMapper = { } }; -export const RestoreParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestoreParameters", - modelProperties: { - ...RestoreParametersBase.type.modelProperties, - restoreMode: { - serializedName: "restoreMode", - type: { - name: "String" - } - }, - databasesToRestore: { - serializedName: "databasesToRestore", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DatabaseRestoreResource" - } - } - } - }, - gremlinDatabasesToRestore: { - serializedName: "gremlinDatabasesToRestore", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "GremlinDatabaseRestoreResource" - } - } - } - }, - tablesToRestore: { - serializedName: "tablesToRestore", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - sourceBackupLocation: { - serializedName: "sourceBackupLocation", - type: { - name: "String" - } - } - } - } -}; - -export const ResourceRestoreParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ResourceRestoreParameters", - modelProperties: { - ...RestoreParametersBase.type.modelProperties - } - } -}; - export const PeriodicModeBackupPolicy: coreClient.CompositeMapper = { serializedName: "Periodic", type: { @@ -7067,6 +6049,13 @@ export const DatabaseAccountGetResults: coreClient.CompositeMapper = { name: "String" } }, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ManagedServiceIdentity" + } + }, systemData: { serializedName: "systemData", type: { @@ -7292,6 +6281,7 @@ export const DatabaseAccountGetResults: coreClient.CompositeMapper = { } }, createMode: { + defaultValue: "Default", serializedName: "properties.createMode", type: { name: "String" @@ -7341,13 +6331,6 @@ export const DatabaseAccountGetResults: coreClient.CompositeMapper = { } } }, - diagnosticLogSettings: { - serializedName: "properties.diagnosticLogSettings", - type: { - name: "Composite", - className: "DiagnosticLogSettings" - } - }, disableLocalAuth: { serializedName: "properties.disableLocalAuth", type: { @@ -7361,14 +6344,8 @@ export const DatabaseAccountGetResults: coreClient.CompositeMapper = { className: "Capacity" } }, - enableMaterializedViews: { - serializedName: "properties.enableMaterializedViews", - type: { - name: "Boolean" - } - }, - keysMetadata: { - serializedName: "properties.keysMetadata", + keysMetadata: { + serializedName: "properties.keysMetadata", type: { name: "Composite", className: "DatabaseAccountKeysMetadata" @@ -7380,14 +6357,20 @@ export const DatabaseAccountGetResults: coreClient.CompositeMapper = { name: "Boolean" } }, + minimalTlsVersion: { + serializedName: "properties.minimalTlsVersion", + type: { + name: "String" + } + }, enableBurstCapacity: { serializedName: "properties.enableBurstCapacity", type: { name: "Boolean" } }, - minimalTlsVersion: { - serializedName: "properties.minimalTlsVersion", + customerManagedKeyStatus: { + serializedName: "properties.customerManagedKeyStatus", type: { name: "String" } @@ -7408,6 +6391,13 @@ export const DatabaseAccountCreateUpdateParameters: coreClient.CompositeMapper = name: "String" } }, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ManagedServiceIdentity" + } + }, consistencyPolicy: { serializedName: "properties.consistencyPolicy", type: { @@ -7553,6 +6543,7 @@ export const DatabaseAccountCreateUpdateParameters: coreClient.CompositeMapper = } }, createMode: { + defaultValue: "Default", serializedName: "properties.createMode", type: { name: "String" @@ -7595,13 +6586,6 @@ export const DatabaseAccountCreateUpdateParameters: coreClient.CompositeMapper = } } }, - diagnosticLogSettings: { - serializedName: "properties.diagnosticLogSettings", - type: { - name: "Composite", - className: "DiagnosticLogSettings" - } - }, disableLocalAuth: { serializedName: "properties.disableLocalAuth", type: { @@ -7622,12 +6606,6 @@ export const DatabaseAccountCreateUpdateParameters: coreClient.CompositeMapper = className: "Capacity" } }, - enableMaterializedViews: { - serializedName: "properties.enableMaterializedViews", - type: { - name: "Boolean" - } - }, keysMetadata: { serializedName: "properties.keysMetadata", type: { @@ -7641,64 +6619,22 @@ export const DatabaseAccountCreateUpdateParameters: coreClient.CompositeMapper = name: "Boolean" } }, - enableBurstCapacity: { - serializedName: "properties.enableBurstCapacity", - type: { - name: "Boolean" - } - }, minimalTlsVersion: { serializedName: "properties.minimalTlsVersion", type: { name: "String" } - } - } - } -}; - -export const GraphResourceGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "GraphResourceGetResults", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "GraphResourceGetPropertiesResource" - } }, - options: { - serializedName: "properties.options", - type: { - name: "Composite", - className: "GraphResourceGetPropertiesOptions" - } - } - } - } -}; - -export const GraphResourceCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "GraphResourceCreateUpdateParameters", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", + enableBurstCapacity: { + serializedName: "properties.enableBurstCapacity", type: { - name: "Composite", - className: "GraphResource" + name: "Boolean" } }, - options: { - serializedName: "properties.options", + customerManagedKeyStatus: { + serializedName: "properties.customerManagedKeyStatus", type: { - name: "Composite", - className: "CreateUpdateOptions" + name: "String" } } } @@ -7835,57 +6771,6 @@ export const SqlContainerCreateUpdateParameters: coreClient.CompositeMapper = { } }; -export const RetrieveThroughputParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RetrieveThroughputParameters", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "RetrieveThroughputPropertiesResource" - } - } - } - } -}; - -export const PhysicalPartitionThroughputInfoResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResult", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResultPropertiesResource" - } - } - } - } -}; - -export const RedistributeThroughputParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RedistributeThroughputParameters", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "RedistributeThroughputPropertiesResource" - } - } - } - } -}; - export const SqlStoredProcedureGetResults: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8345,54 +7230,6 @@ export const GremlinGraphCreateUpdateParameters: coreClient.CompositeMapper = { } }; -export const CassandraViewGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraViewGetResults", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "CassandraViewGetPropertiesResource" - } - }, - options: { - serializedName: "properties.options", - type: { - name: "Composite", - className: "CassandraViewGetPropertiesOptions" - } - } - } - } -}; - -export const CassandraViewCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraViewCreateUpdateParameters", - modelProperties: { - ...ARMResourceProperties.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "CassandraViewResource" - } - }, - options: { - serializedName: "properties.options", - type: { - name: "Composite", - className: "CreateUpdateOptions" - } - } - } - } -}; - export const DatabaseAccountListKeysResult: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8524,265 +7361,145 @@ export const PartitionUsage: coreClient.CompositeMapper = { } }; -export const GraphResourceGetPropertiesResource: coreClient.CompositeMapper = { +export const SqlDatabaseGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GraphResourceGetPropertiesResource", + className: "SqlDatabaseGetPropertiesResource", modelProperties: { - ...GraphResource.type.modelProperties + ...SqlDatabaseResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties, + colls: { + serializedName: "_colls", + type: { + name: "String" + } + }, + users: { + serializedName: "_users", + type: { + name: "String" + } + } } } }; -export const GraphResourceGetPropertiesOptions: coreClient.CompositeMapper = { +export const RestorableSqlDatabasePropertiesResourceDatabase: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GraphResourceGetPropertiesOptions", + className: "RestorableSqlDatabasePropertiesResourceDatabase", modelProperties: { - ...OptionsResource.type.modelProperties + ...SqlDatabaseResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties, + colls: { + serializedName: "_colls", + readOnly: true, + type: { + name: "String" + } + }, + users: { + serializedName: "_users", + readOnly: true, + type: { + name: "String" + } + }, + self: { + serializedName: "_self", + readOnly: true, + type: { + name: "String" + } + } } } }; -export const SqlDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { +export const ThroughputSettingsGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlDatabaseGetPropertiesOptions", + className: "ThroughputSettingsGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...ThroughputSettingsResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const SqlContainerGetPropertiesOptions: coreClient.CompositeMapper = { +export const SqlContainerGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlContainerGetPropertiesOptions", + className: "SqlContainerGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...SqlContainerResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const MongoDBDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { +export const ClientEncryptionKeyGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBDatabaseGetPropertiesOptions", + className: "ClientEncryptionKeyGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...ClientEncryptionKeyResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const MongoDBCollectionGetPropertiesOptions: coreClient.CompositeMapper = { +export const SqlStoredProcedureGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBCollectionGetPropertiesOptions", + className: "SqlStoredProcedureGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...SqlStoredProcedureResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const TableGetPropertiesOptions: coreClient.CompositeMapper = { +export const SqlUserDefinedFunctionGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TableGetPropertiesOptions", + className: "SqlUserDefinedFunctionGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...SqlUserDefinedFunctionResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const CassandraKeyspaceGetPropertiesOptions: coreClient.CompositeMapper = { +export const SqlTriggerGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CassandraKeyspaceGetPropertiesOptions", + className: "SqlTriggerGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...SqlTriggerResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const CassandraTableGetPropertiesOptions: coreClient.CompositeMapper = { +export const MongoDBDatabaseGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CassandraTableGetPropertiesOptions", + className: "MongoDBDatabaseGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties + ...MongoDBDatabaseResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; -export const GremlinDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { +export const MongoDBCollectionGetPropertiesResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GremlinDatabaseGetPropertiesOptions", + className: "MongoDBCollectionGetPropertiesResource", modelProperties: { - ...OptionsResource.type.modelProperties - } - } -}; - -export const GremlinGraphGetPropertiesOptions: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "GremlinGraphGetPropertiesOptions", - modelProperties: { - ...OptionsResource.type.modelProperties - } - } -}; - -export const CassandraViewGetPropertiesOptions: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraViewGetPropertiesOptions", - modelProperties: { - ...OptionsResource.type.modelProperties - } - } -}; - -export const SqlDatabaseGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlDatabaseGetPropertiesResource", - modelProperties: { - ...SqlDatabaseResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties, - colls: { - serializedName: "_colls", - type: { - name: "String" - } - }, - users: { - serializedName: "_users", - type: { - name: "String" - } - } - } - } -}; - -export const RestorableSqlDatabasePropertiesResourceDatabase: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "RestorableSqlDatabasePropertiesResourceDatabase", - modelProperties: { - ...SqlDatabaseResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties, - colls: { - serializedName: "_colls", - readOnly: true, - type: { - name: "String" - } - }, - users: { - serializedName: "_users", - readOnly: true, - type: { - name: "String" - } - }, - self: { - serializedName: "_self", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const ThroughputSettingsGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ThroughputSettingsGetPropertiesResource", - modelProperties: { - ...ThroughputSettingsResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const ClientEncryptionKeyGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClientEncryptionKeyGetPropertiesResource", - modelProperties: { - ...ClientEncryptionKeyResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const SqlContainerGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlContainerGetPropertiesResource", - modelProperties: { - ...SqlContainerResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const SqlStoredProcedureGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlStoredProcedureGetPropertiesResource", - modelProperties: { - ...SqlStoredProcedureResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const SqlUserDefinedFunctionGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlUserDefinedFunctionGetPropertiesResource", - modelProperties: { - ...SqlUserDefinedFunctionResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const SqlTriggerGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlTriggerGetPropertiesResource", - modelProperties: { - ...SqlTriggerResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const MongoDBDatabaseGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoDBDatabaseGetPropertiesResource", - modelProperties: { - ...MongoDBDatabaseResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - -export const MongoDBCollectionGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoDBCollectionGetPropertiesResource", - modelProperties: { - ...MongoDBCollectionResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties + ...MongoDBCollectionResource.type.modelProperties, + ...ExtendedResourceProperties.type.modelProperties } } }; @@ -8842,17 +7559,6 @@ export const GremlinGraphGetPropertiesResource: coreClient.CompositeMapper = { } }; -export const CassandraViewGetPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraViewGetPropertiesResource", - modelProperties: { - ...CassandraViewResource.type.modelProperties, - ...ExtendedResourceProperties.type.modelProperties - } - } -}; - export const RestorableSqlContainerPropertiesResourceContainer: coreClient.CompositeMapper = { type: { name: "Composite", @@ -8871,921 +7577,319 @@ export const RestorableSqlContainerPropertiesResourceContainer: coreClient.Compo } }; -export const ClientEncryptionKeyGetResults: coreClient.CompositeMapper = { +export const SqlDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ClientEncryptionKeyGetResults", + className: "SqlDatabaseGetPropertiesOptions", modelProperties: { - ...ARMProxyResource.type.modelProperties, - resource: { - serializedName: "properties.resource", - type: { - name: "Composite", - className: "ClientEncryptionKeyGetPropertiesResource" - } - } + ...OptionsResource.type.modelProperties } } }; -export const LocationGetResult: coreClient.CompositeMapper = { +export const SqlContainerGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "LocationGetResult", + className: "SqlContainerGetPropertiesOptions", modelProperties: { - ...ARMProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "LocationProperties" - } - } + ...OptionsResource.type.modelProperties } } }; -export const CreateJobRequest: coreClient.CompositeMapper = { +export const MongoDBDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "CreateJobRequest", + className: "MongoDBDatabaseGetPropertiesOptions", modelProperties: { - ...ARMProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "DataTransferJobProperties" - } - } + ...OptionsResource.type.modelProperties } } }; -export const DataTransferJobGetResults: coreClient.CompositeMapper = { +export const MongoDBCollectionGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DataTransferJobGetResults", + className: "MongoDBCollectionGetPropertiesOptions", modelProperties: { - ...ARMProxyResource.type.modelProperties, - jobName: { - serializedName: "properties.jobName", - readOnly: true, - type: { - name: "String" - } - }, - source: { - serializedName: "properties.source", - type: { - name: "Composite", - className: "DataTransferDataSourceSink" - } - }, - destination: { - serializedName: "properties.destination", - type: { - name: "Composite", - className: "DataTransferDataSourceSink" - } - }, - status: { - serializedName: "properties.status", - readOnly: true, - type: { - name: "String" - } - }, - processedCount: { - serializedName: "properties.processedCount", - readOnly: true, - type: { - name: "Number" - } - }, - totalCount: { - serializedName: "properties.totalCount", - readOnly: true, - type: { - name: "Number" - } - }, - lastUpdatedUtcTime: { - serializedName: "properties.lastUpdatedUtcTime", - readOnly: true, - type: { - name: "DateTime" - } - }, - workerCount: { - constraints: { - InclusiveMinimum: 0 - }, - serializedName: "properties.workerCount", - type: { - name: "Number" - } - }, - error: { - serializedName: "properties.error", - type: { - name: "Composite", - className: "ErrorResponse" - } - } + ...OptionsResource.type.modelProperties } } }; -export const BackupResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "BackupResource", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "BackupResourceProperties" - } - } - } - } -}; - -export const DataCenterResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DataCenterResource", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "DataCenterResourceProperties" - } - } - } - } -}; - -export const MongoRoleDefinitionGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoRoleDefinitionGetResults", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - roleName: { - serializedName: "properties.roleName", - type: { - name: "String" - } - }, - typePropertiesType: { - serializedName: "properties.type", - type: { - name: "Enum", - allowedValues: ["BuiltInRole", "CustomRole"] - } - }, - databaseName: { - serializedName: "properties.databaseName", - type: { - name: "String" - } - }, - privileges: { - serializedName: "properties.privileges", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Privilege" - } - } - } - }, - roles: { - serializedName: "properties.roles", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Role" - } - } - } - } - } - } -}; - -export const MongoUserDefinitionGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoUserDefinitionGetResults", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - userName: { - serializedName: "properties.userName", - type: { - name: "String" - } - }, - password: { - serializedName: "properties.password", - type: { - name: "String" - } - }, - databaseName: { - serializedName: "properties.databaseName", - type: { - name: "String" - } - }, - customData: { - serializedName: "properties.customData", - type: { - name: "String" - } - }, - roles: { - serializedName: "properties.roles", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Role" - } - } - } - }, - mechanisms: { - serializedName: "properties.mechanisms", - type: { - name: "String" - } - } - } - } -}; - -export const NotebookWorkspace: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "NotebookWorkspace", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - notebookServerEndpoint: { - serializedName: "properties.notebookServerEndpoint", - readOnly: true, - type: { - name: "String" - } - }, - status: { - serializedName: "properties.status", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - -export const NotebookWorkspaceCreateUpdateParameters: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "NotebookWorkspaceCreateUpdateParameters", - modelProperties: { - ...ARMProxyResource.type.modelProperties - } - } -}; - -export const PrivateLinkResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PrivateLinkResource", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - groupId: { - serializedName: "properties.groupId", - readOnly: true, - type: { - name: "String" - } - }, - requiredMembers: { - serializedName: "properties.requiredMembers", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - requiredZoneNames: { - serializedName: "properties.requiredZoneNames", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } -}; - -export const SqlRoleDefinitionGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlRoleDefinitionGetResults", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - roleName: { - serializedName: "properties.roleName", - type: { - name: "String" - } - }, - typePropertiesType: { - serializedName: "properties.type", - type: { - name: "Enum", - allowedValues: ["BuiltInRole", "CustomRole"] - } - }, - assignableScopes: { - serializedName: "properties.assignableScopes", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - }, - permissions: { - serializedName: "properties.permissions", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Permission" - } - } - } - } - } - } -}; - -export const SqlRoleAssignmentGetResults: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlRoleAssignmentGetResults", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - roleDefinitionId: { - serializedName: "properties.roleDefinitionId", - type: { - name: "String" - } - }, - scope: { - serializedName: "properties.scope", - type: { - name: "String" - } - }, - principalId: { - serializedName: "properties.principalId", - type: { - name: "String" - } - } - } - } -}; - -export const ServiceResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ServiceResource", - modelProperties: { - ...ARMProxyResource.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "ServiceResourceProperties" - } - } - } - } -}; - -export const PhysicalPartitionThroughputInfoResultPropertiesResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "PhysicalPartitionThroughputInfoResultPropertiesResource", - modelProperties: { - ...PhysicalPartitionThroughputInfoProperties.type.modelProperties - } - } -}; - -export const CosmosCassandraDataTransferDataSourceSink: coreClient.CompositeMapper = { - serializedName: "CosmosDBCassandra", - type: { - name: "Composite", - className: "CosmosCassandraDataTransferDataSourceSink", - uberParent: "DataTransferDataSourceSink", - polymorphicDiscriminator: - DataTransferDataSourceSink.type.polymorphicDiscriminator, - modelProperties: { - ...DataTransferDataSourceSink.type.modelProperties, - keyspaceName: { - serializedName: "keyspaceName", - required: true, - type: { - name: "String" - } - }, - tableName: { - serializedName: "tableName", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const CosmosMongoDataTransferDataSourceSink: coreClient.CompositeMapper = { - serializedName: "CosmosDBMongo", - type: { - name: "Composite", - className: "CosmosMongoDataTransferDataSourceSink", - uberParent: "DataTransferDataSourceSink", - polymorphicDiscriminator: - DataTransferDataSourceSink.type.polymorphicDiscriminator, - modelProperties: { - ...DataTransferDataSourceSink.type.modelProperties, - databaseName: { - serializedName: "databaseName", - required: true, - type: { - name: "String" - } - }, - collectionName: { - serializedName: "collectionName", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const CosmosSqlDataTransferDataSourceSink: coreClient.CompositeMapper = { - serializedName: "CosmosDBSql", - type: { - name: "Composite", - className: "CosmosSqlDataTransferDataSourceSink", - uberParent: "DataTransferDataSourceSink", - polymorphicDiscriminator: - DataTransferDataSourceSink.type.polymorphicDiscriminator, - modelProperties: { - ...DataTransferDataSourceSink.type.modelProperties, - databaseName: { - serializedName: "databaseName", - required: true, - type: { - name: "String" - } - }, - containerName: { - serializedName: "containerName", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const AzureBlobDataTransferDataSourceSink: coreClient.CompositeMapper = { - serializedName: "AzureBlobStorage", - type: { - name: "Composite", - className: "AzureBlobDataTransferDataSourceSink", - uberParent: "DataTransferDataSourceSink", - polymorphicDiscriminator: - DataTransferDataSourceSink.type.polymorphicDiscriminator, - modelProperties: { - ...DataTransferDataSourceSink.type.modelProperties, - containerName: { - serializedName: "containerName", - required: true, - type: { - name: "String" - } - }, - endpointUrl: { - serializedName: "endpointUrl", - type: { - name: "String" - } - } - } - } -}; - -export const ClusterResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ClusterResource", - modelProperties: { - ...ManagedCassandraARMResourceProperties.type.modelProperties, - properties: { - serializedName: "properties", - type: { - name: "Composite", - className: "ClusterResourceProperties" - } - } - } - } -}; - -export const NodeGroupSpec: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "NodeGroupSpec", - modelProperties: { - ...NodeGroupProperties.type.modelProperties, - kind: { - serializedName: "kind", - type: { - name: "String" - } - }, - nodeCount: { - serializedName: "nodeCount", - type: { - name: "Number" - } - } - } - } -}; - -export const TrackedResource: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "TrackedResource", - modelProperties: { - ...ResourceAutoGenerated.type.modelProperties, - tags: { - serializedName: "tags", - type: { - name: "Dictionary", - value: { type: { name: "String" } } - } - }, - location: { - serializedName: "location", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const ProxyResourceAutoGenerated: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ProxyResourceAutoGenerated", - modelProperties: { - ...ResourceAutoGenerated.type.modelProperties - } - } -}; - -export const DataTransferServiceResourceProperties: coreClient.CompositeMapper = { - serializedName: "DataTransfer", - type: { - name: "Composite", - className: "DataTransferServiceResourceProperties", - uberParent: "ServiceResourceProperties", - additionalProperties: { type: { name: "Object" } }, - polymorphicDiscriminator: - ServiceResourceProperties.type.polymorphicDiscriminator, - modelProperties: { - ...ServiceResourceProperties.type.modelProperties, - locations: { - serializedName: "locations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "DataTransferRegionalServiceResource" - } - } - } - } - } - } -}; - -export const SqlDedicatedGatewayServiceResourceProperties: coreClient.CompositeMapper = { - serializedName: "SqlDedicatedGateway", +export const TableGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlDedicatedGatewayServiceResourceProperties", - uberParent: "ServiceResourceProperties", - additionalProperties: { type: { name: "Object" } }, - polymorphicDiscriminator: - ServiceResourceProperties.type.polymorphicDiscriminator, + className: "TableGetPropertiesOptions", modelProperties: { - ...ServiceResourceProperties.type.modelProperties, - sqlDedicatedGatewayEndpoint: { - serializedName: "sqlDedicatedGatewayEndpoint", - type: { - name: "String" - } - }, - locations: { - serializedName: "locations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SqlDedicatedGatewayRegionalServiceResource" - } - } - } - } + ...OptionsResource.type.modelProperties } - } -}; - -export const GraphAPIComputeServiceResourceProperties: coreClient.CompositeMapper = { - serializedName: "GraphAPICompute", - type: { - name: "Composite", - className: "GraphAPIComputeServiceResourceProperties", - uberParent: "ServiceResourceProperties", - additionalProperties: { type: { name: "Object" } }, - polymorphicDiscriminator: - ServiceResourceProperties.type.polymorphicDiscriminator, - modelProperties: { - ...ServiceResourceProperties.type.modelProperties, - graphApiComputeEndpoint: { - serializedName: "graphApiComputeEndpoint", - type: { - name: "String" - } - }, - locations: { - serializedName: "locations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "GraphAPIComputeRegionalServiceResource" - } - } - } - } + } +}; + +export const CassandraKeyspaceGetPropertiesOptions: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "CassandraKeyspaceGetPropertiesOptions", + modelProperties: { + ...OptionsResource.type.modelProperties } } }; -export const MaterializedViewsBuilderServiceResourceProperties: coreClient.CompositeMapper = { - serializedName: "MaterializedViewsBuilder", +export const CassandraTableGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MaterializedViewsBuilderServiceResourceProperties", - uberParent: "ServiceResourceProperties", - additionalProperties: { type: { name: "Object" } }, - polymorphicDiscriminator: - ServiceResourceProperties.type.polymorphicDiscriminator, + className: "CassandraTableGetPropertiesOptions", modelProperties: { - ...ServiceResourceProperties.type.modelProperties, - locations: { - serializedName: "locations", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "MaterializedViewsBuilderRegionalServiceResource" - } - } - } - } + ...OptionsResource.type.modelProperties } } }; -export const DataTransferRegionalServiceResource: coreClient.CompositeMapper = { +export const GremlinDatabaseGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DataTransferRegionalServiceResource", + className: "GremlinDatabaseGetPropertiesOptions", modelProperties: { - ...RegionalServiceResource.type.modelProperties + ...OptionsResource.type.modelProperties } } }; -export const SqlDedicatedGatewayRegionalServiceResource: coreClient.CompositeMapper = { +export const GremlinGraphGetPropertiesOptions: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlDedicatedGatewayRegionalServiceResource", + className: "GremlinGraphGetPropertiesOptions", modelProperties: { - ...RegionalServiceResource.type.modelProperties, - sqlDedicatedGatewayEndpoint: { - serializedName: "sqlDedicatedGatewayEndpoint", - readOnly: true, + ...OptionsResource.type.modelProperties + } + } +}; + +export const ClientEncryptionKeyGetResults: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ClientEncryptionKeyGetResults", + modelProperties: { + ...ARMProxyResource.type.modelProperties, + resource: { + serializedName: "properties.resource", type: { - name: "String" + name: "Composite", + className: "ClientEncryptionKeyGetPropertiesResource" } } } } }; -export const GraphAPIComputeRegionalServiceResource: coreClient.CompositeMapper = { +export const LocationGetResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "GraphAPIComputeRegionalServiceResource", + className: "LocationGetResult", modelProperties: { - ...RegionalServiceResource.type.modelProperties, - graphApiComputeEndpoint: { - serializedName: "graphApiComputeEndpoint", - readOnly: true, + ...ARMProxyResource.type.modelProperties, + properties: { + serializedName: "properties", type: { - name: "String" + name: "Composite", + className: "LocationProperties" } } } } }; -export const MaterializedViewsBuilderRegionalServiceResource: coreClient.CompositeMapper = { +export const DataCenterResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MaterializedViewsBuilderRegionalServiceResource", + className: "DataCenterResource", modelProperties: { - ...RegionalServiceResource.type.modelProperties + ...ARMProxyResource.type.modelProperties, + properties: { + serializedName: "properties", + type: { + name: "Composite", + className: "DataCenterResourceProperties" + } + } } } }; -export const PrivateEndpointConnection: coreClient.CompositeMapper = { +export const MongoRoleDefinitionGetResults: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateEndpointConnection", + className: "MongoRoleDefinitionGetResults", modelProperties: { - ...ProxyResource.type.modelProperties, - privateEndpoint: { - serializedName: "properties.privateEndpoint", + ...ARMProxyResource.type.modelProperties, + roleName: { + serializedName: "properties.roleName", type: { - name: "Composite", - className: "PrivateEndpointProperty" + name: "String" } }, - privateLinkServiceConnectionState: { - serializedName: "properties.privateLinkServiceConnectionState", + typePropertiesType: { + serializedName: "properties.type", type: { - name: "Composite", - className: "PrivateLinkServiceConnectionStateProperty" + name: "Enum", + allowedValues: ["BuiltInRole", "CustomRole"] } }, - groupId: { - serializedName: "properties.groupId", + databaseName: { + serializedName: "properties.databaseName", type: { name: "String" } }, - provisioningState: { - serializedName: "properties.provisioningState", + privileges: { + serializedName: "properties.privileges", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Privilege" + } + } + } + }, + roles: { + serializedName: "properties.roles", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Role" + } + } } } } } }; -export const MongoCluster: coreClient.CompositeMapper = { +export const MongoUserDefinitionGetResults: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoCluster", + className: "MongoUserDefinitionGetResults", modelProperties: { - ...TrackedResource.type.modelProperties, - createMode: { - serializedName: "properties.createMode", + ...ARMProxyResource.type.modelProperties, + userName: { + serializedName: "properties.userName", type: { name: "String" } }, - restoreParameters: { - serializedName: "properties.restoreParameters", + password: { + serializedName: "properties.password", type: { - name: "Composite", - className: "MongoClusterRestoreParameters" + name: "String" } }, - administratorLogin: { - serializedName: "properties.administratorLogin", + databaseName: { + serializedName: "properties.databaseName", type: { name: "String" } }, - administratorLoginPassword: { - serializedName: "properties.administratorLoginPassword", + customData: { + serializedName: "properties.customData", type: { name: "String" } }, - serverVersion: { - serializedName: "properties.serverVersion", + roles: { + serializedName: "properties.roles", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Role" + } + } } }, - connectionString: { - serializedName: "properties.connectionString", + mechanisms: { + serializedName: "properties.mechanisms", + type: { + name: "String" + } + } + } + } +}; + +export const NotebookWorkspace: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "NotebookWorkspace", + modelProperties: { + ...ARMProxyResource.type.modelProperties, + notebookServerEndpoint: { + serializedName: "properties.notebookServerEndpoint", readOnly: true, type: { name: "String" } }, - earliestRestoreTime: { - serializedName: "properties.earliestRestoreTime", + status: { + serializedName: "properties.status", readOnly: true, type: { name: "String" } - }, - provisioningState: { - serializedName: "properties.provisioningState", + } + } + } +}; + +export const NotebookWorkspaceCreateUpdateParameters: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "NotebookWorkspaceCreateUpdateParameters", + modelProperties: { + ...ARMProxyResource.type.modelProperties + } + } +}; + +export const PrivateLinkResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "PrivateLinkResource", + modelProperties: { + ...ARMProxyResource.type.modelProperties, + groupId: { + serializedName: "properties.groupId", readOnly: true, type: { name: "String" } }, - clusterStatus: { - serializedName: "properties.clusterStatus", + requiredMembers: { + serializedName: "properties.requiredMembers", readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - nodeGroupSpecs: { - constraints: { - MinItems: 1 - }, - serializedName: "properties.nodeGroupSpecs", + requiredZoneNames: { + serializedName: "properties.requiredZoneNames", + readOnly: true, type: { name: "Sequence", element: { type: { - name: "Composite", - className: "NodeGroupSpec" + name: "String" } } } @@ -9794,81 +7898,72 @@ export const MongoCluster: coreClient.CompositeMapper = { } }; -export const FirewallRule: coreClient.CompositeMapper = { +export const SqlRoleDefinitionGetResults: coreClient.CompositeMapper = { type: { name: "Composite", - className: "FirewallRule", + className: "SqlRoleDefinitionGetResults", modelProperties: { - ...ProxyResourceAutoGenerated.type.modelProperties, - provisioningState: { - serializedName: "properties.provisioningState", - readOnly: true, + ...ARMProxyResource.type.modelProperties, + roleName: { + serializedName: "properties.roleName", type: { name: "String" } }, - startIpAddress: { - constraints: { - Pattern: new RegExp( - "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$" - ) - }, - serializedName: "properties.startIpAddress", - required: true, + typePropertiesType: { + serializedName: "properties.type", type: { - name: "String" + name: "Enum", + allowedValues: ["BuiltInRole", "CustomRole"] + } + }, + assignableScopes: { + serializedName: "properties.assignableScopes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - endIpAddress: { - constraints: { - Pattern: new RegExp( - "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$" - ) - }, - serializedName: "properties.endIpAddress", - required: true, + permissions: { + serializedName: "properties.permissions", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Permission" + } + } } } } } }; -export const DatabaseAccountsDeleteHeaders: coreClient.CompositeMapper = { +export const SqlRoleAssignmentGetResults: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DatabaseAccountsDeleteHeaders", + className: "SqlRoleAssignmentGetResults", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + ...ARMProxyResource.type.modelProperties, + roleDefinitionId: { + serializedName: "properties.roleDefinitionId", type: { name: "String" } }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const DatabaseAccountsFailoverPriorityChangeHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "DatabaseAccountsFailoverPriorityChangeHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + scope: { + serializedName: "properties.scope", type: { name: "String" } }, - location: { - serializedName: "location", + principalId: { + serializedName: "properties.principalId", type: { name: "String" } @@ -9877,166 +7972,183 @@ export const DatabaseAccountsFailoverPriorityChangeHeaders: coreClient.Composite } }; -export const DatabaseAccountsOfflineRegionHeaders: coreClient.CompositeMapper = { +export const ServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DatabaseAccountsOfflineRegionHeaders", + className: "ServiceResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...ARMProxyResource.type.modelProperties, + properties: { + serializedName: "properties", type: { - name: "String" + name: "Composite", + className: "ServiceResourceProperties" } } } } }; -export const DatabaseAccountsOnlineRegionHeaders: coreClient.CompositeMapper = { +export const ClusterResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "DatabaseAccountsOnlineRegionHeaders", + className: "ClusterResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...ManagedCassandraARMResourceProperties.type.modelProperties, + properties: { + serializedName: "properties", type: { - name: "String" + name: "Composite", + className: "ClusterResourceProperties" } } } } }; -export const DatabaseAccountsRegenerateKeyHeaders: coreClient.CompositeMapper = { +export const DataTransferServiceResourceProperties: coreClient.CompositeMapper = { + serializedName: "DataTransfer", type: { name: "Composite", - className: "DatabaseAccountsRegenerateKeyHeaders", + className: "DataTransferServiceResourceProperties", + uberParent: "ServiceResourceProperties", + additionalProperties: { type: { name: "Object" } }, + polymorphicDiscriminator: + ServiceResourceProperties.type.polymorphicDiscriminator, modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...ServiceResourceProperties.type.modelProperties, + locations: { + serializedName: "locations", + readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DataTransferRegionalServiceResource" + } + } } } } } }; -export const GraphResourcesCreateUpdateGraphHeaders: coreClient.CompositeMapper = { +export const SqlDedicatedGatewayServiceResourceProperties: coreClient.CompositeMapper = { + serializedName: "SqlDedicatedGateway", type: { name: "Composite", - className: "GraphResourcesCreateUpdateGraphHeaders", + className: "SqlDedicatedGatewayServiceResourceProperties", + uberParent: "ServiceResourceProperties", + additionalProperties: { type: { name: "Object" } }, + polymorphicDiscriminator: + ServiceResourceProperties.type.polymorphicDiscriminator, modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + ...ServiceResourceProperties.type.modelProperties, + sqlDedicatedGatewayEndpoint: { + serializedName: "sqlDedicatedGatewayEndpoint", type: { name: "String" } }, - location: { - serializedName: "location", + locations: { + serializedName: "locations", + readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SqlDedicatedGatewayRegionalServiceResource" + } + } } } } } }; -export const GraphResourcesDeleteGraphResourceHeaders: coreClient.CompositeMapper = { +export const GraphAPIComputeServiceResourceProperties: coreClient.CompositeMapper = { + serializedName: "GraphAPICompute", type: { name: "Composite", - className: "GraphResourcesDeleteGraphResourceHeaders", + className: "GraphAPIComputeServiceResourceProperties", + uberParent: "ServiceResourceProperties", + additionalProperties: { type: { name: "Object" } }, + polymorphicDiscriminator: + ServiceResourceProperties.type.polymorphicDiscriminator, modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + ...ServiceResourceProperties.type.modelProperties, + graphApiComputeEndpoint: { + serializedName: "graphApiComputeEndpoint", type: { name: "String" } }, - location: { - serializedName: "location", + locations: { + serializedName: "locations", + readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "GraphAPIComputeRegionalServiceResource" + } + } } } } } }; -export const SqlResourcesCreateUpdateSqlDatabaseHeaders: coreClient.CompositeMapper = { +export const MaterializedViewsBuilderServiceResourceProperties: coreClient.CompositeMapper = { + serializedName: "MaterializedViewsBuilder", type: { name: "Composite", - className: "SqlResourcesCreateUpdateSqlDatabaseHeaders", + className: "MaterializedViewsBuilderServiceResourceProperties", + uberParent: "ServiceResourceProperties", + additionalProperties: { type: { name: "Object" } }, + polymorphicDiscriminator: + ServiceResourceProperties.type.polymorphicDiscriminator, modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...ServiceResourceProperties.type.modelProperties, + locations: { + serializedName: "locations", + readOnly: true, type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MaterializedViewsBuilderRegionalServiceResource" + } + } } } } } }; -export const SqlResourcesDeleteSqlDatabaseHeaders: coreClient.CompositeMapper = { +export const DataTransferRegionalServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesDeleteSqlDatabaseHeaders", + className: "DataTransferRegionalServiceResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } + ...RegionalServiceResource.type.modelProperties } } }; -export const SqlResourcesUpdateSqlDatabaseThroughputHeaders: coreClient.CompositeMapper = { +export const SqlDedicatedGatewayRegionalServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesUpdateSqlDatabaseThroughputHeaders", + className: "SqlDedicatedGatewayRegionalServiceResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...RegionalServiceResource.type.modelProperties, + sqlDedicatedGatewayEndpoint: { + serializedName: "sqlDedicatedGatewayEndpoint", + readOnly: true, type: { name: "String" } @@ -10045,19 +8157,15 @@ export const SqlResourcesUpdateSqlDatabaseThroughputHeaders: coreClient.Composit } }; -export const SqlResourcesMigrateSqlDatabaseToAutoscaleHeaders: coreClient.CompositeMapper = { +export const GraphAPIComputeRegionalServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesMigrateSqlDatabaseToAutoscaleHeaders", + className: "GraphAPIComputeRegionalServiceResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", + ...RegionalServiceResource.type.modelProperties, + graphApiComputeEndpoint: { + serializedName: "graphApiComputeEndpoint", + readOnly: true, type: { name: "String" } @@ -10066,61 +8174,44 @@ export const SqlResourcesMigrateSqlDatabaseToAutoscaleHeaders: coreClient.Compos } }; -export const SqlResourcesMigrateSqlDatabaseToManualThroughputHeaders: coreClient.CompositeMapper = { +export const MaterializedViewsBuilderRegionalServiceResource: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesMigrateSqlDatabaseToManualThroughputHeaders", + className: "MaterializedViewsBuilderRegionalServiceResource", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } + ...RegionalServiceResource.type.modelProperties } } }; -export const SqlResourcesCreateUpdateClientEncryptionKeyHeaders: coreClient.CompositeMapper = { +export const PrivateEndpointConnection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesCreateUpdateClientEncryptionKeyHeaders", + className: "PrivateEndpointConnection", modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + ...ProxyResource.type.modelProperties, + privateEndpoint: { + serializedName: "properties.privateEndpoint", type: { - name: "String" + name: "Composite", + className: "PrivateEndpointProperty" } }, - location: { - serializedName: "location", + privateLinkServiceConnectionState: { + serializedName: "properties.privateLinkServiceConnectionState", type: { - name: "String" + name: "Composite", + className: "PrivateLinkServiceConnectionStateProperty" } - } - } - } -}; - -export const SqlResourcesCreateUpdateSqlContainerHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SqlResourcesCreateUpdateSqlContainerHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", + }, + groupId: { + serializedName: "properties.groupId", type: { name: "String" } }, - location: { - serializedName: "location", + provisioningState: { + serializedName: "properties.provisioningState", type: { name: "String" } @@ -10129,10 +8220,10 @@ export const SqlResourcesCreateUpdateSqlContainerHeaders: coreClient.CompositeMa } }; -export const SqlResourcesDeleteSqlContainerHeaders: coreClient.CompositeMapper = { +export const DatabaseAccountsDeleteHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesDeleteSqlContainerHeaders", + className: "DatabaseAccountsDeleteHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10150,10 +8241,10 @@ export const SqlResourcesDeleteSqlContainerHeaders: coreClient.CompositeMapper = } }; -export const SqlResourcesSqlDatabasePartitionMergeHeaders: coreClient.CompositeMapper = { +export const DatabaseAccountsFailoverPriorityChangeHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesSqlDatabasePartitionMergeHeaders", + className: "DatabaseAccountsFailoverPriorityChangeHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10171,10 +8262,10 @@ export const SqlResourcesSqlDatabasePartitionMergeHeaders: coreClient.CompositeM } }; -export const SqlResourcesListSqlContainerPartitionMergeHeaders: coreClient.CompositeMapper = { +export const DatabaseAccountsOfflineRegionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesListSqlContainerPartitionMergeHeaders", + className: "DatabaseAccountsOfflineRegionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10192,10 +8283,10 @@ export const SqlResourcesListSqlContainerPartitionMergeHeaders: coreClient.Compo } }; -export const SqlResourcesUpdateSqlContainerThroughputHeaders: coreClient.CompositeMapper = { +export const DatabaseAccountsOnlineRegionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesUpdateSqlContainerThroughputHeaders", + className: "DatabaseAccountsOnlineRegionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10213,10 +8304,10 @@ export const SqlResourcesUpdateSqlContainerThroughputHeaders: coreClient.Composi } }; -export const SqlResourcesMigrateSqlContainerToAutoscaleHeaders: coreClient.CompositeMapper = { +export const DatabaseAccountsRegenerateKeyHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesMigrateSqlContainerToAutoscaleHeaders", + className: "DatabaseAccountsRegenerateKeyHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10234,10 +8325,10 @@ export const SqlResourcesMigrateSqlContainerToAutoscaleHeaders: coreClient.Compo } }; -export const SqlResourcesMigrateSqlContainerToManualThroughputHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateSqlDatabaseHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesMigrateSqlContainerToManualThroughputHeaders", + className: "SqlResourcesCreateUpdateSqlDatabaseHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10255,10 +8346,10 @@ export const SqlResourcesMigrateSqlContainerToManualThroughputHeaders: coreClien } }; -export const SqlResourcesSqlDatabaseRetrieveThroughputDistributionHeaders: coreClient.CompositeMapper = { +export const SqlResourcesDeleteSqlDatabaseHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesSqlDatabaseRetrieveThroughputDistributionHeaders", + className: "SqlResourcesDeleteSqlDatabaseHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10276,10 +8367,10 @@ export const SqlResourcesSqlDatabaseRetrieveThroughputDistributionHeaders: coreC } }; -export const SqlResourcesSqlDatabaseRedistributeThroughputHeaders: coreClient.CompositeMapper = { +export const SqlResourcesUpdateSqlDatabaseThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesSqlDatabaseRedistributeThroughputHeaders", + className: "SqlResourcesUpdateSqlDatabaseThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10297,10 +8388,10 @@ export const SqlResourcesSqlDatabaseRedistributeThroughputHeaders: coreClient.Co } }; -export const SqlResourcesSqlContainerRetrieveThroughputDistributionHeaders: coreClient.CompositeMapper = { +export const SqlResourcesMigrateSqlDatabaseToAutoscaleHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesSqlContainerRetrieveThroughputDistributionHeaders", + className: "SqlResourcesMigrateSqlDatabaseToAutoscaleHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10318,10 +8409,10 @@ export const SqlResourcesSqlContainerRetrieveThroughputDistributionHeaders: core } }; -export const SqlResourcesSqlContainerRedistributeThroughputHeaders: coreClient.CompositeMapper = { +export const SqlResourcesMigrateSqlDatabaseToManualThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesSqlContainerRedistributeThroughputHeaders", + className: "SqlResourcesMigrateSqlDatabaseToManualThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10339,10 +8430,10 @@ export const SqlResourcesSqlContainerRedistributeThroughputHeaders: coreClient.C } }; -export const SqlResourcesCreateUpdateSqlStoredProcedureHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateSqlContainerHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesCreateUpdateSqlStoredProcedureHeaders", + className: "SqlResourcesCreateUpdateSqlContainerHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10360,10 +8451,10 @@ export const SqlResourcesCreateUpdateSqlStoredProcedureHeaders: coreClient.Compo } }; -export const SqlResourcesDeleteSqlStoredProcedureHeaders: coreClient.CompositeMapper = { +export const SqlResourcesDeleteSqlContainerHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesDeleteSqlStoredProcedureHeaders", + className: "SqlResourcesDeleteSqlContainerHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10381,10 +8472,10 @@ export const SqlResourcesDeleteSqlStoredProcedureHeaders: coreClient.CompositeMa } }; -export const SqlResourcesCreateUpdateSqlUserDefinedFunctionHeaders: coreClient.CompositeMapper = { +export const SqlResourcesUpdateSqlContainerThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesCreateUpdateSqlUserDefinedFunctionHeaders", + className: "SqlResourcesUpdateSqlContainerThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10402,10 +8493,10 @@ export const SqlResourcesCreateUpdateSqlUserDefinedFunctionHeaders: coreClient.C } }; -export const SqlResourcesDeleteSqlUserDefinedFunctionHeaders: coreClient.CompositeMapper = { +export const SqlResourcesMigrateSqlContainerToAutoscaleHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesDeleteSqlUserDefinedFunctionHeaders", + className: "SqlResourcesMigrateSqlContainerToAutoscaleHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10423,10 +8514,10 @@ export const SqlResourcesDeleteSqlUserDefinedFunctionHeaders: coreClient.Composi } }; -export const SqlResourcesCreateUpdateSqlTriggerHeaders: coreClient.CompositeMapper = { +export const SqlResourcesMigrateSqlContainerToManualThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesCreateUpdateSqlTriggerHeaders", + className: "SqlResourcesMigrateSqlContainerToManualThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10444,10 +8535,10 @@ export const SqlResourcesCreateUpdateSqlTriggerHeaders: coreClient.CompositeMapp } }; -export const SqlResourcesDeleteSqlTriggerHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateClientEncryptionKeyHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SqlResourcesDeleteSqlTriggerHeaders", + className: "SqlResourcesCreateUpdateClientEncryptionKeyHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10465,10 +8556,10 @@ export const SqlResourcesDeleteSqlTriggerHeaders: coreClient.CompositeMapper = { } }; -export const MongoDBResourcesCreateUpdateMongoDBDatabaseHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateSqlStoredProcedureHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesCreateUpdateMongoDBDatabaseHeaders", + className: "SqlResourcesCreateUpdateSqlStoredProcedureHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10486,10 +8577,10 @@ export const MongoDBResourcesCreateUpdateMongoDBDatabaseHeaders: coreClient.Comp } }; -export const MongoDBResourcesDeleteMongoDBDatabaseHeaders: coreClient.CompositeMapper = { +export const SqlResourcesDeleteSqlStoredProcedureHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesDeleteMongoDBDatabaseHeaders", + className: "SqlResourcesDeleteSqlStoredProcedureHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10507,10 +8598,10 @@ export const MongoDBResourcesDeleteMongoDBDatabaseHeaders: coreClient.CompositeM } }; -export const MongoDBResourcesUpdateMongoDBDatabaseThroughputHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateSqlUserDefinedFunctionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesUpdateMongoDBDatabaseThroughputHeaders", + className: "SqlResourcesCreateUpdateSqlUserDefinedFunctionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10528,10 +8619,10 @@ export const MongoDBResourcesUpdateMongoDBDatabaseThroughputHeaders: coreClient. } }; -export const MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleHeaders: coreClient.CompositeMapper = { +export const SqlResourcesDeleteSqlUserDefinedFunctionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleHeaders", + className: "SqlResourcesDeleteSqlUserDefinedFunctionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10549,11 +8640,10 @@ export const MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleHeaders: coreClien } }; -export const MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders: coreClient.CompositeMapper = { +export const SqlResourcesCreateUpdateSqlTriggerHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: - "MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders", + className: "SqlResourcesCreateUpdateSqlTriggerHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10571,11 +8661,10 @@ export const MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders: co } }; -export const MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionHeaders: coreClient.CompositeMapper = { +export const SqlResourcesDeleteSqlTriggerHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: - "MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionHeaders", + className: "SqlResourcesDeleteSqlTriggerHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10593,10 +8682,10 @@ export const MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionHeader } }; -export const MongoDBResourcesMongoDBDatabaseRedistributeThroughputHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesCreateUpdateMongoDBDatabaseHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesMongoDBDatabaseRedistributeThroughputHeaders", + className: "MongoDBResourcesCreateUpdateMongoDBDatabaseHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10614,11 +8703,10 @@ export const MongoDBResourcesMongoDBDatabaseRedistributeThroughputHeaders: coreC } }; -export const MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesDeleteMongoDBDatabaseHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: - "MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionHeaders", + className: "MongoDBResourcesDeleteMongoDBDatabaseHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10636,10 +8724,10 @@ export const MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionHeade } }; -export const MongoDBResourcesMongoDBContainerRedistributeThroughputHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesUpdateMongoDBDatabaseThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesMongoDBContainerRedistributeThroughputHeaders", + className: "MongoDBResourcesUpdateMongoDBDatabaseThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10657,10 +8745,10 @@ export const MongoDBResourcesMongoDBContainerRedistributeThroughputHeaders: core } }; -export const MongoDBResourcesCreateUpdateMongoDBCollectionHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesCreateUpdateMongoDBCollectionHeaders", + className: "MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10678,10 +8766,11 @@ export const MongoDBResourcesCreateUpdateMongoDBCollectionHeaders: coreClient.Co } }; -export const MongoDBResourcesDeleteMongoDBCollectionHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesDeleteMongoDBCollectionHeaders", + className: + "MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10699,10 +8788,10 @@ export const MongoDBResourcesDeleteMongoDBCollectionHeaders: coreClient.Composit } }; -export const MongoDBResourcesMongoDBDatabasePartitionMergeHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesCreateUpdateMongoDBCollectionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesMongoDBDatabasePartitionMergeHeaders", + className: "MongoDBResourcesCreateUpdateMongoDBCollectionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -10720,10 +8809,10 @@ export const MongoDBResourcesMongoDBDatabasePartitionMergeHeaders: coreClient.Co } }; -export const MongoDBResourcesListMongoDBCollectionPartitionMergeHeaders: coreClient.CompositeMapper = { +export const MongoDBResourcesDeleteMongoDBCollectionHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoDBResourcesListMongoDBCollectionPartitionMergeHeaders", + className: "MongoDBResourcesDeleteMongoDBCollectionHeaders", modelProperties: { azureAsyncOperation: { serializedName: "azure-asyncoperation", @@ -11122,112 +9211,6 @@ export const CassandraResourcesMigrateCassandraTableToManualThroughputHeaders: c } }; -export const CassandraResourcesCreateUpdateCassandraViewHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraResourcesCreateUpdateCassandraViewHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const CassandraResourcesDeleteCassandraViewHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraResourcesDeleteCassandraViewHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const CassandraResourcesUpdateCassandraViewThroughputHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraResourcesUpdateCassandraViewThroughputHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const CassandraResourcesMigrateCassandraViewToAutoscaleHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CassandraResourcesMigrateCassandraViewToAutoscaleHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const CassandraResourcesMigrateCassandraViewToManualThroughputHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: - "CassandraResourcesMigrateCassandraViewToManualThroughputHeaders", - modelProperties: { - azureAsyncOperation: { - serializedName: "azure-asyncoperation", - type: { - name: "String" - } - }, - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - export const GremlinResourcesCreateUpdateGremlinDatabaseHeaders: coreClient.CompositeMapper = { type: { name: "Composite", @@ -11439,41 +9422,17 @@ export const GremlinResourcesMigrateGremlinGraphToManualThroughputHeaders: coreC } }; -export const MongoClustersDeleteHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoClustersDeleteHeaders", - modelProperties: { - location: { - serializedName: "location", - type: { - name: "String" - } - } - } - } -}; - -export const MongoClustersUpdateHeaders: coreClient.CompositeMapper = { +export const ServiceCreateHeaders: coreClient.CompositeMapper = { type: { name: "Composite", - className: "MongoClustersUpdateHeaders", + className: "ServiceCreateHeaders", modelProperties: { - location: { - serializedName: "location", + azureAsyncOperation: { + serializedName: "azure-asyncoperation", type: { name: "String" } - } - } - } -}; - -export const MongoClustersDeleteFirewallRuleHeaders: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "MongoClustersDeleteFirewallRuleHeaders", - modelProperties: { + }, location: { serializedName: "location", type: { @@ -11507,14 +9466,9 @@ export const ServiceDeleteHeaders: coreClient.CompositeMapper = { export let discriminators = { BackupPolicy: BackupPolicy, - DataTransferDataSourceSink: DataTransferDataSourceSink, ServiceResourceProperties: ServiceResourceProperties, "BackupPolicy.Periodic": PeriodicModeBackupPolicy, "BackupPolicy.Continuous": ContinuousModeBackupPolicy, - "DataTransferDataSourceSink.CosmosDBCassandra": CosmosCassandraDataTransferDataSourceSink, - "DataTransferDataSourceSink.CosmosDBMongo": CosmosMongoDataTransferDataSourceSink, - "DataTransferDataSourceSink.CosmosDBSql": CosmosSqlDataTransferDataSourceSink, - "DataTransferDataSourceSink.AzureBlobStorage": AzureBlobDataTransferDataSourceSink, "ServiceResourceProperties.DataTransfer": DataTransferServiceResourceProperties, "ServiceResourceProperties.SqlDedicatedGateway": SqlDedicatedGatewayServiceResourceProperties, "ServiceResourceProperties.GraphAPICompute": GraphAPIComputeServiceResourceProperties, diff --git a/sdk/cosmosdb/arm-cosmosdb/src/models/parameters.ts b/sdk/cosmosdb/arm-cosmosdb/src/models/parameters.ts index c05f5770553b..90d49d0d7875 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/models/parameters.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/models/parameters.ts @@ -17,14 +17,10 @@ import { FailoverPolicies as FailoverPoliciesMapper, RegionForOnlineOffline as RegionForOnlineOfflineMapper, DatabaseAccountRegenerateKeyParameters as DatabaseAccountRegenerateKeyParametersMapper, - GraphResourceCreateUpdateParameters as GraphResourceCreateUpdateParametersMapper, SqlDatabaseCreateUpdateParameters as SqlDatabaseCreateUpdateParametersMapper, ThroughputSettingsUpdateParameters as ThroughputSettingsUpdateParametersMapper, - ClientEncryptionKeyCreateUpdateParameters as ClientEncryptionKeyCreateUpdateParametersMapper, SqlContainerCreateUpdateParameters as SqlContainerCreateUpdateParametersMapper, - MergeParameters as MergeParametersMapper, - RetrieveThroughputParameters as RetrieveThroughputParametersMapper, - RedistributeThroughputParameters as RedistributeThroughputParametersMapper, + ClientEncryptionKeyCreateUpdateParameters as ClientEncryptionKeyCreateUpdateParametersMapper, SqlStoredProcedureCreateUpdateParameters as SqlStoredProcedureCreateUpdateParametersMapper, SqlUserDefinedFunctionCreateUpdateParameters as SqlUserDefinedFunctionCreateUpdateParametersMapper, SqlTriggerCreateUpdateParameters as SqlTriggerCreateUpdateParametersMapper, @@ -38,17 +34,11 @@ import { TableCreateUpdateParameters as TableCreateUpdateParametersMapper, CassandraKeyspaceCreateUpdateParameters as CassandraKeyspaceCreateUpdateParametersMapper, CassandraTableCreateUpdateParameters as CassandraTableCreateUpdateParametersMapper, - CassandraViewCreateUpdateParameters as CassandraViewCreateUpdateParametersMapper, GremlinDatabaseCreateUpdateParameters as GremlinDatabaseCreateUpdateParametersMapper, GremlinGraphCreateUpdateParameters as GremlinGraphCreateUpdateParametersMapper, - CreateJobRequest as CreateJobRequestMapper, ClusterResource as ClusterResourceMapper, CommandPostBody as CommandPostBodyMapper, DataCenterResource as DataCenterResourceMapper, - MongoCluster as MongoClusterMapper, - MongoClusterUpdate as MongoClusterUpdateMapper, - FirewallRule as FirewallRuleMapper, - CheckNameAvailabilityRequest as CheckNameAvailabilityRequestMapper, NotebookWorkspaceCreateUpdateParameters as NotebookWorkspaceCreateUpdateParametersMapper, PrivateEndpointConnection as PrivateEndpointConnectionMapper, ServiceResourceCreateUpdateParameters as ServiceResourceCreateUpdateParametersMapper @@ -126,7 +116,7 @@ export const accountName: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2023-03-15-preview", + defaultValue: "2023-09-15", isConstant: true, serializedName: "api-version", type: { @@ -276,22 +266,6 @@ export const partitionKeyRangeId: OperationURLParameter = { } }; -export const graphName: OperationURLParameter = { - parameterPath: "graphName", - mapper: { - serializedName: "graphName", - required: true, - type: { - name: "String" - } - } -}; - -export const createUpdateGraphParameters: OperationParameter = { - parameterPath: "createUpdateGraphParameters", - mapper: GraphResourceCreateUpdateParametersMapper -}; - export const databaseName: OperationURLParameter = { parameterPath: "databaseName", mapper: { @@ -313,22 +287,6 @@ export const updateThroughputParameters: OperationParameter = { mapper: ThroughputSettingsUpdateParametersMapper }; -export const clientEncryptionKeyName: OperationURLParameter = { - parameterPath: "clientEncryptionKeyName", - mapper: { - serializedName: "clientEncryptionKeyName", - required: true, - type: { - name: "String" - } - } -}; - -export const createUpdateClientEncryptionKeyParameters: OperationParameter = { - parameterPath: "createUpdateClientEncryptionKeyParameters", - mapper: ClientEncryptionKeyCreateUpdateParametersMapper -}; - export const containerName: OperationURLParameter = { parameterPath: "containerName", mapper: { @@ -345,19 +303,20 @@ export const createUpdateSqlContainerParameters: OperationParameter = { mapper: SqlContainerCreateUpdateParametersMapper }; -export const mergeParameters: OperationParameter = { - parameterPath: "mergeParameters", - mapper: MergeParametersMapper -}; - -export const retrieveThroughputParameters: OperationParameter = { - parameterPath: "retrieveThroughputParameters", - mapper: RetrieveThroughputParametersMapper +export const clientEncryptionKeyName: OperationURLParameter = { + parameterPath: "clientEncryptionKeyName", + mapper: { + serializedName: "clientEncryptionKeyName", + required: true, + type: { + name: "String" + } + } }; -export const redistributeThroughputParameters: OperationParameter = { - parameterPath: "redistributeThroughputParameters", - mapper: RedistributeThroughputParametersMapper +export const createUpdateClientEncryptionKeyParameters: OperationParameter = { + parameterPath: "createUpdateClientEncryptionKeyParameters", + mapper: ClientEncryptionKeyCreateUpdateParametersMapper }; export const storedProcedureName: OperationURLParameter = { @@ -535,10 +494,15 @@ export const createUpdateCassandraTableParameters: OperationParameter = { mapper: CassandraTableCreateUpdateParametersMapper }; -export const viewName: OperationURLParameter = { - parameterPath: "viewName", +export const createUpdateGremlinDatabaseParameters: OperationParameter = { + parameterPath: "createUpdateGremlinDatabaseParameters", + mapper: GremlinDatabaseCreateUpdateParametersMapper +}; + +export const graphName: OperationURLParameter = { + parameterPath: "graphName", mapper: { - serializedName: "viewName", + serializedName: "graphName", required: true, type: { name: "String" @@ -546,16 +510,6 @@ export const viewName: OperationURLParameter = { } }; -export const createUpdateCassandraViewParameters: OperationParameter = { - parameterPath: "createUpdateCassandraViewParameters", - mapper: CassandraViewCreateUpdateParametersMapper -}; - -export const createUpdateGremlinDatabaseParameters: OperationParameter = { - parameterPath: "createUpdateGremlinDatabaseParameters", - mapper: GremlinDatabaseCreateUpdateParametersMapper -}; - export const createUpdateGremlinGraphParameters: OperationParameter = { parameterPath: "createUpdateGremlinGraphParameters", mapper: GremlinGraphCreateUpdateParametersMapper @@ -572,22 +526,6 @@ export const location1: OperationURLParameter = { } }; -export const jobCreateParameters: OperationParameter = { - parameterPath: "jobCreateParameters", - mapper: CreateJobRequestMapper -}; - -export const jobName: OperationURLParameter = { - parameterPath: "jobName", - mapper: { - serializedName: "jobName", - required: true, - type: { - name: "String" - } - } -}; - export const clusterName: OperationURLParameter = { parameterPath: "clusterName", mapper: { @@ -614,22 +552,6 @@ export const body1: OperationParameter = { mapper: CommandPostBodyMapper }; -export const backupId: OperationURLParameter = { - parameterPath: "backupId", - mapper: { - constraints: { - Pattern: new RegExp("^[0-9]+$"), - MaxLength: 15, - MinLength: 1 - }, - serializedName: "backupId", - required: true, - type: { - name: "String" - } - } -}; - export const dataCenterName: OperationURLParameter = { parameterPath: "dataCenterName", mapper: { @@ -651,72 +573,6 @@ export const body2: OperationParameter = { mapper: DataCenterResourceMapper }; -export const parameters: OperationParameter = { - parameterPath: "parameters", - mapper: MongoClusterMapper -}; - -export const mongoClusterName: OperationURLParameter = { - parameterPath: "mongoClusterName", - mapper: { - constraints: { - Pattern: new RegExp("^[a-z0-9]+(-[a-z0-9]+)*"), - MaxLength: 40, - MinLength: 3 - }, - serializedName: "mongoClusterName", - required: true, - type: { - name: "String" - } - } -}; - -export const parameters1: OperationParameter = { - parameterPath: "parameters", - mapper: MongoClusterUpdateMapper -}; - -export const parameters2: OperationParameter = { - parameterPath: "parameters", - mapper: FirewallRuleMapper -}; - -export const firewallRuleName: OperationURLParameter = { - parameterPath: "firewallRuleName", - mapper: { - constraints: { - Pattern: new RegExp("^[a-zA-Z0-9][-_.a-zA-Z0-9]*"), - MaxLength: 80, - MinLength: 1 - }, - serializedName: "firewallRuleName", - required: true, - type: { - name: "String" - } - } -}; - -export const parameters3: OperationParameter = { - parameterPath: "parameters", - mapper: CheckNameAvailabilityRequestMapper -}; - -export const location2: OperationURLParameter = { - parameterPath: "location", - mapper: { - constraints: { - MinLength: 1 - }, - serializedName: "location", - required: true, - type: { - name: "String" - } - } -}; - export const notebookWorkspaceName: OperationURLParameter = { parameterPath: "notebookWorkspaceName", mapper: { @@ -744,7 +600,7 @@ export const privateEndpointConnectionName: OperationURLParameter = { } }; -export const parameters4: OperationParameter = { +export const parameters: OperationParameter = { parameterPath: "parameters", mapper: PrivateEndpointConnectionMapper }; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraClusters.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraClusters.ts index fcb1d9561a58..44ddb96df0bf 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraClusters.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraClusters.ts @@ -24,9 +24,6 @@ import { CassandraClustersListBySubscriptionResponse, CassandraClustersListByResourceGroupOptionalParams, CassandraClustersListByResourceGroupResponse, - BackupResource, - CassandraClustersListBackupsOptionalParams, - CassandraClustersListBackupsResponse, CassandraClustersGetOptionalParams, CassandraClustersGetResponse, CassandraClustersDeleteOptionalParams, @@ -37,8 +34,6 @@ import { CommandPostBody, CassandraClustersInvokeCommandOptionalParams, CassandraClustersInvokeCommandResponse, - CassandraClustersGetBackupOptionalParams, - CassandraClustersGetBackupResponse, CassandraClustersDeallocateOptionalParams, CassandraClustersStartOptionalParams, CassandraClustersStatusOptionalParams, @@ -151,68 +146,6 @@ export class CassandraClustersImpl implements CassandraClusters { } } - /** - * List the backups of this cluster that are available to restore. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName Managed Cassandra cluster name. - * @param options The options parameters. - */ - public listBackups( - resourceGroupName: string, - clusterName: string, - options?: CassandraClustersListBackupsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listBackupsPagingAll( - resourceGroupName, - clusterName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listBackupsPagingPage( - resourceGroupName, - clusterName, - options, - settings - ); - } - }; - } - - private async *listBackupsPagingPage( - resourceGroupName: string, - clusterName: string, - options?: CassandraClustersListBackupsOptionalParams, - _settings?: PageSettings - ): AsyncIterableIterator { - let result: CassandraClustersListBackupsResponse; - result = await this._listBackups(resourceGroupName, clusterName, options); - yield result.value || []; - } - - private async *listBackupsPagingAll( - resourceGroupName: string, - clusterName: string, - options?: CassandraClustersListBackupsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listBackupsPagingPage( - resourceGroupName, - clusterName, - options - )) { - yield* page; - } - } - /** * List all managed Cassandra clusters in this subscription. * @param options The options parameters. @@ -627,42 +560,6 @@ export class CassandraClustersImpl implements CassandraClusters { return poller.pollUntilDone(); } - /** - * List the backups of this cluster that are available to restore. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName Managed Cassandra cluster name. - * @param options The options parameters. - */ - private _listBackups( - resourceGroupName: string, - clusterName: string, - options?: CassandraClustersListBackupsOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, clusterName, options }, - listBackupsOperationSpec - ); - } - - /** - * Get the properties of an individual backup of this cluster that is available to restore. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName Managed Cassandra cluster name. - * @param backupId Id of a restorable backup of a Cassandra cluster. - * @param options The options parameters. - */ - getBackup( - resourceGroupName: string, - clusterName: string, - backupId: string, - options?: CassandraClustersGetBackupOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, clusterName, backupId, options }, - getBackupOperationSpec - ); - } - /** * Deallocate the Managed Cassandra Cluster and Associated Data Centers. Deallocation will deallocate * the host virtual machine of this cluster, and reserved the data disk. This won't do anything on an @@ -1037,51 +934,6 @@ const invokeCommandOperationSpec: coreClient.OperationSpec = { mediaType: "json", serializer }; -const listBackupsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/cassandraClusters/{clusterName}/backups", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ListBackups - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.clusterName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getBackupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/cassandraClusters/{clusterName}/backups/{backupId}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.BackupResource - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.clusterName, - Parameters.backupId - ], - headerParameters: [Parameters.accept], - serializer -}; const deallocateOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/cassandraClusters/{clusterName}/deallocate", diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraResources.ts index 8083dd468af5..0e3362049a2c 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/cassandraResources.ts @@ -25,9 +25,6 @@ import { CassandraTableGetResults, CassandraResourcesListCassandraTablesOptionalParams, CassandraResourcesListCassandraTablesResponse, - CassandraViewGetResults, - CassandraResourcesListCassandraViewsOptionalParams, - CassandraResourcesListCassandraViewsResponse, CassandraResourcesGetCassandraKeyspaceOptionalParams, CassandraResourcesGetCassandraKeyspaceResponse, CassandraKeyspaceCreateUpdateParameters, @@ -58,21 +55,7 @@ import { CassandraResourcesMigrateCassandraTableToAutoscaleOptionalParams, CassandraResourcesMigrateCassandraTableToAutoscaleResponse, CassandraResourcesMigrateCassandraTableToManualThroughputOptionalParams, - CassandraResourcesMigrateCassandraTableToManualThroughputResponse, - CassandraResourcesGetCassandraViewOptionalParams, - CassandraResourcesGetCassandraViewResponse, - CassandraViewCreateUpdateParameters, - CassandraResourcesCreateUpdateCassandraViewOptionalParams, - CassandraResourcesCreateUpdateCassandraViewResponse, - CassandraResourcesDeleteCassandraViewOptionalParams, - CassandraResourcesGetCassandraViewThroughputOptionalParams, - CassandraResourcesGetCassandraViewThroughputResponse, - CassandraResourcesUpdateCassandraViewThroughputOptionalParams, - CassandraResourcesUpdateCassandraViewThroughputResponse, - CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams, - CassandraResourcesMigrateCassandraViewToAutoscaleResponse, - CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams, - CassandraResourcesMigrateCassandraViewToManualThroughputResponse + CassandraResourcesMigrateCassandraTableToManualThroughputResponse } from "../models"; /// @@ -228,80 +211,6 @@ export class CassandraResourcesImpl implements CassandraResources { } } - /** - * Lists the Cassandra materialized views under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param options The options parameters. - */ - public listCassandraViews( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - options?: CassandraResourcesListCassandraViewsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listCassandraViewsPagingAll( - resourceGroupName, - accountName, - keyspaceName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listCassandraViewsPagingPage( - resourceGroupName, - accountName, - keyspaceName, - options, - settings - ); - } - }; - } - - private async *listCassandraViewsPagingPage( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - options?: CassandraResourcesListCassandraViewsOptionalParams, - _settings?: PageSettings - ): AsyncIterableIterator { - let result: CassandraResourcesListCassandraViewsResponse; - result = await this._listCassandraViews( - resourceGroupName, - accountName, - keyspaceName, - options - ); - yield result.value || []; - } - - private async *listCassandraViewsPagingAll( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - options?: CassandraResourcesListCassandraViewsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listCassandraViewsPagingPage( - resourceGroupName, - accountName, - keyspaceName, - options - )) { - yield* page; - } - } - /** * Lists the Cassandra keyspaces under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -1489,593 +1398,9 @@ export class CassandraResourcesImpl implements CassandraResources { ); return poller.pollUntilDone(); } - - /** - * Lists the Cassandra materialized views under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param options The options parameters. - */ - private _listCassandraViews( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - options?: CassandraResourcesListCassandraViewsOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, keyspaceName, options }, - listCassandraViewsOperationSpec - ); - } - - /** - * Gets the Cassandra view under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - getCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesGetCassandraViewOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, keyspaceName, viewName, options }, - getCassandraViewOperationSpec - ); - } - - /** - * Create or update an Azure Cosmos DB Cassandra View - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param createUpdateCassandraViewParameters The parameters to provide for the current Cassandra View. - * @param options The options parameters. - */ - async beginCreateUpdateCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - createUpdateCassandraViewParameters: CassandraViewCreateUpdateParameters, - options?: CassandraResourcesCreateUpdateCassandraViewOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesCreateUpdateCassandraViewResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - keyspaceName, - viewName, - createUpdateCassandraViewParameters, - options - }, - spec: createUpdateCassandraViewOperationSpec - }); - const poller = await createHttpPoller< - CassandraResourcesCreateUpdateCassandraViewResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Create or update an Azure Cosmos DB Cassandra View - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param createUpdateCassandraViewParameters The parameters to provide for the current Cassandra View. - * @param options The options parameters. - */ - async beginCreateUpdateCassandraViewAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - createUpdateCassandraViewParameters: CassandraViewCreateUpdateParameters, - options?: CassandraResourcesCreateUpdateCassandraViewOptionalParams - ): Promise { - const poller = await this.beginCreateUpdateCassandraView( - resourceGroupName, - accountName, - keyspaceName, - viewName, - createUpdateCassandraViewParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Deletes an existing Azure Cosmos DB Cassandra view. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginDeleteCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesDeleteCassandraViewOptionalParams - ): Promise, void>> { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, accountName, keyspaceName, viewName, options }, - spec: deleteCassandraViewOperationSpec - }); - const poller = await createHttpPoller>(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Deletes an existing Azure Cosmos DB Cassandra view. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginDeleteCassandraViewAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesDeleteCassandraViewOptionalParams - ): Promise { - const poller = await this.beginDeleteCassandraView( - resourceGroupName, - accountName, - keyspaceName, - viewName, - options - ); - return poller.pollUntilDone(); - } - - /** - * Gets the RUs per second of the Cassandra view under an existing Azure Cosmos DB database account - * with the provided name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - getCassandraViewThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesGetCassandraViewThroughputOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, keyspaceName, viewName, options }, - getCassandraViewThroughputOperationSpec - ); - } - - /** - * Update RUs per second of an Azure Cosmos DB Cassandra view - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param updateThroughputParameters The RUs per second of the parameters to provide for the current - * Cassandra view. - * @param options The options parameters. - */ - async beginUpdateCassandraViewThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - updateThroughputParameters: ThroughputSettingsUpdateParameters, - options?: CassandraResourcesUpdateCassandraViewThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesUpdateCassandraViewThroughputResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - keyspaceName, - viewName, - updateThroughputParameters, - options - }, - spec: updateCassandraViewThroughputOperationSpec - }); - const poller = await createHttpPoller< - CassandraResourcesUpdateCassandraViewThroughputResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Update RUs per second of an Azure Cosmos DB Cassandra view - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param updateThroughputParameters The RUs per second of the parameters to provide for the current - * Cassandra view. - * @param options The options parameters. - */ - async beginUpdateCassandraViewThroughputAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - updateThroughputParameters: ThroughputSettingsUpdateParameters, - options?: CassandraResourcesUpdateCassandraViewThroughputOptionalParams - ): Promise { - const poller = await this.beginUpdateCassandraViewThroughput( - resourceGroupName, - accountName, - keyspaceName, - viewName, - updateThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Migrate an Azure Cosmos DB Cassandra view from manual throughput to autoscale - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginMigrateCassandraViewToAutoscale( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesMigrateCassandraViewToAutoscaleResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, accountName, keyspaceName, viewName, options }, - spec: migrateCassandraViewToAutoscaleOperationSpec - }); - const poller = await createHttpPoller< - CassandraResourcesMigrateCassandraViewToAutoscaleResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Migrate an Azure Cosmos DB Cassandra view from manual throughput to autoscale - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginMigrateCassandraViewToAutoscaleAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams - ): Promise { - const poller = await this.beginMigrateCassandraViewToAutoscale( - resourceGroupName, - accountName, - keyspaceName, - viewName, - options - ); - return poller.pollUntilDone(); - } - - /** - * Migrate an Azure Cosmos DB Cassandra view from autoscale to manual throughput - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginMigrateCassandraViewToManualThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - CassandraResourcesMigrateCassandraViewToManualThroughputResponse - >, - CassandraResourcesMigrateCassandraViewToManualThroughputResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, accountName, keyspaceName, viewName, options }, - spec: migrateCassandraViewToManualThroughputOperationSpec - }); - const poller = await createHttpPoller< - CassandraResourcesMigrateCassandraViewToManualThroughputResponse, - OperationState< - CassandraResourcesMigrateCassandraViewToManualThroughputResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Migrate an Azure Cosmos DB Cassandra view from autoscale to manual throughput - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - async beginMigrateCassandraViewToManualThroughputAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams - ): Promise { - const poller = await this.beginMigrateCassandraViewToManualThroughput( - resourceGroupName, - accountName, - keyspaceName, - viewName, - options - ); - return poller.pollUntilDone(); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listCassandraKeyspacesOperationSpec: coreClient.OperationSpec = { path: @@ -2511,211 +1836,3 @@ const migrateCassandraTableToManualThroughputOperationSpec: coreClient.Operation headerParameters: [Parameters.accept], serializer }; -const listCassandraViewsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.CassandraViewListResult - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getCassandraViewOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.CassandraViewGetResults - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createUpdateCassandraViewOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.CassandraViewGetResults - }, - 201: { - bodyMapper: Mappers.CassandraViewGetResults - }, - 202: { - bodyMapper: Mappers.CassandraViewGetResults - }, - 204: { - bodyMapper: Mappers.CassandraViewGetResults - } - }, - requestBody: Parameters.createUpdateCassandraViewParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const deleteCassandraViewOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}", - httpMethod: "DELETE", - responses: { 200: {}, 201: {}, 202: {}, 204: {} }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - serializer -}; -const getCassandraViewThroughputOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ThroughputSettingsGetResults - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept], - serializer -}; -const updateCassandraViewThroughputOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 201: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 202: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 204: { - bodyMapper: Mappers.ThroughputSettingsGetResults - } - }, - requestBody: Parameters.updateThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const migrateCassandraViewToAutoscaleOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default/migrateToAutoscale", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 201: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 202: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 204: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept], - serializer -}; -const migrateCassandraViewToManualThroughputOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/cassandraKeyspaces/{keyspaceName}/views/{viewName}/throughputSettings/default/migrateToManualThroughput", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 201: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 202: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - 204: { - bodyMapper: Mappers.ThroughputSettingsGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.keyspaceName, - Parameters.viewName - ], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/dataTransferJobs.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/dataTransferJobs.ts deleted file mode 100644 index fa0f29cdd55a..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/dataTransferJobs.ts +++ /dev/null @@ -1,427 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper"; -import { DataTransferJobs } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { CosmosDBManagementClient } from "../cosmosDBManagementClient"; -import { - DataTransferJobGetResults, - DataTransferJobsListByDatabaseAccountNextOptionalParams, - DataTransferJobsListByDatabaseAccountOptionalParams, - DataTransferJobsListByDatabaseAccountResponse, - CreateJobRequest, - DataTransferJobsCreateOptionalParams, - DataTransferJobsCreateResponse, - DataTransferJobsGetOptionalParams, - DataTransferJobsGetResponse, - DataTransferJobsPauseOptionalParams, - DataTransferJobsPauseResponse, - DataTransferJobsResumeOptionalParams, - DataTransferJobsResumeResponse, - DataTransferJobsCancelOptionalParams, - DataTransferJobsCancelResponse, - DataTransferJobsListByDatabaseAccountNextResponse -} from "../models"; - -/// -/** Class containing DataTransferJobs operations. */ -export class DataTransferJobsImpl implements DataTransferJobs { - private readonly client: CosmosDBManagementClient; - - /** - * Initialize a new instance of the class DataTransferJobs class. - * @param client Reference to the service client - */ - constructor(client: CosmosDBManagementClient) { - this.client = client; - } - - /** - * Get a list of Data Transfer jobs. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - public listByDatabaseAccount( - resourceGroupName: string, - accountName: string, - options?: DataTransferJobsListByDatabaseAccountOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listByDatabaseAccountPagingAll( - resourceGroupName, - accountName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listByDatabaseAccountPagingPage( - resourceGroupName, - accountName, - options, - settings - ); - } - }; - } - - private async *listByDatabaseAccountPagingPage( - resourceGroupName: string, - accountName: string, - options?: DataTransferJobsListByDatabaseAccountOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: DataTransferJobsListByDatabaseAccountResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listByDatabaseAccount( - resourceGroupName, - accountName, - options - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listByDatabaseAccountNext( - resourceGroupName, - accountName, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listByDatabaseAccountPagingAll( - resourceGroupName: string, - accountName: string, - options?: DataTransferJobsListByDatabaseAccountOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listByDatabaseAccountPagingPage( - resourceGroupName, - accountName, - options - )) { - yield* page; - } - } - - /** - * Creates a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param jobCreateParameters Parameters to create Data Transfer Job - * @param options The options parameters. - */ - create( - resourceGroupName: string, - accountName: string, - jobName: string, - jobCreateParameters: CreateJobRequest, - options?: DataTransferJobsCreateOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, jobName, jobCreateParameters, options }, - createOperationSpec - ); - } - - /** - * Get a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - get( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsGetOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, jobName, options }, - getOperationSpec - ); - } - - /** - * Pause a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - pause( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsPauseOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, jobName, options }, - pauseOperationSpec - ); - } - - /** - * Resumes a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - resume( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsResumeOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, jobName, options }, - resumeOperationSpec - ); - } - - /** - * Cancels a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - cancel( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsCancelOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, jobName, options }, - cancelOperationSpec - ); - } - - /** - * Get a list of Data Transfer jobs. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - private _listByDatabaseAccount( - resourceGroupName: string, - accountName: string, - options?: DataTransferJobsListByDatabaseAccountOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, options }, - listByDatabaseAccountOperationSpec - ); - } - - /** - * ListByDatabaseAccountNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param nextLink The nextLink from the previous successful call to the ListByDatabaseAccount method. - * @param options The options parameters. - */ - private _listByDatabaseAccountNext( - resourceGroupName: string, - accountName: string, - nextLink: string, - options?: DataTransferJobsListByDatabaseAccountNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, nextLink, options }, - listByDatabaseAccountNextOperationSpec - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const createOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs/{jobName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.jobCreateParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.jobName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs/{jobName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.jobName - ], - headerParameters: [Parameters.accept], - serializer -}; -const pauseOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs/{jobName}/pause", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.jobName - ], - headerParameters: [Parameters.accept], - serializer -}; -const resumeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs/{jobName}/resume", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.jobName - ], - headerParameters: [Parameters.accept], - serializer -}; -const cancelOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs/{jobName}/cancel", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobGetResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.jobName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listByDatabaseAccountOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/dataTransferJobs", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobFeedResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listByDatabaseAccountNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.DataTransferJobFeedResults - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.nextLink - ], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/graphResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/graphResources.ts deleted file mode 100644 index ca9d84964a8c..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/graphResources.ts +++ /dev/null @@ -1,424 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { GraphResources } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { CosmosDBManagementClient } from "../cosmosDBManagementClient"; -import { - SimplePollerLike, - OperationState, - createHttpPoller -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl"; -import { - GraphResourceGetResults, - GraphResourcesListGraphsOptionalParams, - GraphResourcesListGraphsResponse, - GraphResourcesGetGraphOptionalParams, - GraphResourcesGetGraphResponse, - GraphResourceCreateUpdateParameters, - GraphResourcesCreateUpdateGraphOptionalParams, - GraphResourcesCreateUpdateGraphResponse, - GraphResourcesDeleteGraphResourceOptionalParams -} from "../models"; - -/// -/** Class containing GraphResources operations. */ -export class GraphResourcesImpl implements GraphResources { - private readonly client: CosmosDBManagementClient; - - /** - * Initialize a new instance of the class GraphResources class. - * @param client Reference to the service client - */ - constructor(client: CosmosDBManagementClient) { - this.client = client; - } - - /** - * Lists the graphs under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - public listGraphs( - resourceGroupName: string, - accountName: string, - options?: GraphResourcesListGraphsOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listGraphsPagingAll( - resourceGroupName, - accountName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listGraphsPagingPage( - resourceGroupName, - accountName, - options, - settings - ); - } - }; - } - - private async *listGraphsPagingPage( - resourceGroupName: string, - accountName: string, - options?: GraphResourcesListGraphsOptionalParams, - _settings?: PageSettings - ): AsyncIterableIterator { - let result: GraphResourcesListGraphsResponse; - result = await this._listGraphs(resourceGroupName, accountName, options); - yield result.value || []; - } - - private async *listGraphsPagingAll( - resourceGroupName: string, - accountName: string, - options?: GraphResourcesListGraphsOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listGraphsPagingPage( - resourceGroupName, - accountName, - options - )) { - yield* page; - } - } - - /** - * Lists the graphs under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - private _listGraphs( - resourceGroupName: string, - accountName: string, - options?: GraphResourcesListGraphsOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, options }, - listGraphsOperationSpec - ); - } - - /** - * Gets the Graph resource under an existing Azure Cosmos DB database account with the provided name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - getGraph( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesGetGraphOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, graphName, options }, - getGraphOperationSpec - ); - } - - /** - * Create or update an Azure Cosmos DB Graph. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param createUpdateGraphParameters The parameters to provide for the current graph. - * @param options The options parameters. - */ - async beginCreateUpdateGraph( - resourceGroupName: string, - accountName: string, - graphName: string, - createUpdateGraphParameters: GraphResourceCreateUpdateParameters, - options?: GraphResourcesCreateUpdateGraphOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - GraphResourcesCreateUpdateGraphResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - graphName, - createUpdateGraphParameters, - options - }, - spec: createUpdateGraphOperationSpec - }); - const poller = await createHttpPoller< - GraphResourcesCreateUpdateGraphResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Create or update an Azure Cosmos DB Graph. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param createUpdateGraphParameters The parameters to provide for the current graph. - * @param options The options parameters. - */ - async beginCreateUpdateGraphAndWait( - resourceGroupName: string, - accountName: string, - graphName: string, - createUpdateGraphParameters: GraphResourceCreateUpdateParameters, - options?: GraphResourcesCreateUpdateGraphOptionalParams - ): Promise { - const poller = await this.beginCreateUpdateGraph( - resourceGroupName, - accountName, - graphName, - createUpdateGraphParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Deletes an existing Azure Cosmos DB Graph Resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - async beginDeleteGraphResource( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesDeleteGraphResourceOptionalParams - ): Promise, void>> { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, accountName, graphName, options }, - spec: deleteGraphResourceOperationSpec - }); - const poller = await createHttpPoller>(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Deletes an existing Azure Cosmos DB Graph Resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - async beginDeleteGraphResourceAndWait( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesDeleteGraphResourceOptionalParams - ): Promise { - const poller = await this.beginDeleteGraphResource( - resourceGroupName, - accountName, - graphName, - options - ); - return poller.pollUntilDone(); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listGraphsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/graphs", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.GraphResourcesListResult - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getGraphOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/graphs/{graphName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.GraphResourceGetResults - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.graphName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createUpdateGraphOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/graphs/{graphName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.GraphResourceGetResults - }, - 201: { - bodyMapper: Mappers.GraphResourceGetResults - }, - 202: { - bodyMapper: Mappers.GraphResourceGetResults - }, - 204: { - bodyMapper: Mappers.GraphResourceGetResults - } - }, - requestBody: Parameters.createUpdateGraphParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.graphName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const deleteGraphResourceOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/graphs/{graphName}", - httpMethod: "DELETE", - responses: { 200: {}, 201: {}, 202: {}, 204: {} }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.graphName - ], - serializer -}; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/gremlinResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/gremlinResources.ts index 6170d76b9253..71d2f195fb63 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/gremlinResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/gremlinResources.ts @@ -1754,8 +1754,8 @@ const getGremlinGraphOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept], serializer @@ -1785,8 +1785,8 @@ const createUpdateGremlinGraphOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -1816,8 +1816,8 @@ const deleteGremlinGraphOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], serializer }; @@ -1836,8 +1836,8 @@ const getGremlinGraphThroughputOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept], serializer @@ -1867,8 +1867,8 @@ const updateGremlinGraphThroughputOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", @@ -1901,8 +1901,8 @@ const migrateGremlinGraphToAutoscaleOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept], serializer @@ -1934,8 +1934,8 @@ const migrateGremlinGraphToManualThroughputOperationSpec: coreClient.OperationSp Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept], serializer @@ -1968,8 +1968,8 @@ const retrieveContinuousBackupInformationOperationSpec: coreClient.OperationSpec Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.accountName, - Parameters.graphName, - Parameters.databaseName + Parameters.databaseName, + Parameters.graphName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/index.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/index.ts index 062f4d7ab604..96531b8c1b96 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/index.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/index.ts @@ -19,17 +19,14 @@ export * from "./collectionPartitionRegion"; export * from "./collectionPartition"; export * from "./partitionKeyRangeId"; export * from "./partitionKeyRangeIdRegion"; -export * from "./graphResources"; export * from "./sqlResources"; export * from "./mongoDBResources"; export * from "./tableResources"; export * from "./cassandraResources"; export * from "./gremlinResources"; export * from "./locations"; -export * from "./dataTransferJobs"; export * from "./cassandraClusters"; export * from "./cassandraDataCenters"; -export * from "./mongoClusters"; export * from "./notebookWorkspaces"; export * from "./privateEndpointConnections"; export * from "./privateLinkResources"; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoClusters.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoClusters.ts deleted file mode 100644 index b27619751911..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoClusters.ts +++ /dev/null @@ -1,1308 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator, PageSettings } from "@azure/core-paging"; -import { setContinuationToken } from "../pagingHelper"; -import { MongoClusters } from "../operationsInterfaces"; -import * as coreClient from "@azure/core-client"; -import * as Mappers from "../models/mappers"; -import * as Parameters from "../models/parameters"; -import { CosmosDBManagementClient } from "../cosmosDBManagementClient"; -import { - SimplePollerLike, - OperationState, - createHttpPoller -} from "@azure/core-lro"; -import { createLroSpec } from "../lroImpl"; -import { - MongoCluster, - MongoClustersListNextOptionalParams, - MongoClustersListOptionalParams, - MongoClustersListResponse, - MongoClustersListByResourceGroupNextOptionalParams, - MongoClustersListByResourceGroupOptionalParams, - MongoClustersListByResourceGroupResponse, - FirewallRule, - MongoClustersListFirewallRulesNextOptionalParams, - MongoClustersListFirewallRulesOptionalParams, - MongoClustersListFirewallRulesResponse, - MongoClustersCreateOrUpdateOptionalParams, - MongoClustersCreateOrUpdateResponse, - MongoClustersGetOptionalParams, - MongoClustersGetResponse, - MongoClustersDeleteOptionalParams, - MongoClustersDeleteResponse, - MongoClusterUpdate, - MongoClustersUpdateOptionalParams, - MongoClustersUpdateResponse, - MongoClustersCreateOrUpdateFirewallRuleOptionalParams, - MongoClustersCreateOrUpdateFirewallRuleResponse, - MongoClustersDeleteFirewallRuleOptionalParams, - MongoClustersDeleteFirewallRuleResponse, - MongoClustersGetFirewallRuleOptionalParams, - MongoClustersGetFirewallRuleResponse, - CheckNameAvailabilityRequest, - MongoClustersCheckNameAvailabilityOptionalParams, - MongoClustersCheckNameAvailabilityResponse, - MongoClustersListConnectionStringsOptionalParams, - MongoClustersListConnectionStringsResponse, - MongoClustersListNextResponse, - MongoClustersListByResourceGroupNextResponse, - MongoClustersListFirewallRulesNextResponse -} from "../models"; - -/// -/** Class containing MongoClusters operations. */ -export class MongoClustersImpl implements MongoClusters { - private readonly client: CosmosDBManagementClient; - - /** - * Initialize a new instance of the class MongoClusters class. - * @param client Reference to the service client - */ - constructor(client: CosmosDBManagementClient) { - this.client = client; - } - - /** - * List all the mongo clusters in a given subscription. - * @param options The options parameters. - */ - public list( - options?: MongoClustersListOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listPagingAll(options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listPagingPage(options, settings); - } - }; - } - - private async *listPagingPage( - options?: MongoClustersListOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: MongoClustersListResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._list(options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listNext(continuationToken, options); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listPagingAll( - options?: MongoClustersListOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listPagingPage(options)) { - yield* page; - } - } - - /** - * List all the mongo clusters in a given resource group. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - public listByResourceGroup( - resourceGroupName: string, - options?: MongoClustersListByResourceGroupOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listByResourceGroupPagingPage( - resourceGroupName, - options, - settings - ); - } - }; - } - - private async *listByResourceGroupPagingPage( - resourceGroupName: string, - options?: MongoClustersListByResourceGroupOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: MongoClustersListByResourceGroupResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listByResourceGroup(resourceGroupName, options); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listByResourceGroupNext( - resourceGroupName, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listByResourceGroupPagingAll( - resourceGroupName: string, - options?: MongoClustersListByResourceGroupOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listByResourceGroupPagingPage( - resourceGroupName, - options - )) { - yield* page; - } - } - - /** - * List all the firewall rules in a given mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - public listFirewallRules( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListFirewallRulesOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listFirewallRulesPagingAll( - resourceGroupName, - mongoClusterName, - options - ); - return { - next() { - return iter.next(); - }, - [Symbol.asyncIterator]() { - return this; - }, - byPage: (settings?: PageSettings) => { - if (settings?.maxPageSize) { - throw new Error("maxPageSize is not supported by this operation."); - } - return this.listFirewallRulesPagingPage( - resourceGroupName, - mongoClusterName, - options, - settings - ); - } - }; - } - - private async *listFirewallRulesPagingPage( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListFirewallRulesOptionalParams, - settings?: PageSettings - ): AsyncIterableIterator { - let result: MongoClustersListFirewallRulesResponse; - let continuationToken = settings?.continuationToken; - if (!continuationToken) { - result = await this._listFirewallRules( - resourceGroupName, - mongoClusterName, - options - ); - let page = result.value || []; - continuationToken = result.nextLink; - setContinuationToken(page, continuationToken); - yield page; - } - while (continuationToken) { - result = await this._listFirewallRulesNext( - resourceGroupName, - mongoClusterName, - continuationToken, - options - ); - continuationToken = result.nextLink; - let page = result.value || []; - setContinuationToken(page, continuationToken); - yield page; - } - } - - private async *listFirewallRulesPagingAll( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListFirewallRulesOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listFirewallRulesPagingPage( - resourceGroupName, - mongoClusterName, - options - )) { - yield* page; - } - } - - /** - * List all the mongo clusters in a given subscription. - * @param options The options parameters. - */ - private _list( - options?: MongoClustersListOptionalParams - ): Promise { - return this.client.sendOperationRequest({ options }, listOperationSpec); - } - - /** - * List all the mongo clusters in a given resource group. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - private _listByResourceGroup( - resourceGroupName: string, - options?: MongoClustersListByResourceGroupOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, options }, - listByResourceGroupOperationSpec - ); - } - - /** - * Create or update a mongo cluster. Update overwrites all properties for the resource. To only modify - * some of the properties, use PATCH. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The required parameters for creating or updating a mongo cluster. - * @param options The options parameters. - */ - async beginCreateOrUpdate( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoCluster, - options?: MongoClustersCreateOrUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersCreateOrUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, mongoClusterName, parameters, options }, - spec: createOrUpdateOperationSpec - }); - const poller = await createHttpPoller< - MongoClustersCreateOrUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" - }); - await poller.poll(); - return poller; - } - - /** - * Create or update a mongo cluster. Update overwrites all properties for the resource. To only modify - * some of the properties, use PATCH. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The required parameters for creating or updating a mongo cluster. - * @param options The options parameters. - */ - async beginCreateOrUpdateAndWait( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoCluster, - options?: MongoClustersCreateOrUpdateOptionalParams - ): Promise { - const poller = await this.beginCreateOrUpdate( - resourceGroupName, - mongoClusterName, - parameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Gets information about a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersGetOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, mongoClusterName, options }, - getOperationSpec - ); - } - - /** - * Deletes a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - async beginDelete( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersDeleteOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersDeleteResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, mongoClusterName, options }, - spec: deleteOperationSpec - }); - const poller = await createHttpPoller< - MongoClustersDeleteResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Deletes a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - async beginDeleteAndWait( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersDeleteOptionalParams - ): Promise { - const poller = await this.beginDelete( - resourceGroupName, - mongoClusterName, - options - ); - return poller.pollUntilDone(); - } - - /** - * Updates an existing mongo cluster. The request body can contain one to many of the properties - * present in the normal mongo cluster definition. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The parameters for updating a mongo cluster. - * @param options The options parameters. - */ - async beginUpdate( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoClusterUpdate, - options?: MongoClustersUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersUpdateResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, mongoClusterName, parameters, options }, - spec: updateOperationSpec - }); - const poller = await createHttpPoller< - MongoClustersUpdateResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Updates an existing mongo cluster. The request body can contain one to many of the properties - * present in the normal mongo cluster definition. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The parameters for updating a mongo cluster. - * @param options The options parameters. - */ - async beginUpdateAndWait( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoClusterUpdate, - options?: MongoClustersUpdateOptionalParams - ): Promise { - const poller = await this.beginUpdate( - resourceGroupName, - mongoClusterName, - parameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Creates a new firewall rule or updates an existing firewall rule on a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param parameters The required parameters for creating or updating a firewall rule. - * @param options The options parameters. - */ - async beginCreateOrUpdateFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - parameters: FirewallRule, - options?: MongoClustersCreateOrUpdateFirewallRuleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersCreateOrUpdateFirewallRuleResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - mongoClusterName, - firewallRuleName, - parameters, - options - }, - spec: createOrUpdateFirewallRuleOperationSpec - }); - const poller = await createHttpPoller< - MongoClustersCreateOrUpdateFirewallRuleResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" - }); - await poller.poll(); - return poller; - } - - /** - * Creates a new firewall rule or updates an existing firewall rule on a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param parameters The required parameters for creating or updating a firewall rule. - * @param options The options parameters. - */ - async beginCreateOrUpdateFirewallRuleAndWait( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - parameters: FirewallRule, - options?: MongoClustersCreateOrUpdateFirewallRuleOptionalParams - ): Promise { - const poller = await this.beginCreateOrUpdateFirewallRule( - resourceGroupName, - mongoClusterName, - firewallRuleName, - parameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Deletes a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - async beginDeleteFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersDeleteFirewallRuleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersDeleteFirewallRuleResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { resourceGroupName, mongoClusterName, firewallRuleName, options }, - spec: deleteFirewallRuleOperationSpec - }); - const poller = await createHttpPoller< - MongoClustersDeleteFirewallRuleResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Deletes a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - async beginDeleteFirewallRuleAndWait( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersDeleteFirewallRuleOptionalParams - ): Promise { - const poller = await this.beginDeleteFirewallRule( - resourceGroupName, - mongoClusterName, - firewallRuleName, - options - ); - return poller.pollUntilDone(); - } - - /** - * Gets information about a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - getFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersGetFirewallRuleOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, mongoClusterName, firewallRuleName, options }, - getFirewallRuleOperationSpec - ); - } - - /** - * List all the firewall rules in a given mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - private _listFirewallRules( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListFirewallRulesOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, mongoClusterName, options }, - listFirewallRulesOperationSpec - ); - } - - /** - * Check the availability of name for resource - * @param location The name of the Azure region. - * @param parameters The required parameters for checking if resource name is available. - * @param options The options parameters. - */ - checkNameAvailability( - location: string, - parameters: CheckNameAvailabilityRequest, - options?: MongoClustersCheckNameAvailabilityOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { location, parameters, options }, - checkNameAvailabilityOperationSpec - ); - } - - /** - * List mongo cluster connection strings. This includes the default connection string using - * SCRAM-SHA-256, as well as other connection strings supported by the cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - listConnectionStrings( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListConnectionStringsOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, mongoClusterName, options }, - listConnectionStringsOperationSpec - ); - } - - /** - * ListNext - * @param nextLink The nextLink from the previous successful call to the List method. - * @param options The options parameters. - */ - private _listNext( - nextLink: string, - options?: MongoClustersListNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { nextLink, options }, - listNextOperationSpec - ); - } - - /** - * ListByResourceGroupNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param nextLink The nextLink from the previous successful call to the ListByResourceGroup method. - * @param options The options parameters. - */ - private _listByResourceGroupNext( - resourceGroupName: string, - nextLink: string, - options?: MongoClustersListByResourceGroupNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec - ); - } - - /** - * ListFirewallRulesNext - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param nextLink The nextLink from the previous successful call to the ListFirewallRules method. - * @param options The options parameters. - */ - private _listFirewallRulesNext( - resourceGroupName: string, - mongoClusterName: string, - nextLink: string, - options?: MongoClustersListFirewallRulesNextOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, mongoClusterName, nextLink, options }, - listFirewallRulesNextOperationSpec - ); - } -} -// Operation Specifications -const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); - -const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/mongoClusters", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.MongoClusterListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [Parameters.$host, Parameters.subscriptionId], - headerParameters: [Parameters.accept], - serializer -}; -const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.MongoClusterListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.MongoCluster - }, - 201: { - bodyMapper: Mappers.MongoCluster - }, - 202: { - bodyMapper: Mappers.MongoCluster - }, - 204: { - bodyMapper: Mappers.MongoCluster - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - requestBody: Parameters.parameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.MongoCluster - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept], - serializer -}; -const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.MongoClustersDeleteHeaders - }, - 201: { - headersMapper: Mappers.MongoClustersDeleteHeaders - }, - 202: { - headersMapper: Mappers.MongoClustersDeleteHeaders - }, - 204: { - headersMapper: Mappers.MongoClustersDeleteHeaders - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept], - serializer -}; -const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}", - httpMethod: "PATCH", - responses: { - 200: { - bodyMapper: Mappers.MongoCluster - }, - 201: { - bodyMapper: Mappers.MongoCluster - }, - 202: { - bodyMapper: Mappers.MongoCluster - }, - 204: { - bodyMapper: Mappers.MongoCluster - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - requestBody: Parameters.parameters1, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const createOrUpdateFirewallRuleOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}/firewallRules/{firewallRuleName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.FirewallRule - }, - 201: { - bodyMapper: Mappers.FirewallRule - }, - 202: { - bodyMapper: Mappers.FirewallRule - }, - 204: { - bodyMapper: Mappers.FirewallRule - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - requestBody: Parameters.parameters2, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName, - Parameters.firewallRuleName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const deleteFirewallRuleOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}/firewallRules/{firewallRuleName}", - httpMethod: "DELETE", - responses: { - 200: { - headersMapper: Mappers.MongoClustersDeleteFirewallRuleHeaders - }, - 201: { - headersMapper: Mappers.MongoClustersDeleteFirewallRuleHeaders - }, - 202: { - headersMapper: Mappers.MongoClustersDeleteFirewallRuleHeaders - }, - 204: { - headersMapper: Mappers.MongoClustersDeleteFirewallRuleHeaders - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName, - Parameters.firewallRuleName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getFirewallRuleOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}/firewallRules/{firewallRuleName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.FirewallRule - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName, - Parameters.firewallRuleName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listFirewallRulesOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}/firewallRules", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.FirewallRuleListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept], - serializer -}; -const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/checkMongoClusterNameAvailability", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.CheckNameAvailabilityResponse - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - requestBody: Parameters.parameters3, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.location2 - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const listConnectionStringsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/mongoClusters/{mongoClusterName}/listConnectionStrings", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.ListConnectionStringsResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept], - serializer -}; -const listNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.MongoClusterListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.nextLink - ], - headerParameters: [Parameters.accept], - serializer -}; -const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.MongoClusterListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink - ], - headerParameters: [Parameters.accept], - serializer -}; -const listFirewallRulesNextOperationSpec: coreClient.OperationSpec = { - path: "{nextLink}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.FirewallRuleListResult - }, - default: { - bodyMapper: Mappers.ErrorResponseAutoGenerated - } - }, - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.nextLink, - Parameters.mongoClusterName - ], - headerParameters: [Parameters.accept], - serializer -}; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoDBResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoDBResources.ts index dcb38bbc8654..ee29a8ec5d69 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoDBResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/mongoDBResources.ts @@ -47,16 +47,6 @@ import { MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleResponse, MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputOptionalParams, MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputResponse, - RetrieveThroughputParameters, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse, - RedistributeThroughputParameters, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse, - MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams, - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse, MongoDBResourcesGetMongoDBCollectionOptionalParams, MongoDBResourcesGetMongoDBCollectionResponse, MongoDBCollectionCreateUpdateParameters, @@ -64,11 +54,6 @@ import { MongoDBResourcesCreateUpdateMongoDBCollectionResponse, MongoDBResourcesDeleteMongoDBCollectionOptionalParams, MongoDBResourcesDeleteMongoDBCollectionResponse, - MergeParameters, - MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams, - MongoDBResourcesMongoDBDatabasePartitionMergeResponse, - MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams, - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse, MongoDBResourcesGetMongoDBCollectionThroughputOptionalParams, MongoDBResourcesGetMongoDBCollectionThroughputResponse, MongoDBResourcesUpdateMongoDBCollectionThroughputOptionalParams, @@ -942,757 +927,72 @@ export class MongoDBResourcesImpl implements MongoDBResources { } /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB database. - * @param options The options parameters. - */ - async beginMongoDBDatabaseRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - >, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - retrieveThroughputParameters, - options - }, - spec: mongoDBDatabaseRetrieveThroughputDistributionOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse, - OperationState< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB database. - * @param options The options parameters. - */ - async beginMongoDBDatabaseRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - > { - const poller = await this.beginMongoDBDatabaseRetrieveThroughputDistribution( - resourceGroupName, - accountName, - databaseName, - retrieveThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB database. - * @param options The options parameters. - */ - async beginMongoDBDatabaseRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse - >, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - redistributeThroughputParameters, - options - }, - spec: mongoDBDatabaseRedistributeThroughputOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse, - OperationState< - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB database. - * @param options The options parameters. - */ - async beginMongoDBDatabaseRedistributeThroughputAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams - ): Promise { - const poller = await this.beginMongoDBDatabaseRedistributeThroughput( - resourceGroupName, - accountName, - databaseName, - redistributeThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB container. - * @param options The options parameters. - */ - async beginMongoDBContainerRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - >, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - collectionName, - retrieveThroughputParameters, - options - }, - spec: mongoDBContainerRetrieveThroughputDistributionOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse, - OperationState< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB container. - * @param options The options parameters. - */ - async beginMongoDBContainerRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - > { - const poller = await this.beginMongoDBContainerRetrieveThroughputDistribution( - resourceGroupName, - accountName, - databaseName, - collectionName, - retrieveThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB container. - * @param options The options parameters. - */ - async beginMongoDBContainerRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse - >, - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - collectionName, - redistributeThroughputParameters, - options - }, - spec: mongoDBContainerRedistributeThroughputOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse, - OperationState< - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB container. - * @param options The options parameters. - */ - async beginMongoDBContainerRedistributeThroughputAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams - ): Promise { - const poller = await this.beginMongoDBContainerRedistributeThroughput( - resourceGroupName, - accountName, - databaseName, - collectionName, - redistributeThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Lists the MongoDB collection under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param options The options parameters. - */ - private _listMongoDBCollections( - resourceGroupName: string, - accountName: string, - databaseName: string, - options?: MongoDBResourcesListMongoDBCollectionsOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, databaseName, options }, - listMongoDBCollectionsOperationSpec - ); - } - - /** - * Gets the MongoDB collection under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param options The options parameters. - */ - getMongoDBCollection( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - options?: MongoDBResourcesGetMongoDBCollectionOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, databaseName, collectionName, options }, - getMongoDBCollectionOperationSpec - ); - } - - /** - * Create or update an Azure Cosmos DB MongoDB Collection - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param createUpdateMongoDBCollectionParameters The parameters to provide for the current MongoDB - * Collection. - * @param options The options parameters. - */ - async beginCreateUpdateMongoDBCollection( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - createUpdateMongoDBCollectionParameters: MongoDBCollectionCreateUpdateParameters, - options?: MongoDBResourcesCreateUpdateMongoDBCollectionOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoDBResourcesCreateUpdateMongoDBCollectionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - collectionName, - createUpdateMongoDBCollectionParameters, - options - }, - spec: createUpdateMongoDBCollectionOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesCreateUpdateMongoDBCollectionResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Create or update an Azure Cosmos DB MongoDB Collection - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param createUpdateMongoDBCollectionParameters The parameters to provide for the current MongoDB - * Collection. - * @param options The options parameters. - */ - async beginCreateUpdateMongoDBCollectionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - createUpdateMongoDBCollectionParameters: MongoDBCollectionCreateUpdateParameters, - options?: MongoDBResourcesCreateUpdateMongoDBCollectionOptionalParams - ): Promise { - const poller = await this.beginCreateUpdateMongoDBCollection( - resourceGroupName, - accountName, - databaseName, - collectionName, - createUpdateMongoDBCollectionParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Deletes an existing Azure Cosmos DB MongoDB Collection. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param options The options parameters. - */ - async beginDeleteMongoDBCollection( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - options?: MongoDBResourcesDeleteMongoDBCollectionOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoDBResourcesDeleteMongoDBCollectionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - collectionName, - options - }, - spec: deleteMongoDBCollectionOperationSpec - }); - const poller = await createHttpPoller< - MongoDBResourcesDeleteMongoDBCollectionResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; + * Lists the MongoDB collection under an existing Azure Cosmos DB database account. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param accountName Cosmos DB database account name. + * @param databaseName Cosmos DB database name. + * @param options The options parameters. + */ + private _listMongoDBCollections( + resourceGroupName: string, + accountName: string, + databaseName: string, + options?: MongoDBResourcesListMongoDBCollectionsOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, accountName, databaseName, options }, + listMongoDBCollectionsOperationSpec + ); } /** - * Deletes an existing Azure Cosmos DB MongoDB Collection. + * Gets the MongoDB collection under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param collectionName Cosmos DB collection name. * @param options The options parameters. */ - async beginDeleteMongoDBCollectionAndWait( + getMongoDBCollection( resourceGroupName: string, accountName: string, databaseName: string, collectionName: string, - options?: MongoDBResourcesDeleteMongoDBCollectionOptionalParams - ): Promise { - const poller = await this.beginDeleteMongoDBCollection( - resourceGroupName, - accountName, - databaseName, - collectionName, - options + options?: MongoDBResourcesGetMongoDBCollectionOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, accountName, databaseName, collectionName, options }, + getMongoDBCollectionOperationSpec ); - return poller.pollUntilDone(); } /** - * Merges the partitions of a MongoDB database + * Create or update an Azure Cosmos DB MongoDB Collection * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. + * @param collectionName Cosmos DB collection name. + * @param createUpdateMongoDBCollectionParameters The parameters to provide for the current MongoDB + * Collection. * @param options The options parameters. */ - async beginMongoDBDatabasePartitionMerge( + async beginCreateUpdateMongoDBCollection( resourceGroupName: string, accountName: string, databaseName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams + collectionName: string, + createUpdateMongoDBCollectionParameters: MongoDBCollectionCreateUpdateParameters, + options?: MongoDBResourcesCreateUpdateMongoDBCollectionOptionalParams ): Promise< SimplePollerLike< - OperationState, - MongoDBResourcesMongoDBDatabasePartitionMergeResponse + OperationState, + MongoDBResourcesCreateUpdateMongoDBCollectionResponse > > { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec - ): Promise => { + ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( @@ -1734,76 +1034,76 @@ export class MongoDBResourcesImpl implements MongoDBResources { resourceGroupName, accountName, databaseName, - mergeParameters, + collectionName, + createUpdateMongoDBCollectionParameters, options }, - spec: mongoDBDatabasePartitionMergeOperationSpec + spec: createUpdateMongoDBCollectionOperationSpec }); const poller = await createHttpPoller< - MongoDBResourcesMongoDBDatabasePartitionMergeResponse, - OperationState + MongoDBResourcesCreateUpdateMongoDBCollectionResponse, + OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + intervalInMs: options?.updateIntervalInMs }); await poller.poll(); return poller; } /** - * Merges the partitions of a MongoDB database + * Create or update an Azure Cosmos DB MongoDB Collection * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. + * @param collectionName Cosmos DB collection name. + * @param createUpdateMongoDBCollectionParameters The parameters to provide for the current MongoDB + * Collection. * @param options The options parameters. */ - async beginMongoDBDatabasePartitionMergeAndWait( + async beginCreateUpdateMongoDBCollectionAndWait( resourceGroupName: string, accountName: string, databaseName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams - ): Promise { - const poller = await this.beginMongoDBDatabasePartitionMerge( + collectionName: string, + createUpdateMongoDBCollectionParameters: MongoDBCollectionCreateUpdateParameters, + options?: MongoDBResourcesCreateUpdateMongoDBCollectionOptionalParams + ): Promise { + const poller = await this.beginCreateUpdateMongoDBCollection( resourceGroupName, accountName, databaseName, - mergeParameters, + collectionName, + createUpdateMongoDBCollectionParameters, options ); return poller.pollUntilDone(); } /** - * Merges the partitions of a MongoDB Collection + * Deletes an existing Azure Cosmos DB MongoDB Collection. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param collectionName Cosmos DB collection name. - * @param mergeParameters The parameters for the merge operation. * @param options The options parameters. */ - async beginListMongoDBCollectionPartitionMerge( + async beginDeleteMongoDBCollection( resourceGroupName: string, accountName: string, databaseName: string, collectionName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams + options?: MongoDBResourcesDeleteMongoDBCollectionOptionalParams ): Promise< SimplePollerLike< - OperationState< - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse - >, - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse + OperationState, + MongoDBResourcesDeleteMongoDBCollectionResponse > > { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec - ): Promise => { + ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( @@ -1846,48 +1146,41 @@ export class MongoDBResourcesImpl implements MongoDBResources { accountName, databaseName, collectionName, - mergeParameters, options }, - spec: listMongoDBCollectionPartitionMergeOperationSpec + spec: deleteMongoDBCollectionOperationSpec }); const poller = await createHttpPoller< - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse, - OperationState< - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse - > + MongoDBResourcesDeleteMongoDBCollectionResponse, + OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + intervalInMs: options?.updateIntervalInMs }); await poller.poll(); return poller; } /** - * Merges the partitions of a MongoDB Collection + * Deletes an existing Azure Cosmos DB MongoDB Collection. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param collectionName Cosmos DB collection name. - * @param mergeParameters The parameters for the merge operation. * @param options The options parameters. */ - async beginListMongoDBCollectionPartitionMergeAndWait( + async beginDeleteMongoDBCollectionAndWait( resourceGroupName: string, accountName: string, databaseName: string, collectionName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams - ): Promise { - const poller = await this.beginListMongoDBCollectionPartitionMerge( + options?: MongoDBResourcesDeleteMongoDBCollectionOptionalParams + ): Promise { + const poller = await this.beginDeleteMongoDBCollection( resourceGroupName, accountName, databaseName, collectionName, - mergeParameters, options ); return poller.pollUntilDone(); @@ -3049,144 +2342,6 @@ const migrateMongoDBDatabaseToManualThroughputOperationSpec: coreClient.Operatio headerParameters: [Parameters.accept], serializer }; -const mongoDBDatabaseRetrieveThroughputDistributionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/throughputSettings/default/retrieveThroughputDistribution", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.retrieveThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const mongoDBDatabaseRedistributeThroughputOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/throughputSettings/default/redistributeThroughput", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.redistributeThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const mongoDBContainerRetrieveThroughputDistributionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/collections/{collectionName}/throughputSettings/default/retrieveThroughputDistribution", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.retrieveThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.collectionName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const mongoDBContainerRedistributeThroughputOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/collections/{collectionName}/throughputSettings/default/redistributeThroughput", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.redistributeThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.collectionName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; const listMongoDBCollectionsOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/collections", @@ -3289,75 +2444,6 @@ const deleteMongoDBCollectionOperationSpec: coreClient.OperationSpec = { ], serializer }; -const mongoDBDatabasePartitionMergeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/partitionMerge", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.mergeParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const listMongoDBCollectionPartitionMergeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/collections/{collectionName}/partitionMerge", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.mergeParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.collectionName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; const getMongoDBCollectionThroughputOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/mongodbDatabases/{databaseName}/collections/{collectionName}/throughputSettings/default", diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/privateEndpointConnections.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/privateEndpointConnections.ts index 31cf6e2983a5..f50ade0f71dc 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/privateEndpointConnections.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/privateEndpointConnections.ts @@ -411,7 +411,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - requestBody: Parameters.parameters4, + requestBody: Parameters.parameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operations/sqlResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operations/sqlResources.ts index 0296f77efe68..30318a49cd39 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operations/sqlResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operations/sqlResources.ts @@ -22,12 +22,12 @@ import { SqlDatabaseGetResults, SqlResourcesListSqlDatabasesOptionalParams, SqlResourcesListSqlDatabasesResponse, - ClientEncryptionKeyGetResults, - SqlResourcesListClientEncryptionKeysOptionalParams, - SqlResourcesListClientEncryptionKeysResponse, SqlContainerGetResults, SqlResourcesListSqlContainersOptionalParams, SqlResourcesListSqlContainersResponse, + ClientEncryptionKeyGetResults, + SqlResourcesListClientEncryptionKeysOptionalParams, + SqlResourcesListClientEncryptionKeysResponse, SqlStoredProcedureGetResults, SqlResourcesListSqlStoredProceduresOptionalParams, SqlResourcesListSqlStoredProceduresResponse, @@ -59,11 +59,6 @@ import { SqlResourcesMigrateSqlDatabaseToAutoscaleResponse, SqlResourcesMigrateSqlDatabaseToManualThroughputOptionalParams, SqlResourcesMigrateSqlDatabaseToManualThroughputResponse, - SqlResourcesGetClientEncryptionKeyOptionalParams, - SqlResourcesGetClientEncryptionKeyResponse, - ClientEncryptionKeyCreateUpdateParameters, - SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams, - SqlResourcesCreateUpdateClientEncryptionKeyResponse, SqlResourcesGetSqlContainerOptionalParams, SqlResourcesGetSqlContainerResponse, SqlContainerCreateUpdateParameters, @@ -71,11 +66,6 @@ import { SqlResourcesCreateUpdateSqlContainerResponse, SqlResourcesDeleteSqlContainerOptionalParams, SqlResourcesDeleteSqlContainerResponse, - MergeParameters, - SqlResourcesSqlDatabasePartitionMergeOptionalParams, - SqlResourcesSqlDatabasePartitionMergeResponse, - SqlResourcesListSqlContainerPartitionMergeOptionalParams, - SqlResourcesListSqlContainerPartitionMergeResponse, SqlResourcesGetSqlContainerThroughputOptionalParams, SqlResourcesGetSqlContainerThroughputResponse, SqlResourcesUpdateSqlContainerThroughputOptionalParams, @@ -84,16 +74,11 @@ import { SqlResourcesMigrateSqlContainerToAutoscaleResponse, SqlResourcesMigrateSqlContainerToManualThroughputOptionalParams, SqlResourcesMigrateSqlContainerToManualThroughputResponse, - RetrieveThroughputParameters, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse, - RedistributeThroughputParameters, - SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams, - SqlResourcesSqlDatabaseRedistributeThroughputResponse, - SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams, - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse, - SqlResourcesSqlContainerRedistributeThroughputOptionalParams, - SqlResourcesSqlContainerRedistributeThroughputResponse, + SqlResourcesGetClientEncryptionKeyOptionalParams, + SqlResourcesGetClientEncryptionKeyResponse, + ClientEncryptionKeyCreateUpdateParameters, + SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams, + SqlResourcesCreateUpdateClientEncryptionKeyResponse, SqlResourcesGetSqlStoredProcedureOptionalParams, SqlResourcesGetSqlStoredProcedureResponse, SqlStoredProcedureCreateUpdateParameters, @@ -212,19 +197,19 @@ export class SqlResourcesImpl implements SqlResources { } /** - * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. + * Lists the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param options The options parameters. */ - public listClientEncryptionKeys( + public listSqlContainers( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListClientEncryptionKeysOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listClientEncryptionKeysPagingAll( + options?: SqlResourcesListSqlContainersOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listSqlContainersPagingAll( resourceGroupName, accountName, databaseName, @@ -241,7 +226,7 @@ export class SqlResourcesImpl implements SqlResources { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.listClientEncryptionKeysPagingPage( + return this.listSqlContainersPagingPage( resourceGroupName, accountName, databaseName, @@ -252,15 +237,15 @@ export class SqlResourcesImpl implements SqlResources { }; } - private async *listClientEncryptionKeysPagingPage( + private async *listSqlContainersPagingPage( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListClientEncryptionKeysOptionalParams, + options?: SqlResourcesListSqlContainersOptionalParams, _settings?: PageSettings - ): AsyncIterableIterator { - let result: SqlResourcesListClientEncryptionKeysResponse; - result = await this._listClientEncryptionKeys( + ): AsyncIterableIterator { + let result: SqlResourcesListSqlContainersResponse; + result = await this._listSqlContainers( resourceGroupName, accountName, databaseName, @@ -269,13 +254,13 @@ export class SqlResourcesImpl implements SqlResources { yield result.value || []; } - private async *listClientEncryptionKeysPagingAll( + private async *listSqlContainersPagingAll( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListClientEncryptionKeysOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listClientEncryptionKeysPagingPage( + options?: SqlResourcesListSqlContainersOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listSqlContainersPagingPage( resourceGroupName, accountName, databaseName, @@ -286,19 +271,19 @@ export class SqlResourcesImpl implements SqlResources { } /** - * Lists the SQL container under an existing Azure Cosmos DB database account. + * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param options The options parameters. */ - public listSqlContainers( + public listClientEncryptionKeys( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListSqlContainersOptionalParams - ): PagedAsyncIterableIterator { - const iter = this.listSqlContainersPagingAll( + options?: SqlResourcesListClientEncryptionKeysOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listClientEncryptionKeysPagingAll( resourceGroupName, accountName, databaseName, @@ -315,7 +300,7 @@ export class SqlResourcesImpl implements SqlResources { if (settings?.maxPageSize) { throw new Error("maxPageSize is not supported by this operation."); } - return this.listSqlContainersPagingPage( + return this.listClientEncryptionKeysPagingPage( resourceGroupName, accountName, databaseName, @@ -326,15 +311,15 @@ export class SqlResourcesImpl implements SqlResources { }; } - private async *listSqlContainersPagingPage( + private async *listClientEncryptionKeysPagingPage( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListSqlContainersOptionalParams, + options?: SqlResourcesListClientEncryptionKeysOptionalParams, _settings?: PageSettings - ): AsyncIterableIterator { - let result: SqlResourcesListSqlContainersResponse; - result = await this._listSqlContainers( + ): AsyncIterableIterator { + let result: SqlResourcesListClientEncryptionKeysResponse; + result = await this._listClientEncryptionKeys( resourceGroupName, accountName, databaseName, @@ -343,13 +328,13 @@ export class SqlResourcesImpl implements SqlResources { yield result.value || []; } - private async *listSqlContainersPagingAll( + private async *listClientEncryptionKeysPagingAll( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListSqlContainersOptionalParams - ): AsyncIterableIterator { - for await (const page of this.listSqlContainersPagingPage( + options?: SqlResourcesListClientEncryptionKeysOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listClientEncryptionKeysPagingPage( resourceGroupName, accountName, databaseName, @@ -1292,168 +1277,6 @@ export class SqlResourcesImpl implements SqlResources { return poller.pollUntilDone(); } - /** - * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param options The options parameters. - */ - private _listClientEncryptionKeys( - resourceGroupName: string, - accountName: string, - databaseName: string, - options?: SqlResourcesListClientEncryptionKeysOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, accountName, databaseName, options }, - listClientEncryptionKeysOperationSpec - ); - } - - /** - * Gets the ClientEncryptionKey under an existing Azure Cosmos DB SQL database. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param options The options parameters. - */ - getClientEncryptionKey( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - options?: SqlResourcesGetClientEncryptionKeyOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { - resourceGroupName, - accountName, - databaseName, - clientEncryptionKeyName, - options - }, - getClientEncryptionKeyOperationSpec - ); - } - - /** - * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure - * Powershell (instead of directly). - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption - * key. - * @param options The options parameters. - */ - async beginCreateUpdateClientEncryptionKey( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, - options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesCreateUpdateClientEncryptionKeyResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - clientEncryptionKeyName, - createUpdateClientEncryptionKeyParameters, - options - }, - spec: createUpdateClientEncryptionKeyOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesCreateUpdateClientEncryptionKeyResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs - }); - await poller.poll(); - return poller; - } - - /** - * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure - * Powershell (instead of directly). - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption - * key. - * @param options The options parameters. - */ - async beginCreateUpdateClientEncryptionKeyAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, - options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams - ): Promise { - const poller = await this.beginCreateUpdateClientEncryptionKey( - resourceGroupName, - accountName, - databaseName, - clientEncryptionKeyName, - createUpdateClientEncryptionKeyParameters, - options - ); - return poller.pollUntilDone(); - } - /** * Lists the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -1713,234 +1536,14 @@ export class SqlResourcesImpl implements SqlResources { } /** - * Merges the partitions of a SQL database + * Gets the RUs per second of the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. + * @param containerName Cosmos DB container name. * @param options The options parameters. */ - async beginSqlDatabasePartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesSqlDatabasePartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesSqlDatabasePartitionMergeResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - mergeParameters, - options - }, - spec: sqlDatabasePartitionMergeOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesSqlDatabasePartitionMergeResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Merges the partitions of a SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - async beginSqlDatabasePartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesSqlDatabasePartitionMergeOptionalParams - ): Promise { - const poller = await this.beginSqlDatabasePartitionMerge( - resourceGroupName, - accountName, - databaseName, - mergeParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Merges the partitions of a SQL Container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - async beginListSqlContainerPartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesListSqlContainerPartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesListSqlContainerPartitionMergeResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - containerName, - mergeParameters, - options - }, - spec: listSqlContainerPartitionMergeOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesListSqlContainerPartitionMergeResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Merges the partitions of a SQL Container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - async beginListSqlContainerPartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesListSqlContainerPartitionMergeOptionalParams - ): Promise { - const poller = await this.beginListSqlContainerPartitionMerge( - resourceGroupName, - accountName, - databaseName, - containerName, - mergeParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Gets the RUs per second of the SQL container under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param options The options parameters. - */ - getSqlContainerThroughput( + getSqlContainerThroughput( resourceGroupName: string, accountName: string, databaseName: string, @@ -2280,373 +1883,79 @@ export class SqlResourcesImpl implements SqlResources { } /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL database. - * @param options The options parameters. - */ - async beginSqlDatabaseRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse - >, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - retrieveThroughputParameters, - options - }, - spec: sqlDatabaseRetrieveThroughputDistributionOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse, - OperationState< - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL database. - * @param options The options parameters. - */ - async beginSqlDatabaseRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise { - const poller = await this.beginSqlDatabaseRetrieveThroughputDistribution( - resourceGroupName, - accountName, - databaseName, - retrieveThroughputParameters, - options - ); - return poller.pollUntilDone(); - } - - /** - * Redistribute throughput for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL database. - * @param options The options parameters. - */ - async beginSqlDatabaseRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesSqlDatabaseRedistributeThroughputResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - redistributeThroughputParameters, - options - }, - spec: sqlDatabaseRedistributeThroughputOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesSqlDatabaseRedistributeThroughputResponse, - OperationState - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Redistribute throughput for an Azure Cosmos DB SQL database + * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL database. * @param options The options parameters. */ - async beginSqlDatabaseRedistributeThroughputAndWait( + private _listClientEncryptionKeys( resourceGroupName: string, accountName: string, databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams - ): Promise { - const poller = await this.beginSqlDatabaseRedistributeThroughput( - resourceGroupName, - accountName, - databaseName, - redistributeThroughputParameters, - options + options?: SqlResourcesListClientEncryptionKeysOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, accountName, databaseName, options }, + listClientEncryptionKeysOperationSpec ); - return poller.pollUntilDone(); } /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL container. - * @param options The options parameters. - */ - async beginSqlContainerRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse - >, - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse - > - > { - const directSendOperation = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ): Promise => { - return this.client.sendOperationRequest(args, spec); - }; - const sendOperationFn = async ( - args: coreClient.OperationArguments, - spec: coreClient.OperationSpec - ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; - const providedCallback = args.options?.onResponse; - const callback: coreClient.RawResponseCallback = ( - rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown - ) => { - currentRawResponse = rawResponse; - providedCallback?.(rawResponse, flatResponse); - }; - const updatedArgs = { - ...args, - options: { - ...args.options, - onResponse: callback - } - }; - const flatResponse = await directSendOperation(updatedArgs, spec); - return { - flatResponse, - rawResponse: { - statusCode: currentRawResponse!.status, - body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } - }; - }; - - const lro = createLroSpec({ - sendOperationFn, - args: { - resourceGroupName, - accountName, - databaseName, - containerName, - retrieveThroughputParameters, - options - }, - spec: sqlContainerRetrieveThroughputDistributionOperationSpec - }); - const poller = await createHttpPoller< - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse, - OperationState< - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse - > - >(lro, { - restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" - }); - await poller.poll(); - return poller; - } - - /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL container + * Gets the ClientEncryptionKey under an existing Azure Cosmos DB SQL database. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. * @param options The options parameters. */ - async beginSqlContainerRetrieveThroughputDistributionAndWait( + getClientEncryptionKey( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams - ): Promise { - const poller = await this.beginSqlContainerRetrieveThroughputDistribution( - resourceGroupName, - accountName, - databaseName, - containerName, - retrieveThroughputParameters, - options + clientEncryptionKeyName: string, + options?: SqlResourcesGetClientEncryptionKeyOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + databaseName, + clientEncryptionKeyName, + options + }, + getClientEncryptionKeyOperationSpec ); - return poller.pollUntilDone(); } /** - * Redistribute throughput for an Azure Cosmos DB SQL container + * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure + * Powershell (instead of directly). * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. + * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption + * key. * @param options The options parameters. */ - async beginSqlContainerRedistributeThroughput( + async beginCreateUpdateClientEncryptionKey( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlContainerRedistributeThroughputOptionalParams + clientEncryptionKeyName: string, + createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, + options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams ): Promise< SimplePollerLike< - OperationState, - SqlResourcesSqlContainerRedistributeThroughputResponse + OperationState, + SqlResourcesCreateUpdateClientEncryptionKeyResponse > > { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec - ): Promise => { + ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( @@ -2688,48 +1997,48 @@ export class SqlResourcesImpl implements SqlResources { resourceGroupName, accountName, databaseName, - containerName, - redistributeThroughputParameters, + clientEncryptionKeyName, + createUpdateClientEncryptionKeyParameters, options }, - spec: sqlContainerRedistributeThroughputOperationSpec + spec: createUpdateClientEncryptionKeyOperationSpec }); const poller = await createHttpPoller< - SqlResourcesSqlContainerRedistributeThroughputResponse, - OperationState + SqlResourcesCreateUpdateClientEncryptionKeyResponse, + OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "location" + intervalInMs: options?.updateIntervalInMs }); await poller.poll(); return poller; } /** - * Redistribute throughput for an Azure Cosmos DB SQL container + * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure + * Powershell (instead of directly). * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. + * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption + * key. * @param options The options parameters. */ - async beginSqlContainerRedistributeThroughputAndWait( + async beginCreateUpdateClientEncryptionKeyAndWait( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlContainerRedistributeThroughputOptionalParams - ): Promise { - const poller = await this.beginSqlContainerRedistributeThroughput( + clientEncryptionKeyName: string, + createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, + options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams + ): Promise { + const poller = await this.beginCreateUpdateClientEncryptionKey( resourceGroupName, accountName, databaseName, - containerName, - redistributeThroughputParameters, + clientEncryptionKeyName, + createUpdateClientEncryptionKeyParameters, options ); return poller.pollUntilDone(); @@ -4373,79 +3682,6 @@ const migrateSqlDatabaseToManualThroughputOperationSpec: coreClient.OperationSpe headerParameters: [Parameters.accept], serializer }; -const listClientEncryptionKeysOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ClientEncryptionKeysListResult - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getClientEncryptionKeyOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys/{clientEncryptionKeyName}", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: Mappers.ClientEncryptionKeyGetResults - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.clientEncryptionKeyName - ], - headerParameters: [Parameters.accept], - serializer -}; -const createUpdateClientEncryptionKeyOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys/{clientEncryptionKeyName}", - httpMethod: "PUT", - responses: { - 200: { - bodyMapper: Mappers.ClientEncryptionKeyGetResults - }, - 201: { - bodyMapper: Mappers.ClientEncryptionKeyGetResults - }, - 202: { - bodyMapper: Mappers.ClientEncryptionKeyGetResults - }, - 204: { - bodyMapper: Mappers.ClientEncryptionKeyGetResults - } - }, - requestBody: Parameters.createUpdateClientEncryptionKeyParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.clientEncryptionKeyName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; const listSqlContainersOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/containers", @@ -4548,75 +3784,6 @@ const deleteSqlContainerOperationSpec: coreClient.OperationSpec = { ], serializer }; -const sqlDatabasePartitionMergeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/partitionMerge", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.mergeParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const listSqlContainerPartitionMergeOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/containers/{containerName}/partitionMerge", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionStorageInfoCollection - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.mergeParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName, - Parameters.containerName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; const getSqlContainerThroughputOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/containers/{containerName}/throughputSettings/default", @@ -4736,62 +3903,15 @@ const migrateSqlContainerToManualThroughputOperationSpec: coreClient.OperationSp headerParameters: [Parameters.accept], serializer }; -const sqlDatabaseRetrieveThroughputDistributionOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/throughputSettings/default/retrieveThroughputDistribution", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError - } - }, - requestBody: Parameters.retrieveThroughputParameters, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.accountName, - Parameters.databaseName - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; -const sqlDatabaseRedistributeThroughputOperationSpec: coreClient.OperationSpec = { +const listClientEncryptionKeysOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/throughputSettings/default/redistributeThroughput", - httpMethod: "POST", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys", + httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError + bodyMapper: Mappers.ClientEncryptionKeysListResult } }, - requestBody: Parameters.redistributeThroughputParameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, @@ -4800,32 +3920,18 @@ const sqlDatabaseRedistributeThroughputOperationSpec: coreClient.OperationSpec = Parameters.accountName, Parameters.databaseName ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", + headerParameters: [Parameters.accept], serializer }; -const sqlContainerRetrieveThroughputDistributionOperationSpec: coreClient.OperationSpec = { +const getClientEncryptionKeyOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/containers/{containerName}/throughputSettings/default/retrieveThroughputDistribution", - httpMethod: "POST", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys/{clientEncryptionKeyName}", + httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError + bodyMapper: Mappers.ClientEncryptionKeyGetResults } }, - requestBody: Parameters.retrieveThroughputParameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, @@ -4833,34 +3939,30 @@ const sqlContainerRetrieveThroughputDistributionOperationSpec: coreClient.Operat Parameters.resourceGroupName, Parameters.accountName, Parameters.databaseName, - Parameters.containerName + Parameters.clientEncryptionKeyName ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", + headerParameters: [Parameters.accept], serializer }; -const sqlContainerRedistributeThroughputOperationSpec: coreClient.OperationSpec = { +const createUpdateClientEncryptionKeyOperationSpec: coreClient.OperationSpec = { path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/containers/{containerName}/throughputSettings/default/redistributeThroughput", - httpMethod: "POST", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DocumentDB/databaseAccounts/{accountName}/sqlDatabases/{databaseName}/clientEncryptionKeys/{clientEncryptionKeyName}", + httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult + bodyMapper: Mappers.ClientEncryptionKeyGetResults }, 201: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult + bodyMapper: Mappers.ClientEncryptionKeyGetResults }, 202: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult + bodyMapper: Mappers.ClientEncryptionKeyGetResults }, 204: { - bodyMapper: Mappers.PhysicalPartitionThroughputInfoResult - }, - default: { - bodyMapper: Mappers.CloudError + bodyMapper: Mappers.ClientEncryptionKeyGetResults } }, - requestBody: Parameters.redistributeThroughputParameters, + requestBody: Parameters.createUpdateClientEncryptionKeyParameters, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, @@ -4868,7 +3970,7 @@ const sqlContainerRedistributeThroughputOperationSpec: coreClient.OperationSpec Parameters.resourceGroupName, Parameters.accountName, Parameters.databaseName, - Parameters.containerName + Parameters.clientEncryptionKeyName ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraClusters.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraClusters.ts index 50b10290ff84..a986f122c8dd 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraClusters.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraClusters.ts @@ -12,8 +12,6 @@ import { ClusterResource, CassandraClustersListBySubscriptionOptionalParams, CassandraClustersListByResourceGroupOptionalParams, - BackupResource, - CassandraClustersListBackupsOptionalParams, CassandraClustersGetOptionalParams, CassandraClustersGetResponse, CassandraClustersDeleteOptionalParams, @@ -24,8 +22,6 @@ import { CommandPostBody, CassandraClustersInvokeCommandOptionalParams, CassandraClustersInvokeCommandResponse, - CassandraClustersGetBackupOptionalParams, - CassandraClustersGetBackupResponse, CassandraClustersDeallocateOptionalParams, CassandraClustersStartOptionalParams, CassandraClustersStatusOptionalParams, @@ -51,17 +47,6 @@ export interface CassandraClusters { resourceGroupName: string, options?: CassandraClustersListByResourceGroupOptionalParams ): PagedAsyncIterableIterator; - /** - * List the backups of this cluster that are available to restore. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName Managed Cassandra cluster name. - * @param options The options parameters. - */ - listBackups( - resourceGroupName: string, - clusterName: string, - options?: CassandraClustersListBackupsOptionalParams - ): PagedAsyncIterableIterator; /** * Get the properties of a managed Cassandra cluster. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -190,19 +175,6 @@ export interface CassandraClusters { body: CommandPostBody, options?: CassandraClustersInvokeCommandOptionalParams ): Promise; - /** - * Get the properties of an individual backup of this cluster that is available to restore. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName Managed Cassandra cluster name. - * @param backupId Id of a restorable backup of a Cassandra cluster. - * @param options The options parameters. - */ - getBackup( - resourceGroupName: string, - clusterName: string, - backupId: string, - options?: CassandraClustersGetBackupOptionalParams - ): Promise; /** * Deallocate the Managed Cassandra Cluster and Associated Data Centers. Deallocation will deallocate * the host virtual machine of this cluster, and reserved the data disk. This won't do anything on an diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraResources.ts index 90e49ef1dd33..887d47ff925f 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/cassandraResources.ts @@ -13,8 +13,6 @@ import { CassandraResourcesListCassandraKeyspacesOptionalParams, CassandraTableGetResults, CassandraResourcesListCassandraTablesOptionalParams, - CassandraViewGetResults, - CassandraResourcesListCassandraViewsOptionalParams, CassandraResourcesGetCassandraKeyspaceOptionalParams, CassandraResourcesGetCassandraKeyspaceResponse, CassandraKeyspaceCreateUpdateParameters, @@ -45,21 +43,7 @@ import { CassandraResourcesMigrateCassandraTableToAutoscaleOptionalParams, CassandraResourcesMigrateCassandraTableToAutoscaleResponse, CassandraResourcesMigrateCassandraTableToManualThroughputOptionalParams, - CassandraResourcesMigrateCassandraTableToManualThroughputResponse, - CassandraResourcesGetCassandraViewOptionalParams, - CassandraResourcesGetCassandraViewResponse, - CassandraViewCreateUpdateParameters, - CassandraResourcesCreateUpdateCassandraViewOptionalParams, - CassandraResourcesCreateUpdateCassandraViewResponse, - CassandraResourcesDeleteCassandraViewOptionalParams, - CassandraResourcesGetCassandraViewThroughputOptionalParams, - CassandraResourcesGetCassandraViewThroughputResponse, - CassandraResourcesUpdateCassandraViewThroughputOptionalParams, - CassandraResourcesUpdateCassandraViewThroughputResponse, - CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams, - CassandraResourcesMigrateCassandraViewToAutoscaleResponse, - CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams, - CassandraResourcesMigrateCassandraViewToManualThroughputResponse + CassandraResourcesMigrateCassandraTableToManualThroughputResponse } from "../models"; /// @@ -89,19 +73,6 @@ export interface CassandraResources { keyspaceName: string, options?: CassandraResourcesListCassandraTablesOptionalParams ): PagedAsyncIterableIterator; - /** - * Lists the Cassandra materialized views under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param options The options parameters. - */ - listCassandraViews( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - options?: CassandraResourcesListCassandraViewsOptionalParams - ): PagedAsyncIterableIterator; /** * Gets the Cassandra keyspaces under an existing Azure Cosmos DB database account with the provided * name. @@ -527,217 +498,4 @@ export interface CassandraResources { tableName: string, options?: CassandraResourcesMigrateCassandraTableToManualThroughputOptionalParams ): Promise; - /** - * Gets the Cassandra view under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - getCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesGetCassandraViewOptionalParams - ): Promise; - /** - * Create or update an Azure Cosmos DB Cassandra View - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param createUpdateCassandraViewParameters The parameters to provide for the current Cassandra View. - * @param options The options parameters. - */ - beginCreateUpdateCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - createUpdateCassandraViewParameters: CassandraViewCreateUpdateParameters, - options?: CassandraResourcesCreateUpdateCassandraViewOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesCreateUpdateCassandraViewResponse - > - >; - /** - * Create or update an Azure Cosmos DB Cassandra View - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param createUpdateCassandraViewParameters The parameters to provide for the current Cassandra View. - * @param options The options parameters. - */ - beginCreateUpdateCassandraViewAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - createUpdateCassandraViewParameters: CassandraViewCreateUpdateParameters, - options?: CassandraResourcesCreateUpdateCassandraViewOptionalParams - ): Promise; - /** - * Deletes an existing Azure Cosmos DB Cassandra view. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginDeleteCassandraView( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesDeleteCassandraViewOptionalParams - ): Promise, void>>; - /** - * Deletes an existing Azure Cosmos DB Cassandra view. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginDeleteCassandraViewAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesDeleteCassandraViewOptionalParams - ): Promise; - /** - * Gets the RUs per second of the Cassandra view under an existing Azure Cosmos DB database account - * with the provided name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - getCassandraViewThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesGetCassandraViewThroughputOptionalParams - ): Promise; - /** - * Update RUs per second of an Azure Cosmos DB Cassandra view - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param updateThroughputParameters The RUs per second of the parameters to provide for the current - * Cassandra view. - * @param options The options parameters. - */ - beginUpdateCassandraViewThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - updateThroughputParameters: ThroughputSettingsUpdateParameters, - options?: CassandraResourcesUpdateCassandraViewThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesUpdateCassandraViewThroughputResponse - > - >; - /** - * Update RUs per second of an Azure Cosmos DB Cassandra view - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param updateThroughputParameters The RUs per second of the parameters to provide for the current - * Cassandra view. - * @param options The options parameters. - */ - beginUpdateCassandraViewThroughputAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - updateThroughputParameters: ThroughputSettingsUpdateParameters, - options?: CassandraResourcesUpdateCassandraViewThroughputOptionalParams - ): Promise; - /** - * Migrate an Azure Cosmos DB Cassandra view from manual throughput to autoscale - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginMigrateCassandraViewToAutoscale( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - CassandraResourcesMigrateCassandraViewToAutoscaleResponse - > - >; - /** - * Migrate an Azure Cosmos DB Cassandra view from manual throughput to autoscale - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginMigrateCassandraViewToAutoscaleAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToAutoscaleOptionalParams - ): Promise; - /** - * Migrate an Azure Cosmos DB Cassandra view from autoscale to manual throughput - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginMigrateCassandraViewToManualThroughput( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - CassandraResourcesMigrateCassandraViewToManualThroughputResponse - >, - CassandraResourcesMigrateCassandraViewToManualThroughputResponse - > - >; - /** - * Migrate an Azure Cosmos DB Cassandra view from autoscale to manual throughput - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param keyspaceName Cosmos DB keyspace name. - * @param viewName Cosmos DB view name. - * @param options The options parameters. - */ - beginMigrateCassandraViewToManualThroughputAndWait( - resourceGroupName: string, - accountName: string, - keyspaceName: string, - viewName: string, - options?: CassandraResourcesMigrateCassandraViewToManualThroughputOptionalParams - ): Promise; } diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/dataTransferJobs.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/dataTransferJobs.ts deleted file mode 100644 index ba391a27b49f..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/dataTransferJobs.ts +++ /dev/null @@ -1,107 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { - DataTransferJobGetResults, - DataTransferJobsListByDatabaseAccountOptionalParams, - CreateJobRequest, - DataTransferJobsCreateOptionalParams, - DataTransferJobsCreateResponse, - DataTransferJobsGetOptionalParams, - DataTransferJobsGetResponse, - DataTransferJobsPauseOptionalParams, - DataTransferJobsPauseResponse, - DataTransferJobsResumeOptionalParams, - DataTransferJobsResumeResponse, - DataTransferJobsCancelOptionalParams, - DataTransferJobsCancelResponse -} from "../models"; - -/// -/** Interface representing a DataTransferJobs. */ -export interface DataTransferJobs { - /** - * Get a list of Data Transfer jobs. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - listByDatabaseAccount( - resourceGroupName: string, - accountName: string, - options?: DataTransferJobsListByDatabaseAccountOptionalParams - ): PagedAsyncIterableIterator; - /** - * Creates a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param jobCreateParameters Parameters to create Data Transfer Job - * @param options The options parameters. - */ - create( - resourceGroupName: string, - accountName: string, - jobName: string, - jobCreateParameters: CreateJobRequest, - options?: DataTransferJobsCreateOptionalParams - ): Promise; - /** - * Get a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - get( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsGetOptionalParams - ): Promise; - /** - * Pause a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - pause( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsPauseOptionalParams - ): Promise; - /** - * Resumes a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - resume( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsResumeOptionalParams - ): Promise; - /** - * Cancels a Data Transfer Job. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param jobName Name of the Data Transfer Job - * @param options The options parameters. - */ - cancel( - resourceGroupName: string, - accountName: string, - jobName: string, - options?: DataTransferJobsCancelOptionalParams - ): Promise; -} diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/graphResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/graphResources.ts deleted file mode 100644 index b32ac0f5f5de..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/graphResources.ts +++ /dev/null @@ -1,110 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - GraphResourceGetResults, - GraphResourcesListGraphsOptionalParams, - GraphResourcesGetGraphOptionalParams, - GraphResourcesGetGraphResponse, - GraphResourceCreateUpdateParameters, - GraphResourcesCreateUpdateGraphOptionalParams, - GraphResourcesCreateUpdateGraphResponse, - GraphResourcesDeleteGraphResourceOptionalParams -} from "../models"; - -/// -/** Interface representing a GraphResources. */ -export interface GraphResources { - /** - * Lists the graphs under an existing Azure Cosmos DB database account. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param options The options parameters. - */ - listGraphs( - resourceGroupName: string, - accountName: string, - options?: GraphResourcesListGraphsOptionalParams - ): PagedAsyncIterableIterator; - /** - * Gets the Graph resource under an existing Azure Cosmos DB database account with the provided name. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - getGraph( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesGetGraphOptionalParams - ): Promise; - /** - * Create or update an Azure Cosmos DB Graph. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param createUpdateGraphParameters The parameters to provide for the current graph. - * @param options The options parameters. - */ - beginCreateUpdateGraph( - resourceGroupName: string, - accountName: string, - graphName: string, - createUpdateGraphParameters: GraphResourceCreateUpdateParameters, - options?: GraphResourcesCreateUpdateGraphOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - GraphResourcesCreateUpdateGraphResponse - > - >; - /** - * Create or update an Azure Cosmos DB Graph. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param createUpdateGraphParameters The parameters to provide for the current graph. - * @param options The options parameters. - */ - beginCreateUpdateGraphAndWait( - resourceGroupName: string, - accountName: string, - graphName: string, - createUpdateGraphParameters: GraphResourceCreateUpdateParameters, - options?: GraphResourcesCreateUpdateGraphOptionalParams - ): Promise; - /** - * Deletes an existing Azure Cosmos DB Graph Resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - beginDeleteGraphResource( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesDeleteGraphResourceOptionalParams - ): Promise, void>>; - /** - * Deletes an existing Azure Cosmos DB Graph Resource. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param graphName Cosmos DB graph resource name. - * @param options The options parameters. - */ - beginDeleteGraphResourceAndWait( - resourceGroupName: string, - accountName: string, - graphName: string, - options?: GraphResourcesDeleteGraphResourceOptionalParams - ): Promise; -} diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/index.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/index.ts index 062f4d7ab604..96531b8c1b96 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/index.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/index.ts @@ -19,17 +19,14 @@ export * from "./collectionPartitionRegion"; export * from "./collectionPartition"; export * from "./partitionKeyRangeId"; export * from "./partitionKeyRangeIdRegion"; -export * from "./graphResources"; export * from "./sqlResources"; export * from "./mongoDBResources"; export * from "./tableResources"; export * from "./cassandraResources"; export * from "./gremlinResources"; export * from "./locations"; -export * from "./dataTransferJobs"; export * from "./cassandraClusters"; export * from "./cassandraDataCenters"; -export * from "./mongoClusters"; export * from "./notebookWorkspaces"; export * from "./privateEndpointConnections"; export * from "./privateLinkResources"; diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoClusters.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoClusters.ts deleted file mode 100644 index dee5339452f9..000000000000 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoClusters.ts +++ /dev/null @@ -1,275 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. - * Licensed under the MIT License. - * - * Code generated by Microsoft (R) AutoRest Code Generator. - * Changes may cause incorrect behavior and will be lost if the code is regenerated. - */ - -import { PagedAsyncIterableIterator } from "@azure/core-paging"; -import { SimplePollerLike, OperationState } from "@azure/core-lro"; -import { - MongoCluster, - MongoClustersListOptionalParams, - MongoClustersListByResourceGroupOptionalParams, - FirewallRule, - MongoClustersListFirewallRulesOptionalParams, - MongoClustersCreateOrUpdateOptionalParams, - MongoClustersCreateOrUpdateResponse, - MongoClustersGetOptionalParams, - MongoClustersGetResponse, - MongoClustersDeleteOptionalParams, - MongoClustersDeleteResponse, - MongoClusterUpdate, - MongoClustersUpdateOptionalParams, - MongoClustersUpdateResponse, - MongoClustersCreateOrUpdateFirewallRuleOptionalParams, - MongoClustersCreateOrUpdateFirewallRuleResponse, - MongoClustersDeleteFirewallRuleOptionalParams, - MongoClustersDeleteFirewallRuleResponse, - MongoClustersGetFirewallRuleOptionalParams, - MongoClustersGetFirewallRuleResponse, - CheckNameAvailabilityRequest, - MongoClustersCheckNameAvailabilityOptionalParams, - MongoClustersCheckNameAvailabilityResponse, - MongoClustersListConnectionStringsOptionalParams, - MongoClustersListConnectionStringsResponse -} from "../models"; - -/// -/** Interface representing a MongoClusters. */ -export interface MongoClusters { - /** - * List all the mongo clusters in a given subscription. - * @param options The options parameters. - */ - list( - options?: MongoClustersListOptionalParams - ): PagedAsyncIterableIterator; - /** - * List all the mongo clusters in a given resource group. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param options The options parameters. - */ - listByResourceGroup( - resourceGroupName: string, - options?: MongoClustersListByResourceGroupOptionalParams - ): PagedAsyncIterableIterator; - /** - * List all the firewall rules in a given mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - listFirewallRules( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListFirewallRulesOptionalParams - ): PagedAsyncIterableIterator; - /** - * Create or update a mongo cluster. Update overwrites all properties for the resource. To only modify - * some of the properties, use PATCH. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The required parameters for creating or updating a mongo cluster. - * @param options The options parameters. - */ - beginCreateOrUpdate( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoCluster, - options?: MongoClustersCreateOrUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersCreateOrUpdateResponse - > - >; - /** - * Create or update a mongo cluster. Update overwrites all properties for the resource. To only modify - * some of the properties, use PATCH. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The required parameters for creating or updating a mongo cluster. - * @param options The options parameters. - */ - beginCreateOrUpdateAndWait( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoCluster, - options?: MongoClustersCreateOrUpdateOptionalParams - ): Promise; - /** - * Gets information about a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - get( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersGetOptionalParams - ): Promise; - /** - * Deletes a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - beginDelete( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersDeleteOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersDeleteResponse - > - >; - /** - * Deletes a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - beginDeleteAndWait( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersDeleteOptionalParams - ): Promise; - /** - * Updates an existing mongo cluster. The request body can contain one to many of the properties - * present in the normal mongo cluster definition. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The parameters for updating a mongo cluster. - * @param options The options parameters. - */ - beginUpdate( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoClusterUpdate, - options?: MongoClustersUpdateOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersUpdateResponse - > - >; - /** - * Updates an existing mongo cluster. The request body can contain one to many of the properties - * present in the normal mongo cluster definition. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param parameters The parameters for updating a mongo cluster. - * @param options The options parameters. - */ - beginUpdateAndWait( - resourceGroupName: string, - mongoClusterName: string, - parameters: MongoClusterUpdate, - options?: MongoClustersUpdateOptionalParams - ): Promise; - /** - * Creates a new firewall rule or updates an existing firewall rule on a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param parameters The required parameters for creating or updating a firewall rule. - * @param options The options parameters. - */ - beginCreateOrUpdateFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - parameters: FirewallRule, - options?: MongoClustersCreateOrUpdateFirewallRuleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersCreateOrUpdateFirewallRuleResponse - > - >; - /** - * Creates a new firewall rule or updates an existing firewall rule on a mongo cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param parameters The required parameters for creating or updating a firewall rule. - * @param options The options parameters. - */ - beginCreateOrUpdateFirewallRuleAndWait( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - parameters: FirewallRule, - options?: MongoClustersCreateOrUpdateFirewallRuleOptionalParams - ): Promise; - /** - * Deletes a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - beginDeleteFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersDeleteFirewallRuleOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoClustersDeleteFirewallRuleResponse - > - >; - /** - * Deletes a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - beginDeleteFirewallRuleAndWait( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersDeleteFirewallRuleOptionalParams - ): Promise; - /** - * Gets information about a mongo cluster firewall rule. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param firewallRuleName The name of the mongo cluster firewall rule. - * @param options The options parameters. - */ - getFirewallRule( - resourceGroupName: string, - mongoClusterName: string, - firewallRuleName: string, - options?: MongoClustersGetFirewallRuleOptionalParams - ): Promise; - /** - * Check the availability of name for resource - * @param location The name of the Azure region. - * @param parameters The required parameters for checking if resource name is available. - * @param options The options parameters. - */ - checkNameAvailability( - location: string, - parameters: CheckNameAvailabilityRequest, - options?: MongoClustersCheckNameAvailabilityOptionalParams - ): Promise; - /** - * List mongo cluster connection strings. This includes the default connection string using - * SCRAM-SHA-256, as well as other connection strings supported by the cluster. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param mongoClusterName The name of the mongo cluster. - * @param options The options parameters. - */ - listConnectionStrings( - resourceGroupName: string, - mongoClusterName: string, - options?: MongoClustersListConnectionStringsOptionalParams - ): Promise; -} diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoDBResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoDBResources.ts index c9b9a1a996f2..c21d235c6613 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoDBResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/mongoDBResources.ts @@ -33,16 +33,6 @@ import { MongoDBResourcesMigrateMongoDBDatabaseToAutoscaleResponse, MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputOptionalParams, MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputResponse, - RetrieveThroughputParameters, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse, - RedistributeThroughputParameters, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse, - MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams, - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse, MongoDBResourcesGetMongoDBCollectionOptionalParams, MongoDBResourcesGetMongoDBCollectionResponse, MongoDBCollectionCreateUpdateParameters, @@ -50,11 +40,6 @@ import { MongoDBResourcesCreateUpdateMongoDBCollectionResponse, MongoDBResourcesDeleteMongoDBCollectionOptionalParams, MongoDBResourcesDeleteMongoDBCollectionResponse, - MergeParameters, - MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams, - MongoDBResourcesMongoDBDatabasePartitionMergeResponse, - MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams, - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse, MongoDBResourcesGetMongoDBCollectionThroughputOptionalParams, MongoDBResourcesGetMongoDBCollectionThroughputResponse, MongoDBResourcesUpdateMongoDBCollectionThroughputOptionalParams, @@ -326,174 +311,6 @@ export interface MongoDBResources { databaseName: string, options?: MongoDBResourcesMigrateMongoDBDatabaseToManualThroughputOptionalParams ): Promise; - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB database. - * @param options The options parameters. - */ - beginMongoDBDatabaseRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - >, - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - > - >; - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB database. - * @param options The options parameters. - */ - beginMongoDBDatabaseRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - MongoDBResourcesMongoDBDatabaseRetrieveThroughputDistributionResponse - >; - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB database. - * @param options The options parameters. - */ - beginMongoDBDatabaseRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse - >, - MongoDBResourcesMongoDBDatabaseRedistributeThroughputResponse - > - >; - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB database. - * @param options The options parameters. - */ - beginMongoDBDatabaseRedistributeThroughputAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBDatabaseRedistributeThroughputOptionalParams - ): Promise; - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB container. - * @param options The options parameters. - */ - beginMongoDBContainerRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - >, - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - > - >; - /** - * Retrieve throughput distribution for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current MongoDB container. - * @param options The options parameters. - */ - beginMongoDBContainerRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - MongoDBResourcesMongoDBContainerRetrieveThroughputDistributionResponse - >; - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB container. - * @param options The options parameters. - */ - beginMongoDBContainerRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse - >, - MongoDBResourcesMongoDBContainerRedistributeThroughputResponse - > - >; - /** - * Redistribute throughput for an Azure Cosmos DB MongoDB container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current MongoDB container. - * @param options The options parameters. - */ - beginMongoDBContainerRedistributeThroughputAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: MongoDBResourcesMongoDBContainerRedistributeThroughputOptionalParams - ): Promise; /** * Gets the MongoDB collection under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -585,82 +402,6 @@ export interface MongoDBResources { collectionName: string, options?: MongoDBResourcesDeleteMongoDBCollectionOptionalParams ): Promise; - /** - * Merges the partitions of a MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginMongoDBDatabasePartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - MongoDBResourcesMongoDBDatabasePartitionMergeResponse - > - >; - /** - * Merges the partitions of a MongoDB database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginMongoDBDatabasePartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesMongoDBDatabasePartitionMergeOptionalParams - ): Promise; - /** - * Merges the partitions of a MongoDB Collection - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginListMongoDBCollectionPartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse - >, - MongoDBResourcesListMongoDBCollectionPartitionMergeResponse - > - >; - /** - * Merges the partitions of a MongoDB Collection - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param collectionName Cosmos DB collection name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginListMongoDBCollectionPartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - collectionName: string, - mergeParameters: MergeParameters, - options?: MongoDBResourcesListMongoDBCollectionPartitionMergeOptionalParams - ): Promise; /** * Gets the RUs per second of the MongoDB collection under an existing Azure Cosmos DB database account * with the provided name. diff --git a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/sqlResources.ts b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/sqlResources.ts index 88522df32617..df2919fe6ed6 100644 --- a/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/sqlResources.ts +++ b/sdk/cosmosdb/arm-cosmosdb/src/operationsInterfaces/sqlResources.ts @@ -11,10 +11,10 @@ import { SimplePollerLike, OperationState } from "@azure/core-lro"; import { SqlDatabaseGetResults, SqlResourcesListSqlDatabasesOptionalParams, - ClientEncryptionKeyGetResults, - SqlResourcesListClientEncryptionKeysOptionalParams, SqlContainerGetResults, SqlResourcesListSqlContainersOptionalParams, + ClientEncryptionKeyGetResults, + SqlResourcesListClientEncryptionKeysOptionalParams, SqlStoredProcedureGetResults, SqlResourcesListSqlStoredProceduresOptionalParams, SqlUserDefinedFunctionGetResults, @@ -41,11 +41,6 @@ import { SqlResourcesMigrateSqlDatabaseToAutoscaleResponse, SqlResourcesMigrateSqlDatabaseToManualThroughputOptionalParams, SqlResourcesMigrateSqlDatabaseToManualThroughputResponse, - SqlResourcesGetClientEncryptionKeyOptionalParams, - SqlResourcesGetClientEncryptionKeyResponse, - ClientEncryptionKeyCreateUpdateParameters, - SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams, - SqlResourcesCreateUpdateClientEncryptionKeyResponse, SqlResourcesGetSqlContainerOptionalParams, SqlResourcesGetSqlContainerResponse, SqlContainerCreateUpdateParameters, @@ -53,11 +48,6 @@ import { SqlResourcesCreateUpdateSqlContainerResponse, SqlResourcesDeleteSqlContainerOptionalParams, SqlResourcesDeleteSqlContainerResponse, - MergeParameters, - SqlResourcesSqlDatabasePartitionMergeOptionalParams, - SqlResourcesSqlDatabasePartitionMergeResponse, - SqlResourcesListSqlContainerPartitionMergeOptionalParams, - SqlResourcesListSqlContainerPartitionMergeResponse, SqlResourcesGetSqlContainerThroughputOptionalParams, SqlResourcesGetSqlContainerThroughputResponse, SqlResourcesUpdateSqlContainerThroughputOptionalParams, @@ -66,16 +56,11 @@ import { SqlResourcesMigrateSqlContainerToAutoscaleResponse, SqlResourcesMigrateSqlContainerToManualThroughputOptionalParams, SqlResourcesMigrateSqlContainerToManualThroughputResponse, - RetrieveThroughputParameters, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse, - RedistributeThroughputParameters, - SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams, - SqlResourcesSqlDatabaseRedistributeThroughputResponse, - SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams, - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse, - SqlResourcesSqlContainerRedistributeThroughputOptionalParams, - SqlResourcesSqlContainerRedistributeThroughputResponse, + SqlResourcesGetClientEncryptionKeyOptionalParams, + SqlResourcesGetClientEncryptionKeyResponse, + ClientEncryptionKeyCreateUpdateParameters, + SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams, + SqlResourcesCreateUpdateClientEncryptionKeyResponse, SqlResourcesGetSqlStoredProcedureOptionalParams, SqlResourcesGetSqlStoredProcedureResponse, SqlStoredProcedureCreateUpdateParameters, @@ -129,31 +114,31 @@ export interface SqlResources { options?: SqlResourcesListSqlDatabasesOptionalParams ): PagedAsyncIterableIterator; /** - * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. + * Lists the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param options The options parameters. */ - listClientEncryptionKeys( + listSqlContainers( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListClientEncryptionKeysOptionalParams - ): PagedAsyncIterableIterator; + options?: SqlResourcesListSqlContainersOptionalParams + ): PagedAsyncIterableIterator; /** - * Lists the SQL container under an existing Azure Cosmos DB database account. + * Lists the ClientEncryptionKeys under an existing Azure Cosmos DB SQL database. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. * @param options The options parameters. */ - listSqlContainers( + listClientEncryptionKeys( resourceGroupName: string, accountName: string, databaseName: string, - options?: SqlResourcesListSqlContainersOptionalParams - ): PagedAsyncIterableIterator; + options?: SqlResourcesListClientEncryptionKeysOptionalParams + ): PagedAsyncIterableIterator; /** * Lists the SQL storedProcedure under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -413,64 +398,6 @@ export interface SqlResources { databaseName: string, options?: SqlResourcesMigrateSqlDatabaseToManualThroughputOptionalParams ): Promise; - /** - * Gets the ClientEncryptionKey under an existing Azure Cosmos DB SQL database. - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param options The options parameters. - */ - getClientEncryptionKey( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - options?: SqlResourcesGetClientEncryptionKeyOptionalParams - ): Promise; - /** - * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure - * Powershell (instead of directly). - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption - * key. - * @param options The options parameters. - */ - beginCreateUpdateClientEncryptionKey( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, - options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesCreateUpdateClientEncryptionKeyResponse - > - >; - /** - * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure - * Powershell (instead of directly). - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. - * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption - * key. - * @param options The options parameters. - */ - beginCreateUpdateClientEncryptionKeyAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - clientEncryptionKeyName: string, - createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, - options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams - ): Promise; /** * Gets the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -560,80 +487,6 @@ export interface SqlResources { containerName: string, options?: SqlResourcesDeleteSqlContainerOptionalParams ): Promise; - /** - * Merges the partitions of a SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginSqlDatabasePartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesSqlDatabasePartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesSqlDatabasePartitionMergeResponse - > - >; - /** - * Merges the partitions of a SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginSqlDatabasePartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesSqlDatabasePartitionMergeOptionalParams - ): Promise; - /** - * Merges the partitions of a SQL Container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginListSqlContainerPartitionMerge( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesListSqlContainerPartitionMergeOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesListSqlContainerPartitionMergeResponse - > - >; - /** - * Merges the partitions of a SQL Container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param mergeParameters The parameters for the merge operation. - * @param options The options parameters. - */ - beginListSqlContainerPartitionMergeAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - mergeParameters: MergeParameters, - options?: SqlResourcesListSqlContainerPartitionMergeOptionalParams - ): Promise; /** * Gets the RUs per second of the SQL container under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -761,165 +614,63 @@ export interface SqlResources { options?: SqlResourcesMigrateSqlContainerToManualThroughputOptionalParams ): Promise; /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL database. - * @param options The options parameters. - */ - beginSqlDatabaseRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse - >, - SqlResourcesSqlDatabaseRetrieveThroughputDistributionResponse - > - >; - /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL database. - * @param options The options parameters. - */ - beginSqlDatabaseRetrieveThroughputDistributionAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlDatabaseRetrieveThroughputDistributionOptionalParams - ): Promise; - /** - * Redistribute throughput for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL database. - * @param options The options parameters. - */ - beginSqlDatabaseRedistributeThroughput( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams - ): Promise< - SimplePollerLike< - OperationState, - SqlResourcesSqlDatabaseRedistributeThroughputResponse - > - >; - /** - * Redistribute throughput for an Azure Cosmos DB SQL database - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL database. - * @param options The options parameters. - */ - beginSqlDatabaseRedistributeThroughputAndWait( - resourceGroupName: string, - accountName: string, - databaseName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlDatabaseRedistributeThroughputOptionalParams - ): Promise; - /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL container - * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param accountName Cosmos DB database account name. - * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL container. - * @param options The options parameters. - */ - beginSqlContainerRetrieveThroughputDistribution( - resourceGroupName: string, - accountName: string, - databaseName: string, - containerName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams - ): Promise< - SimplePollerLike< - OperationState< - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse - >, - SqlResourcesSqlContainerRetrieveThroughputDistributionResponse - > - >; - /** - * Retrieve throughput distribution for an Azure Cosmos DB SQL container + * Gets the ClientEncryptionKey under an existing Azure Cosmos DB SQL database. * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param retrieveThroughputParameters The parameters to provide for retrieving throughput distribution - * for the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. * @param options The options parameters. */ - beginSqlContainerRetrieveThroughputDistributionAndWait( + getClientEncryptionKey( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - retrieveThroughputParameters: RetrieveThroughputParameters, - options?: SqlResourcesSqlContainerRetrieveThroughputDistributionOptionalParams - ): Promise; + clientEncryptionKeyName: string, + options?: SqlResourcesGetClientEncryptionKeyOptionalParams + ): Promise; /** - * Redistribute throughput for an Azure Cosmos DB SQL container + * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure + * Powershell (instead of directly). * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. + * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption + * key. * @param options The options parameters. */ - beginSqlContainerRedistributeThroughput( + beginCreateUpdateClientEncryptionKey( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlContainerRedistributeThroughputOptionalParams + clientEncryptionKeyName: string, + createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, + options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams ): Promise< SimplePollerLike< - OperationState, - SqlResourcesSqlContainerRedistributeThroughputResponse + OperationState, + SqlResourcesCreateUpdateClientEncryptionKeyResponse > >; /** - * Redistribute throughput for an Azure Cosmos DB SQL container + * Create or update a ClientEncryptionKey. This API is meant to be invoked via tools such as the Azure + * Powershell (instead of directly). * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param accountName Cosmos DB database account name. * @param databaseName Cosmos DB database name. - * @param containerName Cosmos DB container name. - * @param redistributeThroughputParameters The parameters to provide for redistributing throughput for - * the current SQL container. + * @param clientEncryptionKeyName Cosmos DB ClientEncryptionKey name. + * @param createUpdateClientEncryptionKeyParameters The parameters to provide for the client encryption + * key. * @param options The options parameters. */ - beginSqlContainerRedistributeThroughputAndWait( + beginCreateUpdateClientEncryptionKeyAndWait( resourceGroupName: string, accountName: string, databaseName: string, - containerName: string, - redistributeThroughputParameters: RedistributeThroughputParameters, - options?: SqlResourcesSqlContainerRedistributeThroughputOptionalParams - ): Promise; + clientEncryptionKeyName: string, + createUpdateClientEncryptionKeyParameters: ClientEncryptionKeyCreateUpdateParameters, + options?: SqlResourcesCreateUpdateClientEncryptionKeyOptionalParams + ): Promise; /** * Gets the SQL storedProcedure under an existing Azure Cosmos DB database account. * @param resourceGroupName The name of the resource group. The name is case insensitive. diff --git a/sdk/cosmosdb/arm-cosmosdb/test/sampleTest.ts b/sdk/cosmosdb/arm-cosmosdb/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/cosmosdb/arm-cosmosdb/test/sampleTest.ts @@ -0,0 +1,43 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { + Recorder, + RecorderStartOptions, + env +} from "@azure-tools/test-recorder"; +import { assert } from "chai"; +import { Context } from "mocha"; + +const replaceableVariables: Record = { + AZURE_CLIENT_ID: "azure_client_id", + AZURE_CLIENT_SECRET: "azure_client_secret", + AZURE_TENANT_ID: "88888888-8888-8888-8888-888888888888", + SUBSCRIPTION_ID: "azure_subscription_id" +}; + +const recorderOptions: RecorderStartOptions = { + envSetupForPlayback: replaceableVariables +}; + +describe("My test", () => { + let recorder: Recorder; + + beforeEach(async function(this: Context) { + recorder = new Recorder(this.currentTest); + await recorder.start(recorderOptions); + }); + + afterEach(async function() { + await recorder.stop(); + }); + + it("sample test", async function() { + console.log("Hi, I'm a test!"); + }); +}); diff --git a/sdk/cosmosdb/arm-cosmosdb/tsconfig.json b/sdk/cosmosdb/arm-cosmosdb/tsconfig.json index bbcdce662fee..3e6ae96443f3 100644 --- a/sdk/cosmosdb/arm-cosmosdb/tsconfig.json +++ b/sdk/cosmosdb/arm-cosmosdb/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-cosmosdb": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"