From ec13acfda535c344f8f4f14e90d88a9f1568e34a Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 15 Mar 2022 03:45:12 +0000 Subject: [PATCH] CodeGen from PR 18193 in Azure/azure-rest-api-specs Merge 65898c1c672899037eff6da141b5a18b5180853a into 9aff6fbac1975af94f6a3bc415be84f67d3311ee --- .../arm-redisenterprisecache/CHANGELOG.md | 16 +++ .../arm-redisenterprisecache/_meta.json | 7 +- .../api-extractor.json | 25 +++- .../arm-redisenterprisecache/package.json | 36 +++--- .../review/arm-redisenterprisecache.api.md | 44 +++++++ .../src/models/index.ts | 62 ++++++++- .../src/models/mappers.ts | 84 +++++++++++++ .../src/models/parameters.ts | 8 +- .../src/operations/databases.ts | 119 ++++++++++++++++++ .../src/operationsInterfaces/databases.ts | 34 ++++- .../src/redisEnterpriseManagementClient.ts | 4 +- .../arm-redisenterprisecache/tsconfig.json | 19 ++- sdk/redisenterprise/ci.mgmt.yml | 7 +- 13 files changed, 422 insertions(+), 43 deletions(-) diff --git a/sdk/redisenterprise/arm-redisenterprisecache/CHANGELOG.md b/sdk/redisenterprise/arm-redisenterprisecache/CHANGELOG.md index 0d3ba054309c..efa205490461 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/CHANGELOG.md +++ b/sdk/redisenterprise/arm-redisenterprisecache/CHANGELOG.md @@ -1,5 +1,21 @@ # Release History +## 2.1.0 (2022-03-15) + +**Features** + + - Added operation Databases.beginForceUnlink + - Added operation Databases.beginForceUnlinkAndWait + - Added Interface DatabasePropertiesGeoReplication + - Added Interface DatabasesForceUnlinkOptionalParams + - Added Interface ForceUnlinkParameters + - Added Interface LinkedDatabase + - Added Type Alias LinkState + - Interface DatabaseUpdate has a new optional parameter geoReplication + - Type Alias Database has a new parameter geoReplication + - Added Enum KnownLinkState + + ## 2.0.0 (2022-01-20) The package of @azure/arm-redisenterprisecache is using our next generation design principles since version 2.0.0, which contains breaking changes. diff --git a/sdk/redisenterprise/arm-redisenterprisecache/_meta.json b/sdk/redisenterprise/arm-redisenterprisecache/_meta.json index 4ea87dcfb2cb..32182543b3f2 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/_meta.json +++ b/sdk/redisenterprise/arm-redisenterprisecache/_meta.json @@ -1,7 +1,8 @@ { - "commit": "f9a6cb686bcc0f1b23761db19f2491c5c4df95cb", + "commit": "e7da1b7cefd3d42a4d97145ffe9e0336da08cea0", "readme": "specification/redisenterprise/resource-manager/readme.md", - "autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\mydev\\azure-sdk-for-js ../azure-rest-api-specs/specification/redisenterprise/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.16.20220114.1 --generate-sample=true", + "autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/home/vsts/work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/redisenterprise/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.16.20220105.1", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "use": "@autorest/typescript@6.0.0-alpha.16.20220114.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.1.1", + "use": "@autorest/typescript@6.0.0-alpha.16.20220105.1" } \ No newline at end of file diff --git a/sdk/redisenterprise/arm-redisenterprisecache/api-extractor.json b/sdk/redisenterprise/arm-redisenterprisecache/api-extractor.json index aa467acd6d7c..96c3a6e4a1c6 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/api-extractor.json +++ b/sdk/redisenterprise/arm-redisenterprisecache/api-extractor.json @@ -1,18 +1,31 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", "mainEntryPointFilePath": "./dist-esm/src/index.d.ts", - "docModel": { "enabled": true }, - "apiReport": { "enabled": true, "reportFolder": "./review" }, + "docModel": { + "enabled": true + }, + "apiReport": { + "enabled": true, + "reportFolder": "./review" + }, "dtsRollup": { "enabled": true, "untrimmedFilePath": "", "publicTrimmedFilePath": "./types/arm-redisenterprisecache.d.ts" }, "messages": { - "tsdocMessageReporting": { "default": { "logLevel": "none" } }, + "tsdocMessageReporting": { + "default": { + "logLevel": "none" + } + }, "extractorMessageReporting": { - "ae-missing-release-tag": { "logLevel": "none" }, - "ae-unresolved-link": { "logLevel": "none" } + "ae-missing-release-tag": { + "logLevel": "none" + }, + "ae-unresolved-link": { + "logLevel": "none" + } } } -} +} \ No newline at end of file diff --git a/sdk/redisenterprise/arm-redisenterprisecache/package.json b/sdk/redisenterprise/arm-redisenterprisecache/package.json index 348e9edd5b56..13c2ae7672dc 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/package.json +++ b/sdk/redisenterprise/arm-redisenterprisecache/package.json @@ -3,8 +3,10 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for RedisEnterpriseManagementClient.", - "version": "2.0.0", - "engines": { "node": ">=12.0.0" }, + "version": "2.1.0", + "engines": { + "node": ">=12.0.0" + }, "dependencies": { "@azure/core-lro": "^2.2.0", "@azure/abort-controller": "^1.0.0", @@ -14,7 +16,13 @@ "@azure/core-rest-pipeline": "^1.1.0", "tslib": "^2.2.0" }, - "keywords": ["node", "azure", "typescript", "browser", "isomorphic"], + "keywords": [ + "node", + "azure", + "typescript", + "browser", + "isomorphic" + ], "license": "MIT", "main": "./dist/index.js", "module": "./dist-esm/src/index.js", @@ -41,7 +49,9 @@ "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" }, - "bugs": { "url": "https://github.com/Azure/azure-sdk-for-js/issues" }, + "bugs": { + "url": "https://github.com/Azure/azure-sdk-for-js/issues" + }, "files": [ "dist/**/*.js", "dist/**/*.js.map", @@ -88,19 +98,5 @@ "docs": "echo skipped" }, "sideEffects": false, - "//metadata": { - "constantPaths": [ - { - "path": "src/RedisEnterpriseManagementClient.ts", - "prefix": "packageDetails" - } - ] - }, - "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": ["azure"], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-redisenterprisecache?view=azure-node-preview" - } -} + "autoPublish": true +} \ No newline at end of file diff --git a/sdk/redisenterprise/arm-redisenterprisecache/review/arm-redisenterprisecache.api.md b/sdk/redisenterprise/arm-redisenterprisecache/review/arm-redisenterprisecache.api.md index 51f77a9c4487..bfdf883104f7 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/review/arm-redisenterprisecache.api.md +++ b/sdk/redisenterprise/arm-redisenterprisecache/review/arm-redisenterprisecache.api.md @@ -70,6 +70,7 @@ export type Database = ProxyResource & { evictionPolicy?: EvictionPolicy; persistence?: Persistence; modules?: Module[]; + geoReplication?: DatabasePropertiesGeoReplication; }; // @public @@ -78,6 +79,12 @@ export interface DatabaseList { value?: Database[]; } +// @public +export interface DatabasePropertiesGeoReplication { + groupNickname?: string; + linkedDatabases?: LinkedDatabase[]; +} + // @public export interface Databases { beginCreate(resourceGroupName: string, clusterName: string, databaseName: string, parameters: Database, options?: DatabasesCreateOptionalParams): Promise, DatabasesCreateResponse>>; @@ -86,6 +93,8 @@ export interface Databases { beginDeleteAndWait(resourceGroupName: string, clusterName: string, databaseName: string, options?: DatabasesDeleteOptionalParams): Promise; beginExport(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ExportClusterParameters, options?: DatabasesExportOptionalParams): Promise, void>>; beginExportAndWait(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ExportClusterParameters, options?: DatabasesExportOptionalParams): Promise; + beginForceUnlink(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ForceUnlinkParameters, options?: DatabasesForceUnlinkOptionalParams): Promise, void>>; + beginForceUnlinkAndWait(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ForceUnlinkParameters, options?: DatabasesForceUnlinkOptionalParams): Promise; beginImport(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ImportClusterParameters, options?: DatabasesImportOptionalParams): Promise, void>>; beginImportAndWait(resourceGroupName: string, clusterName: string, databaseName: string, parameters: ImportClusterParameters, options?: DatabasesImportOptionalParams): Promise; beginRegenerateKey(resourceGroupName: string, clusterName: string, databaseName: string, parameters: RegenerateKeyParameters, options?: DatabasesRegenerateKeyOptionalParams): Promise, DatabasesRegenerateKeyResponse>>; @@ -118,6 +127,12 @@ export interface DatabasesExportOptionalParams extends coreClient.OperationOptio updateIntervalInMs?: number; } +// @public +export interface DatabasesForceUnlinkOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + // @public export interface DatabasesGetOptionalParams extends coreClient.OperationOptions { } @@ -175,6 +190,7 @@ export interface DatabaseUpdate { clientProtocol?: Protocol; clusteringPolicy?: ClusteringPolicy; evictionPolicy?: EvictionPolicy; + geoReplication?: DatabasePropertiesGeoReplication; modules?: Module[]; persistence?: Persistence; port?: number; @@ -210,6 +226,11 @@ export interface ExportClusterParameters { sasUri: string; } +// @public +export interface ForceUnlinkParameters { + ids: string[]; +} + // @public export interface ImportClusterParameters { sasUris: string[]; @@ -257,6 +278,20 @@ export enum KnownEvictionPolicy { VolatileTTL = "VolatileTTL" } +// @public +export enum KnownLinkState { + // (undocumented) + Linked = "Linked", + // (undocumented) + LinkFailed = "LinkFailed", + // (undocumented) + Linking = "Linking", + // (undocumented) + UnlinkFailed = "UnlinkFailed", + // (undocumented) + Unlinking = "Unlinking" +} + // @public export enum KnownOrigin { // (undocumented) @@ -379,6 +414,15 @@ export enum KnownTlsVersion { One2 = "1.2" } +// @public +export interface LinkedDatabase { + id?: string; + readonly state?: LinkState; +} + +// @public +export type LinkState = string; + // @public export interface Module { args?: string; diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/models/index.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/models/index.ts index d2481bd0e776..b688726da85c 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/models/index.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/models/index.ts @@ -256,7 +256,7 @@ export interface Persistence { export interface Module { /** The name of the module, e.g. 'RedisBloom', 'RediSearch', 'RedisTimeSeries' */ name: string; - /** Configuration options for the module, e.g. 'ERROR_RATE 0.00 INITIAL_SIZE 400'. */ + /** Configuration options for the module, e.g. 'ERROR_RATE 0.01 INITIAL_SIZE 400'. */ args?: string; /** * The version of the module, e.g. '1.0'. @@ -265,6 +265,25 @@ export interface Module { readonly version?: string; } +/** Optional set of properties to configure geo replication for this database. */ +export interface DatabasePropertiesGeoReplication { + /** Name for the group of linked database resources */ + groupNickname?: string; + /** List of database resources to link with this database */ + linkedDatabases?: LinkedDatabase[]; +} + +/** Specifies details of a linked database resource. */ +export interface LinkedDatabase { + /** Resource ID of a database resource to link with this database. */ + id?: string; + /** + * State of the link between the database resources. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly state?: LinkState; +} + /** A partial update to the RedisEnterprise database */ export interface DatabaseUpdate { /** Specifies whether redis clients can connect using TLS-encrypted or plaintext redis protocols. Default is TLS-encrypted. */ @@ -289,6 +308,8 @@ export interface DatabaseUpdate { persistence?: Persistence; /** Optional set of redis modules to enable in this database - modules can only be added at creation time. */ modules?: Module[]; + /** Optional set of properties to configure geo replication for this database. */ + geoReplication?: DatabasePropertiesGeoReplication; } /** The secret access keys used for authenticating connections to redis */ @@ -335,6 +356,12 @@ export interface PrivateLinkResourceListResult { value?: PrivateLinkResource[]; } +/** Parameters for a Redis Enterprise Active Geo Replication Force Unlink operation. */ +export interface ForceUnlinkParameters { + /** The resource IDs of the database resources to be unlinked. */ + ids: string[]; +} + /** The Private Endpoint Connection resource. */ export type PrivateEndpointConnection = Resource & { /** The resource of private end point. */ @@ -434,6 +461,8 @@ export type Database = ProxyResource & { persistence?: Persistence; /** Optional set of redis modules to enable in this database - modules can only be added at creation time. */ modules?: Module[]; + /** Optional set of properties to configure geo replication for this database. */ + geoReplication?: DatabasePropertiesGeoReplication; }; /** Known values of {@link Origin} that the service accepts. */ @@ -703,6 +732,28 @@ export enum KnownRdbFrequency { * **12h** */ export type RdbFrequency = string; + +/** Known values of {@link LinkState} that the service accepts. */ +export enum KnownLinkState { + Linked = "Linked", + Linking = "Linking", + Unlinking = "Unlinking", + LinkFailed = "LinkFailed", + UnlinkFailed = "UnlinkFailed" +} + +/** + * Defines values for LinkState. \ + * {@link KnownLinkState} can be used interchangeably with LinkState, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **Linked** \ + * **Linking** \ + * **Unlinking** \ + * **LinkFailed** \ + * **UnlinkFailed** + */ +export type LinkState = string; /** Defines values for AccessKeyType. */ export type AccessKeyType = "Primary" | "Secondary"; @@ -879,6 +930,15 @@ export interface DatabasesExportOptionalParams resumeFrom?: string; } +/** Optional parameters. */ +export interface DatabasesForceUnlinkOptionalParams + 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 DatabasesListByClusterNextOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/models/mappers.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/models/mappers.ts index 197f60139550..7e9608ab2454 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/models/mappers.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/models/mappers.ts @@ -543,6 +543,55 @@ export const Module: coreClient.CompositeMapper = { } }; +export const DatabasePropertiesGeoReplication: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "DatabasePropertiesGeoReplication", + modelProperties: { + groupNickname: { + serializedName: "groupNickname", + type: { + name: "String" + } + }, + linkedDatabases: { + serializedName: "linkedDatabases", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "LinkedDatabase" + } + } + } + } + } + } +}; + +export const LinkedDatabase: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "LinkedDatabase", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + state: { + serializedName: "state", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + export const DatabaseUpdate: coreClient.CompositeMapper = { type: { name: "Composite", @@ -604,6 +653,13 @@ export const DatabaseUpdate: coreClient.CompositeMapper = { } } } + }, + geoReplication: { + serializedName: "properties.geoReplication", + type: { + name: "Composite", + className: "DatabasePropertiesGeoReplication" + } } } } @@ -728,6 +784,27 @@ export const PrivateLinkResourceListResult: coreClient.CompositeMapper = { } }; +export const ForceUnlinkParameters: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ForceUnlinkParameters", + modelProperties: { + ids: { + serializedName: "ids", + required: true, + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + export const PrivateEndpointConnection: coreClient.CompositeMapper = { type: { name: "Composite", @@ -970,6 +1047,13 @@ export const Database: coreClient.CompositeMapper = { } } } + }, + geoReplication: { + serializedName: "properties.geoReplication", + type: { + name: "Composite", + className: "DatabasePropertiesGeoReplication" + } } } } diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/models/parameters.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/models/parameters.ts index 0d3fb87eca50..eb599b1f0600 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/models/parameters.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/models/parameters.ts @@ -19,6 +19,7 @@ import { RegenerateKeyParameters as RegenerateKeyParametersMapper, ImportClusterParameters as ImportClusterParametersMapper, ExportClusterParameters as ExportClusterParametersMapper, + ForceUnlinkParameters as ForceUnlinkParametersMapper, PrivateEndpointConnection as PrivateEndpointConnectionMapper } from "../models/mappers"; @@ -49,7 +50,7 @@ export const $host: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2021-08-01", + defaultValue: "2022-01-01", isConstant: true, serializedName: "api-version", type: { @@ -190,6 +191,11 @@ export const parameters6: OperationParameter = { mapper: ExportClusterParametersMapper }; +export const parameters7: OperationParameter = { + parameterPath: "parameters", + mapper: ForceUnlinkParametersMapper +}; + export const privateEndpointConnectionName: OperationURLParameter = { parameterPath: "privateEndpointConnectionName", mapper: { diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/operations/databases.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/operations/databases.ts index 71867cabd88a..bf4ec5983cf2 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/operations/databases.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/operations/databases.ts @@ -36,6 +36,8 @@ import { DatabasesImportOptionalParams, ExportClusterParameters, DatabasesExportOptionalParams, + ForceUnlinkParameters, + DatabasesForceUnlinkOptionalParams, DatabasesListByClusterNextResponse } from "../models"; @@ -734,6 +736,97 @@ export class DatabasesImpl implements Databases { return poller.pollUntilDone(); } + /** + * Forcibly removes the link to the specified database resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the RedisEnterprise cluster. + * @param databaseName The name of the database. + * @param parameters Information identifying the database to be unlinked. + * @param options The options parameters. + */ + async beginForceUnlink( + resourceGroupName: string, + clusterName: string, + databaseName: string, + parameters: ForceUnlinkParameters, + options?: DatabasesForceUnlinkOptionalParams + ): Promise, void>> { + const directSendOperation = async ( + args: coreClient.OperationArguments, + spec: coreClient.OperationSpec + ): Promise => { + return this.client.sendOperationRequest(args, spec); + }; + const sendOperation = 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 = new LroImpl( + sendOperation, + { resourceGroupName, clusterName, databaseName, parameters, options }, + forceUnlinkOperationSpec + ); + return new LroEngine(lro, { + resumeFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + lroResourceLocationConfig: "azure-async-operation" + }); + } + + /** + * Forcibly removes the link to the specified database resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the RedisEnterprise cluster. + * @param databaseName The name of the database. + * @param parameters Information identifying the database to be unlinked. + * @param options The options parameters. + */ + async beginForceUnlinkAndWait( + resourceGroupName: string, + clusterName: string, + databaseName: string, + parameters: ForceUnlinkParameters, + options?: DatabasesForceUnlinkOptionalParams + ): Promise { + const poller = await this.beginForceUnlink( + resourceGroupName, + clusterName, + databaseName, + parameters, + options + ); + return poller.pollUntilDone(); + } + /** * ListByClusterNext * @param resourceGroupName The name of the resource group. The name is case insensitive. @@ -1002,6 +1095,32 @@ const exportOperationSpec: coreClient.OperationSpec = { mediaType: "json", serializer }; +const forceUnlinkOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cache/redisEnterprise/{clusterName}/databases/{databaseName}/forceUnlink", + httpMethod: "POST", + responses: { + 200: {}, + 201: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.parameters7, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.clusterName, + Parameters.databaseName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; const listByClusterNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/operationsInterfaces/databases.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/operationsInterfaces/databases.ts index 2da2b5aacdef..714e0bdd497b 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/operationsInterfaces/databases.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/operationsInterfaces/databases.ts @@ -27,7 +27,9 @@ import { ImportClusterParameters, DatabasesImportOptionalParams, ExportClusterParameters, - DatabasesExportOptionalParams + DatabasesExportOptionalParams, + ForceUnlinkParameters, + DatabasesForceUnlinkOptionalParams } from "../models"; /// @@ -261,4 +263,34 @@ export interface Databases { parameters: ExportClusterParameters, options?: DatabasesExportOptionalParams ): Promise; + /** + * Forcibly removes the link to the specified database resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the RedisEnterprise cluster. + * @param databaseName The name of the database. + * @param parameters Information identifying the database to be unlinked. + * @param options The options parameters. + */ + beginForceUnlink( + resourceGroupName: string, + clusterName: string, + databaseName: string, + parameters: ForceUnlinkParameters, + options?: DatabasesForceUnlinkOptionalParams + ): Promise, void>>; + /** + * Forcibly removes the link to the specified database resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the RedisEnterprise cluster. + * @param databaseName The name of the database. + * @param parameters Information identifying the database to be unlinked. + * @param options The options parameters. + */ + beginForceUnlinkAndWait( + resourceGroupName: string, + clusterName: string, + databaseName: string, + parameters: ForceUnlinkParameters, + options?: DatabasesForceUnlinkOptionalParams + ): Promise; } diff --git a/sdk/redisenterprise/arm-redisenterprisecache/src/redisEnterpriseManagementClient.ts b/sdk/redisenterprise/arm-redisenterprisecache/src/redisEnterpriseManagementClient.ts index c8809c323349..a18691063c1e 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/src/redisEnterpriseManagementClient.ts +++ b/sdk/redisenterprise/arm-redisenterprisecache/src/redisEnterpriseManagementClient.ts @@ -58,7 +58,7 @@ export class RedisEnterpriseManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-redisenterprisecache/2.0.0`; + const packageDetails = `azsdk-js-arm-redisenterprisecache/2.1.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -81,7 +81,7 @@ export class RedisEnterpriseManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2021-08-01"; + this.apiVersion = options.apiVersion || "2022-01-01"; this.operations = new OperationsImpl(this); this.operationsStatus = new OperationsStatusImpl(this); this.redisEnterprise = new RedisEnterpriseImpl(this); diff --git a/sdk/redisenterprise/arm-redisenterprisecache/tsconfig.json b/sdk/redisenterprise/arm-redisenterprisecache/tsconfig.json index afe51717ab9e..3e6ae96443f3 100644 --- a/sdk/redisenterprise/arm-redisenterprisecache/tsconfig.json +++ b/sdk/redisenterprise/arm-redisenterprisecache/tsconfig.json @@ -9,12 +9,19 @@ "esModuleInterop": true, "allowSyntheticDefaultImports": true, "forceConsistentCasingInFileNames": true, - "lib": ["es6", "dom"], + "lib": [ + "es6", + "dom" + ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { "@azure/arm-redisenterprisecache": ["./src/index"] } + "importHelpers": true }, - "include": ["./src/**/*.ts", "./test/**/*.ts", "samples-dev/**/*.ts"], - "exclude": ["node_modules"] -} + "include": [ + "./src/**/*.ts", + "./test/**/*.ts" + ], + "exclude": [ + "node_modules" + ] +} \ No newline at end of file diff --git a/sdk/redisenterprise/ci.mgmt.yml b/sdk/redisenterprise/ci.mgmt.yml index cf29fc456058..25762671da79 100644 --- a/sdk/redisenterprise/ci.mgmt.yml +++ b/sdk/redisenterprise/ci.mgmt.yml @@ -1,5 +1,5 @@ # NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file. - + trigger: branches: include: @@ -10,6 +10,7 @@ trigger: include: - sdk/redisenterprise/ci.mgmt.yml - sdk/redisenterprise/arm-redisenterprise/ + - sdk/redisenterprise/arm-redisenterprisecache pr: branches: include: @@ -23,11 +24,11 @@ pr: include: - sdk/redisenterprise/ci.mgmt.yml - sdk/redisenterprise/arm-redisenterprise/ - + - sdk/redisenterprise/arm-redisenterprisecache extends: template: /eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: redisenterprise Artifacts: - name: azure-arm-redisenterprisecache - safeName: azurearmredisenterprisecache \ No newline at end of file + safeName: azurearmredisenterprisecache