diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 738fed458ab5..c768ebb11460 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -4136,7 +4136,7 @@ packages: dependencies: semver: 7.5.4 shelljs: 0.8.5 - typescript: 5.3.0-dev.20230811 + typescript: 5.3.0-dev.20230817 dev: false /ecdsa-sig-formatter/1.0.11: @@ -8721,8 +8721,8 @@ packages: hasBin: true dev: false - /typescript/5.3.0-dev.20230811: - resolution: {integrity: sha512-C4bwx7ZpBwX7bKxrrNl+M1j8yNGmwQ5M58X0mT4VYI1+FHqRvb/uJ4F1uJsVJ+X7iy22iXSICR/Vxnpc1gNk7w==} + /typescript/5.3.0-dev.20230817: + resolution: {integrity: sha512-WbPb4NIGIcx8fQG4JPh54lALvzPUJTcDLCP9xVsrfOMrMAWswPqqekMZ7jVpasCOmYtC9e+oUCpW+jgVVcW7UQ==} engines: {node: '>=14.17'} hasBin: true dev: false @@ -15077,7 +15077,7 @@ packages: dev: false file:projects/arm-signalr.tgz: - resolution: {integrity: sha512-1NkCyVbi6iaM9hn+1DX6XI012m7zF5dOVAzQd7Y707GZCdmb+d4kTAabf9+sxp3KlLuN9CAX8vNIG8UTTFw1Pg==, tarball: file:projects/arm-signalr.tgz} + resolution: {integrity: sha512-2TXX2h1vcbLy91DuJgaXAYhjLtjvRmTzysxsEPSafLYRiB5vcE+Lqr+gt38SbIaqBg1w55L0l7BNfvyI7eVY1w==, tarball: file:projects/arm-signalr.tgz} name: '@rush-temp/arm-signalr' version: 0.0.0 dependencies: @@ -15097,10 +15097,13 @@ packages: rimraf: 3.0.2 rollup: 2.79.1 rollup-plugin-sourcemaps: 0.6.3_dmbj5memikchm63lpeyt6ukdau + ts-node: 10.9.1_n7tz6hmpirns3flqdptizaxofa tslib: 2.6.1 typescript: 5.0.4 uglify-js: 3.17.4 transitivePeerDependencies: + - '@swc/core' + - '@swc/wasm' - supports-color dev: false @@ -17642,7 +17645,7 @@ packages: version: 0.0.0 dependencies: '@azure/identity': 2.1.0 - '@microsoft/api-extractor': 7.36.3_@types+node@14.18.54 + '@microsoft/api-extractor': 7.36.4_@types+node@14.18.54 '@types/chai': 4.3.5 '@types/mocha': 7.0.2 '@types/node': 14.18.54 @@ -17650,7 +17653,7 @@ packages: chai: 4.3.7 cross-env: 7.0.3 dotenv: 16.3.1 - eslint: 8.45.0 + eslint: 8.46.0 karma: 6.4.2 karma-chrome-launcher: 3.2.0 karma-coverage: 2.2.1 @@ -17668,7 +17671,7 @@ packages: prettier: 2.8.8 rimraf: 3.0.2 source-map-support: 0.5.21 - tslib: 2.6.0 + tslib: 2.6.1 typescript: 5.0.4 transitivePeerDependencies: - bufferutil @@ -17683,7 +17686,7 @@ packages: version: 0.0.0 dependencies: '@azure/identity': 2.1.0 - '@microsoft/api-extractor': 7.36.3_@types+node@14.18.54 + '@microsoft/api-extractor': 7.36.4_@types+node@14.18.54 '@types/chai': 4.3.5 '@types/mocha': 7.0.2 '@types/node': 14.18.54 @@ -17691,7 +17694,7 @@ packages: chai: 4.3.7 cross-env: 7.0.3 dotenv: 16.3.1 - eslint: 8.45.0 + eslint: 8.46.0 karma: 6.4.2 karma-chrome-launcher: 3.2.0 karma-coverage: 2.2.1 @@ -17709,7 +17712,7 @@ packages: prettier: 2.8.8 rimraf: 3.0.2 source-map-support: 0.5.21 - tslib: 2.6.0 + tslib: 2.6.1 typescript: 5.0.4 transitivePeerDependencies: - bufferutil diff --git a/sdk/signalr/arm-signalr/CHANGELOG.md b/sdk/signalr/arm-signalr/CHANGELOG.md index d0fecce61637..0f63e2c51186 100644 --- a/sdk/signalr/arm-signalr/CHANGELOG.md +++ b/sdk/signalr/arm-signalr/CHANGELOG.md @@ -1,15 +1,50 @@ # Release History + +## 6.0.0-beta.1 (2023-08-18) + +**Features** -## 5.2.1 (Unreleased) - -### Features Added - -### Breaking Changes - -### Bugs Fixed + - Added operation group SignalRReplicas + - Added operation SignalR.listReplicaSkus + - Added Interface IPRule + - Added Interface Replica + - Added Interface ReplicaList + - Added Interface SignalRListReplicaSkusOptionalParams + - Added Interface SignalRRegenerateKeyHeaders + - Added Interface SignalRReplicasCreateOrUpdateOptionalParams + - Added Interface SignalRReplicasDeleteOptionalParams + - Added Interface SignalRReplicasGetOptionalParams + - Added Interface SignalRReplicasListNextOptionalParams + - Added Interface SignalRReplicasListOptionalParams + - Added Interface SignalRReplicasRestartHeaders + - Added Interface SignalRReplicasRestartOptionalParams + - Added Interface SignalRReplicasUpdateHeaders + - Added Interface SignalRReplicasUpdateOptionalParams + - Added Interface SignalRRestartHeaders + - Added Interface SignalRUpdateHeaders + - Added Type Alias SignalRListReplicaSkusResponse + - Added Type Alias SignalRReplicasCreateOrUpdateResponse + - Added Type Alias SignalRReplicasGetResponse + - Added Type Alias SignalRReplicasListNextResponse + - Added Type Alias SignalRReplicasListResponse + - Added Type Alias SignalRReplicasRestartResponse + - Added Type Alias SignalRReplicasUpdateResponse + - Added Type Alias SignalRRestartResponse + - Interface Resource has a new optional parameter systemData + - Interface SignalRNetworkACLs has a new optional parameter ipRules + - Interface SignalRResource has a new optional parameter regionEndpointEnabled + - Interface SignalRResource has a new optional parameter resourceStopped -### Other Changes +**Breaking Changes** + - Interface CustomCertificate no longer has parameter systemData + - Interface CustomDomain no longer has parameter systemData + - Interface PrivateEndpointConnection no longer has parameter systemData + - Interface SharedPrivateLinkResource no longer has parameter systemData + - Interface SignalRResource no longer has parameter systemData + - Parameter location of interface TrackedResource is now required + + ## 5.2.0 (2023-03-08) **Features** diff --git a/sdk/signalr/arm-signalr/README.md b/sdk/signalr/arm-signalr/README.md index 3cbed3414f59..c10db9f5949f 100644 --- a/sdk/signalr/arm-signalr/README.md +++ b/sdk/signalr/arm-signalr/README.md @@ -6,7 +6,7 @@ REST API for Azure SignalR Service [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/signalr/arm-signalr) | [Package (NPM)](https://www.npmjs.com/package/@azure/arm-signalr) | -[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-signalr) | +[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-signalr?view=azure-node-preview) | [Samples](https://github.com/Azure-Samples/azure-samples-js-management) ## Getting started diff --git a/sdk/signalr/arm-signalr/_meta.json b/sdk/signalr/arm-signalr/_meta.json index a0e22707ebfd..7c59aee71cee 100644 --- a/sdk/signalr/arm-signalr/_meta.json +++ b/sdk/signalr/arm-signalr/_meta.json @@ -1,8 +1,8 @@ { - "commit": "4f4044394791773e6e7e82a9bd90d3935caaca1b", + "commit": "e4f05ae0d0ec8fd2258803174f88602cd6ad31cb", "readme": "specification/signalr/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\\signalr\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.9 --generate-sample=true", + "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=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/signalr/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.6.2", - "use": "@autorest/typescript@6.0.0-rc.9" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.1", + "use": "@autorest/typescript@^6.0.4" } \ No newline at end of file diff --git a/sdk/signalr/arm-signalr/package.json b/sdk/signalr/arm-signalr/package.json index 1c05854b1c09..9ccd1dc3d539 100644 --- a/sdk/signalr/arm-signalr/package.json +++ b/sdk/signalr/arm-signalr/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for SignalRManagementClient.", - "version": "5.2.1", + "version": "6.0.0-beta.1", "engines": { "node": ">=14.0.0" }, "dependencies": { - "@azure/core-lro": "^2.5.0", + "@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": [ @@ -48,6 +48,7 @@ "chai": "^4.2.0", "cross-env": "^7.0.2", "@types/node": "^14.0.0", + "ts-node": "^10.0.0", "@azure/dev-tool": "^1.0.0" }, "repository": { @@ -111,13 +112,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/signalr/arm-signalr", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-signalr?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/signalr/arm-signalr" +} \ No newline at end of file diff --git a/sdk/signalr/arm-signalr/review/arm-signalr.api.md b/sdk/signalr/arm-signalr/review/arm-signalr.api.md index cb9e9109aedc..ea44cd769b35 100644 --- a/sdk/signalr/arm-signalr/review/arm-signalr.api.md +++ b/sdk/signalr/arm-signalr/review/arm-signalr.api.md @@ -22,7 +22,6 @@ export interface CustomCertificate extends ProxyResource { keyVaultSecretName: string; keyVaultSecretVersion?: string; readonly provisioningState?: ProvisioningState; - readonly systemData?: SystemData; } // @public @@ -36,7 +35,6 @@ export interface CustomDomain extends ProxyResource { customCertificate: ResourceReference; domainName: string; readonly provisioningState?: ProvisioningState; - readonly systemData?: SystemData; } // @public @@ -79,6 +77,12 @@ export type FeatureFlags = string; // @public export function getContinuationToken(page: unknown): string | undefined; +// @public +export interface IPRule { + action?: ACLAction; + value?: string; +} + // @public type KeyType_2 = string; export { KeyType_2 as KeyType } @@ -314,7 +318,6 @@ export interface PrivateEndpointConnection extends ProxyResource { privateEndpoint?: PrivateEndpoint; privateLinkServiceConnectionState?: PrivateLinkServiceConnectionState; readonly provisioningState?: ProvisioningState; - readonly systemData?: SystemData; } // @public @@ -359,10 +362,25 @@ export interface RegenerateKeyParameters { keyType?: KeyType_2; } +// @public +export interface Replica extends TrackedResource { + readonly provisioningState?: ProvisioningState; + regionEndpointEnabled?: string; + resourceStopped?: string; + sku?: ResourceSku; +} + +// @public (undocumented) +export interface ReplicaList { + nextLink?: string; + value?: Replica[]; +} + // @public export interface Resource { readonly id?: string; readonly name?: string; + readonly systemData?: SystemData; readonly type?: string; } @@ -433,7 +451,6 @@ export interface SharedPrivateLinkResource extends ProxyResource { readonly provisioningState?: ProvisioningState; requestMessage?: string; readonly status?: SharedPrivateLinkResourceStatus; - readonly systemData?: SystemData; } // @public @@ -453,8 +470,8 @@ export interface SignalR { beginDeleteAndWait(resourceGroupName: string, resourceName: string, options?: SignalRDeleteOptionalParams): Promise; beginRegenerateKey(resourceGroupName: string, resourceName: string, parameters: RegenerateKeyParameters, options?: SignalRRegenerateKeyOptionalParams): Promise, SignalRRegenerateKeyResponse>>; beginRegenerateKeyAndWait(resourceGroupName: string, resourceName: string, parameters: RegenerateKeyParameters, options?: SignalRRegenerateKeyOptionalParams): Promise; - beginRestart(resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams): Promise, void>>; - beginRestartAndWait(resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams): Promise; + beginRestart(resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams): Promise, SignalRRestartResponse>>; + beginRestartAndWait(resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams): Promise; beginUpdate(resourceGroupName: string, resourceName: string, parameters: SignalRResource, options?: SignalRUpdateOptionalParams): Promise, SignalRUpdateResponse>>; beginUpdateAndWait(resourceGroupName: string, resourceName: string, parameters: SignalRResource, options?: SignalRUpdateOptionalParams): Promise; checkNameAvailability(location: string, parameters: NameAvailabilityParameters, options?: SignalRCheckNameAvailabilityOptionalParams): Promise; @@ -462,6 +479,7 @@ export interface SignalR { listByResourceGroup(resourceGroupName: string, options?: SignalRListByResourceGroupOptionalParams): PagedAsyncIterableIterator; listBySubscription(options?: SignalRListBySubscriptionOptionalParams): PagedAsyncIterableIterator; listKeys(resourceGroupName: string, resourceName: string, options?: SignalRListKeysOptionalParams): Promise; + listReplicaSkus(resourceGroupName: string, resourceName: string, replicaName: string, options?: SignalRListReplicaSkusOptionalParams): Promise; listSkus(resourceGroupName: string, resourceName: string, options?: SignalRListSkusOptionalParams): Promise; } @@ -640,6 +658,13 @@ export interface SignalRListKeysOptionalParams extends coreClient.OperationOptio // @public export type SignalRListKeysResponse = SignalRKeys; +// @public +export interface SignalRListReplicaSkusOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SignalRListReplicaSkusResponse = SkuList; + // @public export interface SignalRListSkusOptionalParams extends coreClient.OperationOptions { } @@ -667,6 +692,8 @@ export class SignalRManagementClient extends coreClient.ServiceClient { // (undocumented) signalRPrivateLinkResources: SignalRPrivateLinkResources; // (undocumented) + signalRReplicas: SignalRReplicas; + // (undocumented) signalRSharedPrivateLinkResources: SignalRSharedPrivateLinkResources; // (undocumented) subscriptionId: string; @@ -684,6 +711,7 @@ export interface SignalRManagementClientOptionalParams extends coreClient.Servic // @public export interface SignalRNetworkACLs { defaultAction?: ACLAction; + ipRules?: IPRule[]; privateEndpoints?: PrivateEndpointACL[]; publicNetwork?: NetworkACL; } @@ -750,6 +778,12 @@ export interface SignalRPrivateLinkResourcesListOptionalParams extends coreClien // @public export type SignalRPrivateLinkResourcesListResponse = PrivateLinkResourceList; +// @public +export interface SignalRRegenerateKeyHeaders { + // (undocumented) + location?: string; +} + // @public export interface SignalRRegenerateKeyOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -759,6 +793,83 @@ export interface SignalRRegenerateKeyOptionalParams extends coreClient.Operation // @public export type SignalRRegenerateKeyResponse = SignalRKeys; +// @public +export interface SignalRReplicas { + beginCreateOrUpdate(resourceGroupName: string, resourceName: string, replicaName: string, parameters: Replica, options?: SignalRReplicasCreateOrUpdateOptionalParams): Promise, SignalRReplicasCreateOrUpdateResponse>>; + beginCreateOrUpdateAndWait(resourceGroupName: string, resourceName: string, replicaName: string, parameters: Replica, options?: SignalRReplicasCreateOrUpdateOptionalParams): Promise; + beginRestart(resourceGroupName: string, resourceName: string, replicaName: string, options?: SignalRReplicasRestartOptionalParams): Promise, SignalRReplicasRestartResponse>>; + beginRestartAndWait(resourceGroupName: string, resourceName: string, replicaName: string, options?: SignalRReplicasRestartOptionalParams): Promise; + beginUpdate(resourceGroupName: string, resourceName: string, replicaName: string, parameters: Replica, options?: SignalRReplicasUpdateOptionalParams): Promise, SignalRReplicasUpdateResponse>>; + beginUpdateAndWait(resourceGroupName: string, resourceName: string, replicaName: string, parameters: Replica, options?: SignalRReplicasUpdateOptionalParams): Promise; + delete(resourceGroupName: string, resourceName: string, replicaName: string, options?: SignalRReplicasDeleteOptionalParams): Promise; + get(resourceGroupName: string, resourceName: string, replicaName: string, options?: SignalRReplicasGetOptionalParams): Promise; + list(resourceGroupName: string, resourceName: string, options?: SignalRReplicasListOptionalParams): PagedAsyncIterableIterator; +} + +// @public +export interface SignalRReplicasCreateOrUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + +// @public +export type SignalRReplicasCreateOrUpdateResponse = Replica; + +// @public +export interface SignalRReplicasDeleteOptionalParams extends coreClient.OperationOptions { +} + +// @public +export interface SignalRReplicasGetOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SignalRReplicasGetResponse = Replica; + +// @public +export interface SignalRReplicasListNextOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SignalRReplicasListNextResponse = ReplicaList; + +// @public +export interface SignalRReplicasListOptionalParams extends coreClient.OperationOptions { +} + +// @public +export type SignalRReplicasListResponse = ReplicaList; + +// @public +export interface SignalRReplicasRestartHeaders { + // (undocumented) + location?: string; +} + +// @public +export interface SignalRReplicasRestartOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + +// @public +export type SignalRReplicasRestartResponse = SignalRReplicasRestartHeaders; + +// @public +export interface SignalRReplicasUpdateHeaders { + // (undocumented) + location?: string; +} + +// @public +export interface SignalRReplicasUpdateOptionalParams extends coreClient.OperationOptions { + resumeFrom?: string; + updateIntervalInMs?: number; +} + +// @public +export type SignalRReplicasUpdateResponse = Replica; + // @public export type SignalRRequestType = string; @@ -779,12 +890,13 @@ export interface SignalRResource extends TrackedResource { readonly provisioningState?: ProvisioningState; publicNetworkAccess?: string; readonly publicPort?: number; + regionEndpointEnabled?: string; resourceLogConfiguration?: ResourceLogConfiguration; + resourceStopped?: string; serverless?: ServerlessSettings; readonly serverPort?: number; readonly sharedPrivateLinkResources?: SharedPrivateLinkResource[]; sku?: ResourceSku; - readonly systemData?: SystemData; tls?: SignalRTlsSettings; upstream?: ServerlessUpstreamSettings; readonly version?: string; @@ -796,12 +908,21 @@ export interface SignalRResourceList { value?: SignalRResource[]; } +// @public +export interface SignalRRestartHeaders { + // (undocumented) + location?: string; +} + // @public export interface SignalRRestartOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; updateIntervalInMs?: number; } +// @public +export type SignalRRestartResponse = SignalRRestartHeaders; + // @public export interface SignalRSharedPrivateLinkResources { beginCreateOrUpdate(sharedPrivateLinkResourceName: string, resourceGroupName: string, resourceName: string, parameters: SharedPrivateLinkResource, options?: SignalRSharedPrivateLinkResourcesCreateOrUpdateOptionalParams): Promise, SignalRSharedPrivateLinkResourcesCreateOrUpdateResponse>>; @@ -856,6 +977,12 @@ export interface SignalRTlsSettings { clientCertEnabled?: boolean; } +// @public +export interface SignalRUpdateHeaders { + // (undocumented) + location?: string; +} + // @public export interface SignalRUpdateOptionalParams extends coreClient.OperationOptions { resumeFrom?: string; @@ -920,7 +1047,7 @@ export interface SystemData { // @public export interface TrackedResource extends Resource { - location?: string; + location: string; tags?: { [propertyName: string]: string; }; diff --git a/sdk/signalr/arm-signalr/src/models/index.ts b/sdk/signalr/arm-signalr/src/models/index.ts index d6dba3818517..00f040832314 100644 --- a/sdk/signalr/arm-signalr/src/models/index.ts +++ b/sdk/signalr/arm-signalr/src/models/index.ts @@ -154,7 +154,7 @@ export interface ErrorAdditionalInfo { /** Data POST-ed to the nameAvailability action */ export interface NameAvailabilityParameters { - /** The resource type. Can be "Microsoft.SignalRService/SignalR" or "Microsoft.SignalRService/webPubSub" */ + /** The resource type. Can be "Microsoft.SignalRService/SignalR", "Microsoft.SignalRService/WebPubSub", "Microsoft.SignalRService/SignalR/replicas" or "Microsoft.SignalRService/WebPubSub/replicas" */ type: string; /** The resource name to validate. e.g."my-resource-name" */ name: string; @@ -249,22 +249,6 @@ export interface ResourceSku { capacity?: number; } -/** Metadata pertaining to creation and last modification of the resource. */ -export interface SystemData { - /** The identity that created the resource. */ - createdBy?: string; - /** The type of identity that created the resource. */ - createdByType?: CreatedByType; - /** The timestamp of resource creation (UTC). */ - createdAt?: Date; - /** The identity that last modified the resource. */ - lastModifiedBy?: string; - /** The type of identity that last modified the resource. */ - lastModifiedByType?: CreatedByType; - /** The timestamp of resource last modification (UTC) */ - lastModifiedAt?: Date; -} - /** Private endpoint */ export interface PrivateEndpoint { /** Full qualified Id of the private endpoint */ @@ -281,28 +265,49 @@ export interface PrivateLinkServiceConnectionState { actionsRequired?: string; } -/** The core properties of ARM resources. */ +/** Common fields that are returned in the response for all Azure Resource Manager resources */ export interface Resource { /** - * Fully qualified resource Id for the resource. + * 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. + * 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.SignalRService/SignalR" + * 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; +} + +/** Metadata pertaining to creation and last modification of the resource. */ +export interface SystemData { + /** The identity that created the resource. */ + createdBy?: string; + /** The type of identity that created the resource. */ + createdByType?: CreatedByType; + /** The timestamp of resource creation (UTC). */ + createdAt?: Date; + /** The identity that last modified the resource. */ + lastModifiedBy?: string; + /** The type of identity that last modified the resource. */ + lastModifiedByType?: CreatedByType; + /** The timestamp of resource last modification (UTC) */ + lastModifiedAt?: Date; } /** TLS settings for the resource */ export interface SignalRTlsSettings { - /** Request client certificate during TLS handshake if enabled */ + /** Request client certificate during TLS handshake if enabled. Not supported for free tier. Any input will be ignored for free tier. */ clientCertEnabled?: boolean; } @@ -464,6 +469,8 @@ export interface SignalRNetworkACLs { publicNetwork?: NetworkACL; /** ACLs for requests from private endpoints */ privateEndpoints?: PrivateEndpointACL[]; + /** IP rules for filtering public traffic */ + ipRules?: IPRule[]; } /** Network ACL */ @@ -474,6 +481,14 @@ export interface NetworkACL { deny?: SignalRRequestType[]; } +/** An IP rule */ +export interface IPRule { + /** An IP or CIDR or ServiceTag */ + value?: string; + /** Azure Networking ACL Action. */ + action?: ACLAction; +} + /** A class represent managed identities used for request and response */ export interface ManagedIdentity { /** Represents the identity type: systemAssigned, userAssigned, None */ @@ -593,11 +608,13 @@ export interface RegenerateKeyParameters { keyType?: KeyType; } -/** A list of shared private link resources */ -export interface SharedPrivateLinkResourceList { - /** The list of the shared private link resources */ - value?: SharedPrivateLinkResource[]; - /** Request URL that can be used to query next page of private endpoint connections. Returned when the total number of requested private endpoint connections exceed maximum page size. */ +export interface ReplicaList { + /** List of the replica */ + value?: Replica[]; + /** + * The URL the client should use to fetch the next page (per server side paging). + * It's null for now, added for future use. + */ nextLink?: string; } @@ -664,15 +681,23 @@ export interface SkuCapacity { readonly scaleType?: ScaleType; } -/** The resource model definition for a ARM proxy resource. It will have everything other than required location and tags */ +/** A list of shared private link resources */ +export interface SharedPrivateLinkResourceList { + /** The list of the shared private link resources */ + value?: SharedPrivateLinkResource[]; + /** Request URL that can be used to query next page of private endpoint connections. Returned when the total number of requested private endpoint connections exceed maximum page size. */ + nextLink?: string; +} + +/** The resource model definition for a Azure Resource Manager proxy resource. It will not have tags and a location */ export interface ProxyResource extends Resource {} -/** The resource model definition for a ARM tracked top level resource. */ +/** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */ export interface TrackedResource extends Resource { - /** The GEO location of the resource. e.g. West US | East US | North Central US | South Central US. */ - location?: string; - /** Tags of the service which is a list of key value pairs that describe the resource. */ + /** Resource tags. */ tags?: { [propertyName: string]: string }; + /** The geo-location where the resource lives */ + location: string; } /** ACL for a private endpoint */ @@ -683,11 +708,6 @@ export interface PrivateEndpointACL extends NetworkACL { /** A private endpoint connection to an azure resource */ export interface PrivateEndpointConnection extends ProxyResource { - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; /** * Provisioning state of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -706,11 +726,6 @@ export interface PrivateEndpointConnection extends ProxyResource { /** Describes a Shared Private Link Resource */ export interface SharedPrivateLinkResource extends ProxyResource { - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; /** The group id from the provider of resource the shared private link resource is for */ groupId?: string; /** The resource id of the resource the shared private link resource is for */ @@ -731,11 +746,6 @@ export interface SharedPrivateLinkResource extends ProxyResource { /** A custom certificate. */ export interface CustomCertificate extends ProxyResource { - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; /** * Provisioning state of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -751,11 +761,6 @@ export interface CustomCertificate extends ProxyResource { /** A custom domain */ export interface CustomDomain extends ProxyResource { - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; /** * Provisioning state of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -783,15 +788,10 @@ export interface PrivateLinkResource extends ProxyResource { export interface SignalRResource extends TrackedResource { /** The billing information of the resource. */ sku?: ResourceSku; - /** The kind of the service, it can be SignalR or RawWebSockets */ + /** The kind of the service */ kind?: ServiceKind; /** A class represent managed identities used for request and response */ identity?: ManagedIdentity; - /** - * Metadata pertaining to creation and last modification of the resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; /** * Provisioning state of the resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -878,6 +878,65 @@ export interface SignalRResource extends TrackedResource { * When set as true, connection with AuthType=aad won't work. */ disableAadAuth?: boolean; + /** + * Enable or disable the regional endpoint. Default to "Enabled". + * When it's Disabled, new connections will not be routed to this endpoint, however existing connections will not be affected. + * This property is replica specific. Disable the regional endpoint without replica is not allowed. + */ + regionEndpointEnabled?: string; + /** + * Stop or start the resource. Default to "False". + * When it's true, the data plane of the resource is shutdown. + * When it's false, the data plane of the resource is started. + */ + resourceStopped?: string; +} + +/** A class represent a replica resource. */ +export interface Replica extends TrackedResource { + /** The billing information of the resource. */ + sku?: ResourceSku; + /** + * Provisioning state of the resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly provisioningState?: ProvisioningState; + /** + * Enable or disable the regional endpoint. Default to "Enabled". + * When it's Disabled, new connections will not be routed to this endpoint, however existing connections will not be affected. + */ + regionEndpointEnabled?: string; + /** + * Stop or start the resource. Default to "false". + * When it's true, the data plane of the resource is shutdown. + * When it's false, the data plane of the resource is started. + */ + resourceStopped?: string; +} + +/** Defines headers for SignalR_update operation. */ +export interface SignalRUpdateHeaders { + location?: string; +} + +/** Defines headers for SignalR_regenerateKey operation. */ +export interface SignalRRegenerateKeyHeaders { + location?: string; +} + +/** Defines headers for SignalR_restart operation. */ +export interface SignalRRestartHeaders { + location?: string; +} + +/** Defines headers for SignalRReplicas_update operation. */ +export interface SignalRReplicasUpdateHeaders { + location?: string; +} + +/** Defines headers for SignalRReplicas_restart operation. */ +export interface SignalRReplicasRestartHeaders { + location?: string; } /** Known values of {@link SignalRSkuTier} that the service accepts. */ @@ -943,30 +1002,6 @@ export enum KnownProvisioningState { */ export type ProvisioningState = string; -/** Known values of {@link CreatedByType} that the service accepts. */ -export enum KnownCreatedByType { - /** User */ - User = "User", - /** Application */ - Application = "Application", - /** ManagedIdentity */ - ManagedIdentity = "ManagedIdentity", - /** Key */ - Key = "Key" -} - -/** - * Defines values for CreatedByType. \ - * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, - * this enum contains the known values that the service supports. - * ### Known values supported by the service - * **User** \ - * **Application** \ - * **ManagedIdentity** \ - * **Key** - */ -export type CreatedByType = string; - /** Known values of {@link PrivateLinkServiceConnectionStatus} that the service accepts. */ export enum KnownPrivateLinkServiceConnectionStatus { /** Pending */ @@ -991,6 +1026,30 @@ export enum KnownPrivateLinkServiceConnectionStatus { */ export type PrivateLinkServiceConnectionStatus = string; +/** Known values of {@link CreatedByType} that the service accepts. */ +export enum KnownCreatedByType { + /** User */ + User = "User", + /** Application */ + Application = "Application", + /** ManagedIdentity */ + ManagedIdentity = "ManagedIdentity", + /** Key */ + Key = "Key" +} + +/** + * Defines values for CreatedByType. \ + * {@link KnownCreatedByType} can be used interchangeably with CreatedByType, + * this enum contains the known values that the service supports. + * ### Known values supported by the service + * **User** \ + * **Application** \ + * **ManagedIdentity** \ + * **Key** + */ +export type CreatedByType = string; + /** Known values of {@link SharedPrivateLinkResourceStatus} that the service accepts. */ export enum KnownSharedPrivateLinkResourceStatus { /** Pending */ @@ -1276,6 +1335,13 @@ export interface SignalRRegenerateKeyOptionalParams /** Contains response data for the regenerateKey operation. */ export type SignalRRegenerateKeyResponse = SignalRKeys; +/** Optional parameters. */ +export interface SignalRListReplicaSkusOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listReplicaSkus operation. */ +export type SignalRListReplicaSkusResponse = SkuList; + /** Optional parameters. */ export interface SignalRRestartOptionalParams extends coreClient.OperationOptions { @@ -1285,6 +1351,9 @@ export interface SignalRRestartOptionalParams resumeFrom?: string; } +/** Contains response data for the restart operation. */ +export type SignalRRestartResponse = SignalRRestartHeaders; + /** Optional parameters. */ export interface SignalRListSkusOptionalParams extends coreClient.OperationOptions {} @@ -1449,6 +1518,67 @@ export interface SignalRPrivateLinkResourcesListNextOptionalParams /** Contains response data for the listNext operation. */ export type SignalRPrivateLinkResourcesListNextResponse = PrivateLinkResourceList; +/** Optional parameters. */ +export interface SignalRReplicasListOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the list operation. */ +export type SignalRReplicasListResponse = ReplicaList; + +/** Optional parameters. */ +export interface SignalRReplicasGetOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the get operation. */ +export type SignalRReplicasGetResponse = Replica; + +/** Optional parameters. */ +export interface SignalRReplicasCreateOrUpdateOptionalParams + 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 SignalRReplicasCreateOrUpdateResponse = Replica; + +/** Optional parameters. */ +export interface SignalRReplicasDeleteOptionalParams + extends coreClient.OperationOptions {} + +/** Optional parameters. */ +export interface SignalRReplicasUpdateOptionalParams + 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 SignalRReplicasUpdateResponse = Replica; + +/** Optional parameters. */ +export interface SignalRReplicasRestartOptionalParams + 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 restart operation. */ +export type SignalRReplicasRestartResponse = SignalRReplicasRestartHeaders; + +/** Optional parameters. */ +export interface SignalRReplicasListNextOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the listNext operation. */ +export type SignalRReplicasListNextResponse = ReplicaList; + /** Optional parameters. */ export interface SignalRSharedPrivateLinkResourcesListOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/signalr/arm-signalr/src/models/mappers.ts b/sdk/signalr/arm-signalr/src/models/mappers.ts index c9e43fdd19a0..531502559e1e 100644 --- a/sdk/signalr/arm-signalr/src/models/mappers.ts +++ b/sdk/signalr/arm-signalr/src/models/mappers.ts @@ -578,51 +578,6 @@ export const ResourceSku: coreClient.CompositeMapper = { } }; -export const SystemData: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SystemData", - modelProperties: { - createdBy: { - serializedName: "createdBy", - type: { - name: "String" - } - }, - createdByType: { - serializedName: "createdByType", - type: { - name: "String" - } - }, - createdAt: { - serializedName: "createdAt", - type: { - name: "DateTime" - } - }, - lastModifiedBy: { - serializedName: "lastModifiedBy", - type: { - name: "String" - } - }, - lastModifiedByType: { - serializedName: "lastModifiedByType", - type: { - name: "String" - } - }, - lastModifiedAt: { - serializedName: "lastModifiedAt", - type: { - name: "DateTime" - } - } - } - } -}; - export const PrivateEndpoint: coreClient.CompositeMapper = { type: { name: "Composite", @@ -690,6 +645,58 @@ export const Resource: coreClient.CompositeMapper = { type: { name: "String" } + }, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + } + } + } +}; + +export const SystemData: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String" + } + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String" + } + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime" + } + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String" + } + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String" + } + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime" + } } } } @@ -701,7 +708,7 @@ export const SignalRTlsSettings: coreClient.CompositeMapper = { className: "SignalRTlsSettings", modelProperties: { clientCertEnabled: { - defaultValue: true, + defaultValue: false, serializedName: "clientCertEnabled", type: { name: "Boolean" @@ -1004,6 +1011,21 @@ export const SignalRNetworkACLs: coreClient.CompositeMapper = { } } } + }, + ipRules: { + constraints: { + MaxItems: 30 + }, + serializedName: "ipRules", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "IPRule" + } + } + } } } } @@ -1040,6 +1062,27 @@ export const NetworkACL: coreClient.CompositeMapper = { } }; +export const IPRule: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "IPRule", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "String" + } + }, + action: { + serializedName: "action", + type: { + name: "String" + } + } + } + } +}; + export const ManagedIdentity: coreClient.CompositeMapper = { type: { name: "Composite", @@ -1324,10 +1367,10 @@ export const RegenerateKeyParameters: coreClient.CompositeMapper = { } }; -export const SharedPrivateLinkResourceList: coreClient.CompositeMapper = { +export const ReplicaList: coreClient.CompositeMapper = { type: { name: "Composite", - className: "SharedPrivateLinkResourceList", + className: "ReplicaList", modelProperties: { value: { serializedName: "value", @@ -1336,7 +1379,7 @@ export const SharedPrivateLinkResourceList: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "SharedPrivateLinkResource" + className: "Replica" } } } @@ -1459,6 +1502,33 @@ export const SkuCapacity: coreClient.CompositeMapper = { } }; +export const SharedPrivateLinkResourceList: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SharedPrivateLinkResourceList", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SharedPrivateLinkResource" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + export const ProxyResource: coreClient.CompositeMapper = { type: { name: "Composite", @@ -1475,18 +1545,19 @@ export const TrackedResource: coreClient.CompositeMapper = { className: "TrackedResource", modelProperties: { ...Resource.type.modelProperties, - location: { - serializedName: "location", - type: { - name: "String" - } - }, tags: { serializedName: "tags", type: { name: "Dictionary", value: { type: { name: "String" } } } + }, + location: { + serializedName: "location", + required: true, + type: { + name: "String" + } } } } @@ -1515,13 +1586,6 @@ export const PrivateEndpointConnection: coreClient.CompositeMapper = { className: "PrivateEndpointConnection", modelProperties: { ...ProxyResource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, @@ -1565,13 +1629,6 @@ export const SharedPrivateLinkResource: coreClient.CompositeMapper = { className: "SharedPrivateLinkResource", modelProperties: { ...ProxyResource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, groupId: { serializedName: "properties.groupId", type: { @@ -1614,13 +1671,6 @@ export const CustomCertificate: coreClient.CompositeMapper = { className: "CustomCertificate", modelProperties: { ...ProxyResource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, @@ -1658,13 +1708,6 @@ export const CustomDomain: coreClient.CompositeMapper = { className: "CustomDomain", modelProperties: { ...ProxyResource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, @@ -1766,13 +1809,6 @@ export const SignalRResource: coreClient.CompositeMapper = { className: "ManagedIdentity" } }, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, @@ -1929,6 +1965,133 @@ export const SignalRResource: coreClient.CompositeMapper = { type: { name: "Boolean" } + }, + regionEndpointEnabled: { + defaultValue: "Enabled", + serializedName: "properties.regionEndpointEnabled", + type: { + name: "String" + } + }, + resourceStopped: { + defaultValue: "false", + serializedName: "properties.resourceStopped", + type: { + name: "String" + } + } + } + } +}; + +export const Replica: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "Replica", + modelProperties: { + ...TrackedResource.type.modelProperties, + sku: { + serializedName: "sku", + type: { + name: "Composite", + className: "ResourceSku" + } + }, + provisioningState: { + serializedName: "properties.provisioningState", + readOnly: true, + type: { + name: "String" + } + }, + regionEndpointEnabled: { + defaultValue: "Enabled", + serializedName: "properties.regionEndpointEnabled", + type: { + name: "String" + } + }, + resourceStopped: { + defaultValue: "false", + serializedName: "properties.resourceStopped", + type: { + name: "String" + } + } + } + } +}; + +export const SignalRUpdateHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SignalRUpdateHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + } + } + } +}; + +export const SignalRRegenerateKeyHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SignalRRegenerateKeyHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + } + } + } +}; + +export const SignalRRestartHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SignalRRestartHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + } + } + } +}; + +export const SignalRReplicasUpdateHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SignalRReplicasUpdateHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } + } + } + } +}; + +export const SignalRReplicasRestartHeaders: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SignalRReplicasRestartHeaders", + modelProperties: { + location: { + serializedName: "location", + type: { + name: "String" + } } } } diff --git a/sdk/signalr/arm-signalr/src/models/parameters.ts b/sdk/signalr/arm-signalr/src/models/parameters.ts index 7ffb2f938b29..c4dff7000ba9 100644 --- a/sdk/signalr/arm-signalr/src/models/parameters.ts +++ b/sdk/signalr/arm-signalr/src/models/parameters.ts @@ -18,6 +18,7 @@ import { CustomCertificate as CustomCertificateMapper, CustomDomain as CustomDomainMapper, PrivateEndpointConnection as PrivateEndpointConnectionMapper, + Replica as ReplicaMapper, SharedPrivateLinkResource as SharedPrivateLinkResourceMapper } from "../models/mappers"; @@ -48,7 +49,7 @@ export const $host: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2023-02-01", + defaultValue: "2023-08-01-preview", isConstant: true, serializedName: "api-version", type: { @@ -103,7 +104,7 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" + name: "Uuid" } } }; @@ -111,6 +112,10 @@ export const subscriptionId: OperationURLParameter = { export const resourceGroupName: OperationURLParameter = { parameterPath: "resourceGroupName", mapper: { + constraints: { + MaxLength: 90, + MinLength: 1 + }, serializedName: "resourceGroupName", required: true, type: { @@ -122,6 +127,11 @@ export const resourceGroupName: OperationURLParameter = { export const resourceName: OperationURLParameter = { parameterPath: "resourceName", mapper: { + constraints: { + Pattern: new RegExp("^[a-zA-Z][a-zA-Z0-9-]{1,61}[a-zA-Z0-9]$"), + MaxLength: 63, + MinLength: 3 + }, serializedName: "resourceName", required: true, type: { @@ -140,6 +150,22 @@ export const parameters2: OperationParameter = { mapper: RegenerateKeyParametersMapper }; +export const replicaName: OperationURLParameter = { + parameterPath: "replicaName", + mapper: { + constraints: { + Pattern: new RegExp("^[a-zA-Z][a-zA-Z0-9-]{1,61}[a-zA-Z0-9]$"), + MaxLength: 63, + MinLength: 3 + }, + serializedName: "replicaName", + required: true, + type: { + name: "String" + } + } +}; + export const certificateName: OperationURLParameter = { parameterPath: "certificateName", mapper: { @@ -188,6 +214,11 @@ export const parameters5: OperationParameter = { mapper: PrivateEndpointConnectionMapper }; +export const parameters6: OperationParameter = { + parameterPath: "parameters", + mapper: ReplicaMapper +}; + export const sharedPrivateLinkResourceName: OperationURLParameter = { parameterPath: "sharedPrivateLinkResourceName", mapper: { @@ -199,7 +230,7 @@ export const sharedPrivateLinkResourceName: OperationURLParameter = { } }; -export const parameters6: OperationParameter = { +export const parameters7: OperationParameter = { parameterPath: "parameters", mapper: SharedPrivateLinkResourceMapper }; diff --git a/sdk/signalr/arm-signalr/src/operations/index.ts b/sdk/signalr/arm-signalr/src/operations/index.ts index 486ffc3ee06b..f07e688e7ad0 100644 --- a/sdk/signalr/arm-signalr/src/operations/index.ts +++ b/sdk/signalr/arm-signalr/src/operations/index.ts @@ -13,4 +13,5 @@ export * from "./signalRCustomCertificates"; export * from "./signalRCustomDomains"; export * from "./signalRPrivateEndpointConnections"; export * from "./signalRPrivateLinkResources"; +export * from "./signalRReplicas"; export * from "./signalRSharedPrivateLinkResources"; diff --git a/sdk/signalr/arm-signalr/src/operations/signalR.ts b/sdk/signalr/arm-signalr/src/operations/signalR.ts index 5f3f1987b77e..4af4bdfdef5b 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalR.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalR.ts @@ -42,7 +42,10 @@ import { RegenerateKeyParameters, SignalRRegenerateKeyOptionalParams, SignalRRegenerateKeyResponse, + SignalRListReplicaSkusOptionalParams, + SignalRListReplicaSkusResponse, SignalRRestartOptionalParams, + SignalRRestartResponse, SignalRListSkusOptionalParams, SignalRListSkusResponse, SignalRListBySubscriptionNextResponse, @@ -118,8 +121,7 @@ export class SignalRImpl implements SignalR { /** * Handles requests to list all resources in a resource group. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ public listByResourceGroup( @@ -218,8 +220,7 @@ export class SignalRImpl implements SignalR { /** * Handles requests to list all resources in a resource group. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ private _listByResourceGroup( @@ -234,8 +235,7 @@ export class SignalRImpl implements SignalR { /** * Get the resource and its properties. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -252,8 +252,7 @@ export class SignalRImpl implements SignalR { /** * Create or update a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the create or update operation * @param options The options parameters. @@ -318,7 +317,8 @@ export class SignalRImpl implements SignalR { OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -326,8 +326,7 @@ export class SignalRImpl implements SignalR { /** * Create or update a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the create or update operation * @param options The options parameters. @@ -349,8 +348,7 @@ export class SignalRImpl implements SignalR { /** * Operation to delete a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -414,8 +412,7 @@ export class SignalRImpl implements SignalR { /** * Operation to delete a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -434,8 +431,7 @@ export class SignalRImpl implements SignalR { /** * Operation to update an exiting resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the update operation * @param options The options parameters. @@ -500,7 +496,8 @@ export class SignalRImpl implements SignalR { OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "location" }); await poller.poll(); return poller; @@ -508,8 +505,7 @@ export class SignalRImpl implements SignalR { /** * Operation to update an exiting resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the update operation * @param options The options parameters. @@ -531,8 +527,7 @@ export class SignalRImpl implements SignalR { /** * Get the access keys of the resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -550,8 +545,7 @@ export class SignalRImpl implements SignalR { /** * Regenerate the access key for the resource. PrimaryKey and SecondaryKey cannot be regenerated at the * same time. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameter that describes the Regenerate Key Operation. * @param options The options parameters. @@ -617,7 +611,7 @@ export class SignalRImpl implements SignalR { >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" + resourceLocationConfig: "location" }); await poller.poll(); return poller; @@ -626,8 +620,7 @@ export class SignalRImpl implements SignalR { /** * Regenerate the access key for the resource. PrimaryKey and SecondaryKey cannot be regenerated at the * same time. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameter that describes the Regenerate Key Operation. * @param options The options parameters. @@ -647,10 +640,28 @@ export class SignalRImpl implements SignalR { return poller.pollUntilDone(); } + /** + * List all available skus of the replica resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + listReplicaSkus( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRListReplicaSkusOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, replicaName, options }, + listReplicaSkusOperationSpec + ); + } + /** * Operation to restart a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -658,11 +669,16 @@ export class SignalRImpl implements SignalR { resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams - ): Promise, void>> { + ): Promise< + SimplePollerLike< + OperationState, + SignalRRestartResponse + > + > { const directSendOperation = async ( args: coreClient.OperationArguments, spec: coreClient.OperationSpec - ): Promise => { + ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( @@ -703,10 +719,13 @@ export class SignalRImpl implements SignalR { args: { resourceGroupName, resourceName, options }, spec: restartOperationSpec }); - const poller = await createHttpPoller>(lro, { + const poller = await createHttpPoller< + SignalRRestartResponse, + OperationState + >(lro, { restoreFrom: options?.resumeFrom, intervalInMs: options?.updateIntervalInMs, - resourceLocationConfig: "azure-async-operation" + resourceLocationConfig: "location" }); await poller.poll(); return poller; @@ -714,8 +733,7 @@ export class SignalRImpl implements SignalR { /** * Operation to restart a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -723,7 +741,7 @@ export class SignalRImpl implements SignalR { resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams - ): Promise { + ): Promise { const poller = await this.beginRestart( resourceGroupName, resourceName, @@ -734,8 +752,7 @@ export class SignalRImpl implements SignalR { /** * List all available skus of the resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -767,8 +784,7 @@ export class SignalRImpl implements SignalR { /** * ListByResourceGroupNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param 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. */ @@ -1013,15 +1029,46 @@ const regenerateKeyOperationSpec: coreClient.OperationSpec = { mediaType: "json", serializer }; +const listReplicaSkusOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}/skus", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.SkuList + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept], + serializer +}; const restartOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/restart", httpMethod: "POST", responses: { - 200: {}, - 201: {}, - 202: {}, - 204: {}, + 200: { + headersMapper: Mappers.SignalRRestartHeaders + }, + 201: { + headersMapper: Mappers.SignalRRestartHeaders + }, + 202: { + headersMapper: Mappers.SignalRRestartHeaders + }, + 204: { + headersMapper: Mappers.SignalRRestartHeaders + }, default: { bodyMapper: Mappers.ErrorResponse } diff --git a/sdk/signalr/arm-signalr/src/operations/signalRCustomCertificates.ts b/sdk/signalr/arm-signalr/src/operations/signalRCustomCertificates.ts index 0bb359765993..018aacad6f3e 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalRCustomCertificates.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalRCustomCertificates.ts @@ -48,8 +48,7 @@ export class SignalRCustomCertificatesImpl /** * List all custom certificates. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -125,8 +124,7 @@ export class SignalRCustomCertificatesImpl /** * List all custom certificates. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -143,8 +141,7 @@ export class SignalRCustomCertificatesImpl /** * Get a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param options The options parameters. @@ -163,8 +160,7 @@ export class SignalRCustomCertificatesImpl /** * Create or update a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param parameters A custom certificate. @@ -237,7 +233,8 @@ export class SignalRCustomCertificatesImpl OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -245,8 +242,7 @@ export class SignalRCustomCertificatesImpl /** * Create or update a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param parameters A custom certificate. @@ -271,8 +267,7 @@ export class SignalRCustomCertificatesImpl /** * Delete a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param options The options parameters. @@ -291,8 +286,7 @@ export class SignalRCustomCertificatesImpl /** * ListNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param nextLink The nextLink from the previous successful call to the List method. * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operations/signalRCustomDomains.ts b/sdk/signalr/arm-signalr/src/operations/signalRCustomDomains.ts index de49c3f48981..dd9f7a6c231b 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalRCustomDomains.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalRCustomDomains.ts @@ -47,8 +47,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * List all custom domains. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -124,8 +123,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * List all custom domains. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -142,8 +140,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * Get a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. @@ -162,8 +159,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * Create or update a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param parameters A custom domain @@ -230,7 +226,8 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -238,8 +235,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * Create or update a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param parameters A custom domain @@ -264,8 +260,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * Delete a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. @@ -331,8 +326,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * Delete a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. @@ -354,8 +348,7 @@ export class SignalRCustomDomainsImpl implements SignalRCustomDomains { /** * ListNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param nextLink The nextLink from the previous successful call to the List method. * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operations/signalRPrivateEndpointConnections.ts b/sdk/signalr/arm-signalr/src/operations/signalRPrivateEndpointConnections.ts index f556386d8548..102f5dfe7903 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalRPrivateEndpointConnections.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalRPrivateEndpointConnections.ts @@ -48,8 +48,7 @@ export class SignalRPrivateEndpointConnectionsImpl /** * List private endpoint connections - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -125,8 +124,7 @@ export class SignalRPrivateEndpointConnectionsImpl /** * List private endpoint connections - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -143,9 +141,9 @@ export class SignalRPrivateEndpointConnectionsImpl /** * Get the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -168,9 +166,9 @@ export class SignalRPrivateEndpointConnectionsImpl /** * Update the state of specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The resource of private endpoint and its properties * @param options The options parameters. @@ -196,9 +194,9 @@ export class SignalRPrivateEndpointConnectionsImpl /** * Delete the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -268,9 +266,9 @@ export class SignalRPrivateEndpointConnectionsImpl /** * Delete the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -291,8 +289,7 @@ export class SignalRPrivateEndpointConnectionsImpl /** * ListNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param nextLink The nextLink from the previous successful call to the List method. * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operations/signalRPrivateLinkResources.ts b/sdk/signalr/arm-signalr/src/operations/signalRPrivateLinkResources.ts index 8d497da7747a..48add3a2e81a 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalRPrivateLinkResources.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalRPrivateLinkResources.ts @@ -37,8 +37,7 @@ export class SignalRPrivateLinkResourcesImpl /** * Get the private link resources that need to be created for a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -114,8 +113,7 @@ export class SignalRPrivateLinkResourcesImpl /** * Get the private link resources that need to be created for a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -132,8 +130,7 @@ export class SignalRPrivateLinkResourcesImpl /** * ListNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param nextLink The nextLink from the previous successful call to the List method. * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operations/signalRReplicas.ts b/sdk/signalr/arm-signalr/src/operations/signalRReplicas.ts new file mode 100644 index 000000000000..ffb881b82ef6 --- /dev/null +++ b/sdk/signalr/arm-signalr/src/operations/signalRReplicas.ts @@ -0,0 +1,702 @@ +/* + * 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 { SignalRReplicas } from "../operationsInterfaces"; +import * as coreClient from "@azure/core-client"; +import * as Mappers from "../models/mappers"; +import * as Parameters from "../models/parameters"; +import { SignalRManagementClient } from "../signalRManagementClient"; +import { + SimplePollerLike, + OperationState, + createHttpPoller +} from "@azure/core-lro"; +import { createLroSpec } from "../lroImpl"; +import { + Replica, + SignalRReplicasListNextOptionalParams, + SignalRReplicasListOptionalParams, + SignalRReplicasListResponse, + SignalRReplicasGetOptionalParams, + SignalRReplicasGetResponse, + SignalRReplicasCreateOrUpdateOptionalParams, + SignalRReplicasCreateOrUpdateResponse, + SignalRReplicasDeleteOptionalParams, + SignalRReplicasUpdateOptionalParams, + SignalRReplicasUpdateResponse, + SignalRReplicasRestartOptionalParams, + SignalRReplicasRestartResponse, + SignalRReplicasListNextResponse +} from "../models"; + +/// +/** Class containing SignalRReplicas operations. */ +export class SignalRReplicasImpl implements SignalRReplicas { + private readonly client: SignalRManagementClient; + + /** + * Initialize a new instance of the class SignalRReplicas class. + * @param client Reference to the service client + */ + constructor(client: SignalRManagementClient) { + this.client = client; + } + + /** + * List all replicas belong to this resource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param options The options parameters. + */ + public list( + resourceGroupName: string, + resourceName: string, + options?: SignalRReplicasListOptionalParams + ): PagedAsyncIterableIterator { + const iter = this.listPagingAll(resourceGroupName, resourceName, 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( + resourceGroupName, + resourceName, + options, + settings + ); + } + }; + } + + private async *listPagingPage( + resourceGroupName: string, + resourceName: string, + options?: SignalRReplicasListOptionalParams, + settings?: PageSettings + ): AsyncIterableIterator { + let result: SignalRReplicasListResponse; + let continuationToken = settings?.continuationToken; + if (!continuationToken) { + result = await this._list(resourceGroupName, resourceName, options); + let page = result.value || []; + continuationToken = result.nextLink; + setContinuationToken(page, continuationToken); + yield page; + } + while (continuationToken) { + result = await this._listNext( + resourceGroupName, + resourceName, + continuationToken, + options + ); + continuationToken = result.nextLink; + let page = result.value || []; + setContinuationToken(page, continuationToken); + yield page; + } + } + + private async *listPagingAll( + resourceGroupName: string, + resourceName: string, + options?: SignalRReplicasListOptionalParams + ): AsyncIterableIterator { + for await (const page of this.listPagingPage( + resourceGroupName, + resourceName, + options + )) { + yield* page; + } + } + + /** + * List all replicas belong to this resource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param options The options parameters. + */ + private _list( + resourceGroupName: string, + resourceName: string, + options?: SignalRReplicasListOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, options }, + listOperationSpec + ); + } + + /** + * Get the replica and its properties. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasGetOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, replicaName, options }, + getOperationSpec + ); + } + + /** + * Create or update a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the create or update operation + * @param options The options parameters. + */ + async beginCreateOrUpdate( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasCreateOrUpdateOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasCreateOrUpdateResponse + > + > { + 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, + resourceName, + replicaName, + parameters, + options + }, + spec: createOrUpdateOperationSpec + }); + const poller = await createHttpPoller< + SignalRReplicasCreateOrUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "azure-async-operation" + }); + await poller.poll(); + return poller; + } + + /** + * Create or update a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the create or update operation + * @param options The options parameters. + */ + async beginCreateOrUpdateAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasCreateOrUpdateOptionalParams + ): Promise { + const poller = await this.beginCreateOrUpdate( + resourceGroupName, + resourceName, + replicaName, + parameters, + options + ); + return poller.pollUntilDone(); + } + + /** + * Operation to delete a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasDeleteOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, replicaName, options }, + deleteOperationSpec + ); + } + + /** + * Operation to update an exiting replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the update operation + * @param options The options parameters. + */ + async beginUpdate( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasUpdateOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasUpdateResponse + > + > { + 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, + resourceName, + replicaName, + parameters, + options + }, + spec: updateOperationSpec + }); + const poller = await createHttpPoller< + SignalRReplicasUpdateResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "location" + }); + await poller.poll(); + return poller; + } + + /** + * Operation to update an exiting replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the update operation + * @param options The options parameters. + */ + async beginUpdateAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasUpdateOptionalParams + ): Promise { + const poller = await this.beginUpdate( + resourceGroupName, + resourceName, + replicaName, + parameters, + options + ); + return poller.pollUntilDone(); + } + + /** + * Operation to restart a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + async beginRestart( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasRestartOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasRestartResponse + > + > { + 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, resourceName, replicaName, options }, + spec: restartOperationSpec + }); + const poller = await createHttpPoller< + SignalRReplicasRestartResponse, + OperationState + >(lro, { + restoreFrom: options?.resumeFrom, + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "location" + }); + await poller.poll(); + return poller; + } + + /** + * Operation to restart a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + async beginRestartAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasRestartOptionalParams + ): Promise { + const poller = await this.beginRestart( + resourceGroupName, + resourceName, + replicaName, + options + ); + return poller.pollUntilDone(); + } + + /** + * ListNext + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param nextLink The nextLink from the previous successful call to the List method. + * @param options The options parameters. + */ + private _listNext( + resourceGroupName: string, + resourceName: string, + nextLink: string, + options?: SignalRReplicasListNextOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, resourceName, nextLink, options }, + listNextOperationSpec + ); + } +} +// Operation Specifications +const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); + +const listOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ReplicaList + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept], + serializer +}; +const getOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.Replica + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept], + serializer +}; +const createOrUpdateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}", + httpMethod: "PUT", + responses: { + 200: { + bodyMapper: Mappers.Replica + }, + 201: { + bodyMapper: Mappers.Replica + }, + 202: { + bodyMapper: Mappers.Replica + }, + 204: { + bodyMapper: Mappers.Replica + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.parameters6, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const deleteOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}", + httpMethod: "DELETE", + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept], + serializer +}; +const updateOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}", + httpMethod: "PATCH", + responses: { + 200: { + bodyMapper: Mappers.Replica + }, + 201: { + bodyMapper: Mappers.Replica + }, + 202: { + bodyMapper: Mappers.Replica + }, + 204: { + bodyMapper: Mappers.Replica + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.parameters6, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; +const restartOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.SignalRService/signalR/{resourceName}/replicas/{replicaName}/restart", + httpMethod: "POST", + responses: { + 200: { + headersMapper: Mappers.SignalRReplicasRestartHeaders + }, + 201: { + headersMapper: Mappers.SignalRReplicasRestartHeaders + }, + 202: { + headersMapper: Mappers.SignalRReplicasRestartHeaders + }, + 204: { + headersMapper: Mappers.SignalRReplicasRestartHeaders + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName, + Parameters.replicaName + ], + headerParameters: [Parameters.accept], + serializer +}; +const listNextOperationSpec: coreClient.OperationSpec = { + path: "{nextLink}", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: Mappers.ReplicaList + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + urlParameters: [ + Parameters.$host, + Parameters.nextLink, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.resourceName + ], + headerParameters: [Parameters.accept], + serializer +}; diff --git a/sdk/signalr/arm-signalr/src/operations/signalRSharedPrivateLinkResources.ts b/sdk/signalr/arm-signalr/src/operations/signalRSharedPrivateLinkResources.ts index 3a2c573cf9c4..cd802565c42d 100644 --- a/sdk/signalr/arm-signalr/src/operations/signalRSharedPrivateLinkResources.ts +++ b/sdk/signalr/arm-signalr/src/operations/signalRSharedPrivateLinkResources.ts @@ -48,8 +48,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * List shared private link resources - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -125,8 +124,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * List shared private link resources - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -144,8 +142,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * Get the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -169,8 +166,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * Create or update a shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The shared private link resource * @param options The options parameters. @@ -242,7 +238,8 @@ export class SignalRSharedPrivateLinkResourcesImpl OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, + resourceLocationConfig: "azure-async-operation" }); await poller.poll(); return poller; @@ -251,8 +248,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * Create or update a shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The shared private link resource * @param options The options parameters. @@ -277,8 +273,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * Delete the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -349,8 +344,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * Delete the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -371,8 +365,7 @@ export class SignalRSharedPrivateLinkResourcesImpl /** * ListNext - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param nextLink The nextLink from the previous successful call to the List method. * @param options The options parameters. @@ -458,7 +451,7 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - requestBody: Parameters.parameters6, + requestBody: Parameters.parameters7, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/index.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/index.ts index 486ffc3ee06b..f07e688e7ad0 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/index.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/index.ts @@ -13,4 +13,5 @@ export * from "./signalRCustomCertificates"; export * from "./signalRCustomDomains"; export * from "./signalRPrivateEndpointConnections"; export * from "./signalRPrivateLinkResources"; +export * from "./signalRReplicas"; export * from "./signalRSharedPrivateLinkResources"; diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalR.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalR.ts index efc7911975d2..094fd98de827 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalR.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalR.ts @@ -27,7 +27,10 @@ import { RegenerateKeyParameters, SignalRRegenerateKeyOptionalParams, SignalRRegenerateKeyResponse, + SignalRListReplicaSkusOptionalParams, + SignalRListReplicaSkusResponse, SignalRRestartOptionalParams, + SignalRRestartResponse, SignalRListSkusOptionalParams, SignalRListSkusResponse } from "../models"; @@ -44,8 +47,7 @@ export interface SignalR { ): PagedAsyncIterableIterator; /** * Handles requests to list all resources in a resource group. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param options The options parameters. */ listByResourceGroup( @@ -65,8 +67,7 @@ export interface SignalR { ): Promise; /** * Get the resource and its properties. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -77,8 +78,7 @@ export interface SignalR { ): Promise; /** * Create or update a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the create or update operation * @param options The options parameters. @@ -96,8 +96,7 @@ export interface SignalR { >; /** * Create or update a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the create or update operation * @param options The options parameters. @@ -110,8 +109,7 @@ export interface SignalR { ): Promise; /** * Operation to delete a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -122,8 +120,7 @@ export interface SignalR { ): Promise, void>>; /** * Operation to delete a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -134,8 +131,7 @@ export interface SignalR { ): Promise; /** * Operation to update an exiting resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the update operation * @param options The options parameters. @@ -153,8 +149,7 @@ export interface SignalR { >; /** * Operation to update an exiting resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameters for the update operation * @param options The options parameters. @@ -167,8 +162,7 @@ export interface SignalR { ): Promise; /** * Get the access keys of the resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -180,8 +174,7 @@ export interface SignalR { /** * Regenerate the access key for the resource. PrimaryKey and SecondaryKey cannot be regenerated at the * same time. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameter that describes the Regenerate Key Operation. * @param options The options parameters. @@ -200,8 +193,7 @@ export interface SignalR { /** * Regenerate the access key for the resource. PrimaryKey and SecondaryKey cannot be regenerated at the * same time. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters Parameter that describes the Regenerate Key Operation. * @param options The options parameters. @@ -212,10 +204,22 @@ export interface SignalR { parameters: RegenerateKeyParameters, options?: SignalRRegenerateKeyOptionalParams ): Promise; + /** + * List all available skus of the replica resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + listReplicaSkus( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRListReplicaSkusOptionalParams + ): Promise; /** * Operation to restart a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -223,11 +227,15 @@ export interface SignalR { resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams - ): Promise, void>>; + ): Promise< + SimplePollerLike< + OperationState, + SignalRRestartResponse + > + >; /** * Operation to restart a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -235,11 +243,10 @@ export interface SignalR { resourceGroupName: string, resourceName: string, options?: SignalRRestartOptionalParams - ): Promise; + ): Promise; /** * List all available skus of the resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomCertificates.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomCertificates.ts index b752f17e67fd..bd67c254e17f 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomCertificates.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomCertificates.ts @@ -23,8 +23,7 @@ import { export interface SignalRCustomCertificates { /** * List all custom certificates. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -35,8 +34,7 @@ export interface SignalRCustomCertificates { ): PagedAsyncIterableIterator; /** * Get a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param options The options parameters. @@ -49,8 +47,7 @@ export interface SignalRCustomCertificates { ): Promise; /** * Create or update a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param parameters A custom certificate. @@ -70,8 +67,7 @@ export interface SignalRCustomCertificates { >; /** * Create or update a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param parameters A custom certificate. @@ -86,8 +82,7 @@ export interface SignalRCustomCertificates { ): Promise; /** * Delete a custom certificate. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param certificateName Custom certificate name * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomDomains.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomDomains.ts index 66fb253125b8..ff55feed2ed7 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomDomains.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRCustomDomains.ts @@ -23,8 +23,7 @@ import { export interface SignalRCustomDomains { /** * List all custom domains. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -35,8 +34,7 @@ export interface SignalRCustomDomains { ): PagedAsyncIterableIterator; /** * Get a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. @@ -49,8 +47,7 @@ export interface SignalRCustomDomains { ): Promise; /** * Create or update a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param parameters A custom domain @@ -70,8 +67,7 @@ export interface SignalRCustomDomains { >; /** * Create or update a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param parameters A custom domain @@ -86,8 +82,7 @@ export interface SignalRCustomDomains { ): Promise; /** * Delete a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. @@ -100,8 +95,7 @@ export interface SignalRCustomDomains { ): Promise, void>>; /** * Delete a custom domain. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param name Custom domain name. * @param options The options parameters. diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateEndpointConnections.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateEndpointConnections.ts index dda4b9b4450c..0390d1ffca50 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateEndpointConnections.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateEndpointConnections.ts @@ -23,8 +23,7 @@ import { export interface SignalRPrivateEndpointConnections { /** * List private endpoint connections - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -35,9 +34,9 @@ export interface SignalRPrivateEndpointConnections { ): PagedAsyncIterableIterator; /** * Get the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -49,9 +48,9 @@ export interface SignalRPrivateEndpointConnections { ): Promise; /** * Update the state of specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The resource of private endpoint and its properties * @param options The options parameters. @@ -65,9 +64,9 @@ export interface SignalRPrivateEndpointConnections { ): Promise; /** * Delete the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -79,9 +78,9 @@ export interface SignalRPrivateEndpointConnections { ): Promise, void>>; /** * Delete the specified private endpoint connection - * @param privateEndpointConnectionName The name of the private endpoint connection - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param privateEndpointConnectionName The name of the private endpoint connection associated with the + * Azure resource. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateLinkResources.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateLinkResources.ts index fc877b502531..d13b596d7201 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateLinkResources.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRPrivateLinkResources.ts @@ -17,8 +17,7 @@ import { export interface SignalRPrivateLinkResources { /** * Get the private link resources that need to be created for a resource. - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRReplicas.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRReplicas.ts new file mode 100644 index 000000000000..e4532b90f28b --- /dev/null +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRReplicas.ts @@ -0,0 +1,166 @@ +/* + * 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 { + Replica, + SignalRReplicasListOptionalParams, + SignalRReplicasGetOptionalParams, + SignalRReplicasGetResponse, + SignalRReplicasCreateOrUpdateOptionalParams, + SignalRReplicasCreateOrUpdateResponse, + SignalRReplicasDeleteOptionalParams, + SignalRReplicasUpdateOptionalParams, + SignalRReplicasUpdateResponse, + SignalRReplicasRestartOptionalParams, + SignalRReplicasRestartResponse +} from "../models"; + +/// +/** Interface representing a SignalRReplicas. */ +export interface SignalRReplicas { + /** + * List all replicas belong to this resource + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param options The options parameters. + */ + list( + resourceGroupName: string, + resourceName: string, + options?: SignalRReplicasListOptionalParams + ): PagedAsyncIterableIterator; + /** + * Get the replica and its properties. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + get( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasGetOptionalParams + ): Promise; + /** + * Create or update a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the create or update operation + * @param options The options parameters. + */ + beginCreateOrUpdate( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasCreateOrUpdateOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasCreateOrUpdateResponse + > + >; + /** + * Create or update a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the create or update operation + * @param options The options parameters. + */ + beginCreateOrUpdateAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasCreateOrUpdateOptionalParams + ): Promise; + /** + * Operation to delete a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + delete( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasDeleteOptionalParams + ): Promise; + /** + * Operation to update an exiting replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the update operation + * @param options The options parameters. + */ + beginUpdate( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasUpdateOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasUpdateResponse + > + >; + /** + * Operation to update an exiting replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param parameters Parameters for the update operation + * @param options The options parameters. + */ + beginUpdateAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + parameters: Replica, + options?: SignalRReplicasUpdateOptionalParams + ): Promise; + /** + * Operation to restart a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + beginRestart( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasRestartOptionalParams + ): Promise< + SimplePollerLike< + OperationState, + SignalRReplicasRestartResponse + > + >; + /** + * Operation to restart a replica. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param resourceName The name of the resource. + * @param replicaName The name of the replica. + * @param options The options parameters. + */ + beginRestartAndWait( + resourceGroupName: string, + resourceName: string, + replicaName: string, + options?: SignalRReplicasRestartOptionalParams + ): Promise; +} diff --git a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRSharedPrivateLinkResources.ts b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRSharedPrivateLinkResources.ts index 7dc8f1032504..08d21569e50f 100644 --- a/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRSharedPrivateLinkResources.ts +++ b/sdk/signalr/arm-signalr/src/operationsInterfaces/signalRSharedPrivateLinkResources.ts @@ -23,8 +23,7 @@ import { export interface SignalRSharedPrivateLinkResources { /** * List shared private link resources - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -36,8 +35,7 @@ export interface SignalRSharedPrivateLinkResources { /** * Get the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -50,8 +48,7 @@ export interface SignalRSharedPrivateLinkResources { /** * Create or update a shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The shared private link resource * @param options The options parameters. @@ -71,8 +68,7 @@ export interface SignalRSharedPrivateLinkResources { /** * Create or update a shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param parameters The shared private link resource * @param options The options parameters. @@ -87,8 +83,7 @@ export interface SignalRSharedPrivateLinkResources { /** * Delete the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ @@ -101,8 +96,7 @@ export interface SignalRSharedPrivateLinkResources { /** * Delete the specified shared private link resource * @param sharedPrivateLinkResourceName The name of the shared private link resource - * @param resourceGroupName The name of the resource group that contains the resource. You can obtain - * this value from the Azure Resource Manager API or the portal. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param resourceName The name of the resource. * @param options The options parameters. */ diff --git a/sdk/signalr/arm-signalr/src/signalRManagementClient.ts b/sdk/signalr/arm-signalr/src/signalRManagementClient.ts index 6e0d7c350c71..4a08dcdd4ece 100644 --- a/sdk/signalr/arm-signalr/src/signalRManagementClient.ts +++ b/sdk/signalr/arm-signalr/src/signalRManagementClient.ts @@ -22,6 +22,7 @@ import { SignalRCustomDomainsImpl, SignalRPrivateEndpointConnectionsImpl, SignalRPrivateLinkResourcesImpl, + SignalRReplicasImpl, SignalRSharedPrivateLinkResourcesImpl } from "./operations"; import { @@ -32,6 +33,7 @@ import { SignalRCustomDomains, SignalRPrivateEndpointConnections, SignalRPrivateLinkResources, + SignalRReplicas, SignalRSharedPrivateLinkResources } from "./operationsInterfaces"; import { SignalRManagementClientOptionalParams } from "./models"; @@ -44,8 +46,7 @@ export class SignalRManagementClient extends coreClient.ServiceClient { /** * Initializes a new instance of the SignalRManagementClient class. * @param credentials Subscription credentials which uniquely identify client subscription. - * @param subscriptionId Gets subscription Id which uniquely identify the Microsoft Azure subscription. - * The subscription ID forms part of the URI for every service call. + * @param subscriptionId The ID of the target subscription. The value must be an UUID. * @param options The parameter options */ constructor( @@ -69,7 +70,7 @@ export class SignalRManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-signalr/5.2.1`; + const packageDetails = `azsdk-js-arm-signalr/6.0.0-beta.1`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -122,7 +123,7 @@ export class SignalRManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2023-02-01"; + this.apiVersion = options.apiVersion || "2023-08-01-preview"; this.operations = new OperationsImpl(this); this.signalR = new SignalRImpl(this); this.usages = new UsagesImpl(this); @@ -134,6 +135,7 @@ export class SignalRManagementClient extends coreClient.ServiceClient { this.signalRPrivateLinkResources = new SignalRPrivateLinkResourcesImpl( this ); + this.signalRReplicas = new SignalRReplicasImpl(this); this.signalRSharedPrivateLinkResources = new SignalRSharedPrivateLinkResourcesImpl( this ); @@ -175,5 +177,6 @@ export class SignalRManagementClient extends coreClient.ServiceClient { signalRCustomDomains: SignalRCustomDomains; signalRPrivateEndpointConnections: SignalRPrivateEndpointConnections; signalRPrivateLinkResources: SignalRPrivateLinkResources; + signalRReplicas: SignalRReplicas; signalRSharedPrivateLinkResources: SignalRSharedPrivateLinkResources; } diff --git a/sdk/signalr/arm-signalr/test/sampleTest.ts b/sdk/signalr/arm-signalr/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/signalr/arm-signalr/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/signalr/arm-signalr/tsconfig.json b/sdk/signalr/arm-signalr/tsconfig.json index b5227bc29af1..3e6ae96443f3 100644 --- a/sdk/signalr/arm-signalr/tsconfig.json +++ b/sdk/signalr/arm-signalr/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-signalr": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"