diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index f6b596f5818c..7842a64c8b3e 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -965,7 +965,7 @@ packages: resolution: {integrity: sha512-Q71Buur3RMcg6lCnisLL8Im562DBw+ybzgm+YQj/FbAaI8ZNu/zl/5z1fE4k3Q9LSIzYrz6HLRzlhdSBXpydlQ==} engines: {node: '>=8.0.0'} dependencies: - '@azure/core-http': 1.2.3 + '@azure/core-http': 1.2.6 '@azure/core-tracing': 1.0.0-preview.9 '@azure/logger': 1.0.3 '@azure/msal-node': 1.0.0-beta.6_debug@4.3.4 @@ -2227,7 +2227,7 @@ packages: resolution: {integrity: sha512-ALYone6pm6QmwZoAgeyNksccT9Q4AWZQ6PvfwR37GT6r6FWUPguq6sUmNGSMV2Wr761oQoBxwGGa6DR5o1DC9g==} dependencies: '@types/connect': 3.4.35 - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/chai-as-promised/7.1.5: @@ -2253,14 +2253,14 @@ packages: /@types/concurrently/6.4.0: resolution: {integrity: sha512-CYU1eyFHsIa2IZIsb8gfUOdiewfnZcyM2Hg1Zaq95xnmB0Ix/bTRM8SttqZ2Cjy6JGPZLttHjZewVsDg1yvnJg==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 chalk: 4.1.2 dev: false /@types/connect/3.4.35: resolution: {integrity: sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/cookie/0.4.1: @@ -2295,7 +2295,7 @@ packages: /@types/express-serve-static-core/4.17.28: resolution: {integrity: sha512-P1BJAEAW3E2DJUlkgq4tOL3RyMunoWXqbSCygWo5ZIWTjUgN1YnaXWW4VWl/oc8vs/XoYibEGBKP0uZyF4AHig==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 '@types/qs': 6.9.7 '@types/range-parser': 1.2.4 dev: false @@ -2312,26 +2312,26 @@ packages: /@types/fs-extra/8.1.2: resolution: {integrity: sha512-SvSrYXfWSc7R4eqnOzbQF4TZmfpNSM9FrSWLU3EUnWBuyZqNBOrv1B1JA3byUDPUl9z4Ab3jeZG2eDdySlgNMg==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/fs-extra/9.0.13: resolution: {integrity: sha512-nEnwB++1u5lVDM2UI4c1+5R+FYaKfaAzS4OococimjVm3nQw3TuzH5UNsocrcTBbhnerblyHj4A49qXbIiZdpA==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/glob/7.2.0: resolution: {integrity: sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==} dependencies: '@types/minimatch': 3.0.5 - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/is-buffer/2.0.0: resolution: {integrity: sha512-0f7N/e3BAz32qDYvgB4d2cqv1DqUwvGxHkXsrucICn8la1Vb6Yl6Eg8mPScGwUiqHJeE7diXlzaK+QMA9m4Gxw==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/json-schema/7.0.11: @@ -2345,13 +2345,13 @@ packages: /@types/jsonwebtoken/8.5.8: resolution: {integrity: sha512-zm6xBQpFDIDM6o9r6HSgDeIcLy82TKWctCXEPbJJcXb5AKmi5BNNdLXneixK4lplX3PqIVcwLBCGE/kAGnlD4A==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/jws/3.2.4: resolution: {integrity: sha512-aqtH4dPw1wUjFZaeMD1ak/pf8iXlu/odFe+trJrvw0g1sTh93i+SCykg0Ek8C6B7rVK3oBORbfZAsKO7P10etg==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/long/4.0.1: @@ -2395,13 +2395,13 @@ packages: /@types/mock-fs/4.13.1: resolution: {integrity: sha512-m6nFAJ3lBSnqbvDZioawRvpLXSaPyn52Srf7OfzjubYbYX8MTUdIgDxQl0wEapm4m/pNYSd9TXocpQ0TvZFlYA==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/mock-require/2.0.1: resolution: {integrity: sha512-O7U5DVGboY/Crueb5/huUCIRjKtRVRaLmRDbZJBlDQgJn966z3aiFDN+6AtYviu2ExwMkl34LjT/IiC0OPtKuQ==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/ms/0.7.31: @@ -2415,7 +2415,7 @@ packages: /@types/node-fetch/2.6.1: resolution: {integrity: sha512-oMqjURCaxoSIsHSr1E47QHzbmzNR5rK8McHuNb11BOM9cHcIK3Avy0s/b2JlXHoQGTYS3NsvWzV1M0iK7l0wbA==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 form-data: 3.0.1 dev: false @@ -2465,7 +2465,7 @@ packages: resolution: {integrity: sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ==} dependencies: '@types/mime': 1.3.2 - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/sinon/10.0.11: @@ -2487,7 +2487,7 @@ packages: /@types/stoppable/1.1.1: resolution: {integrity: sha512-b8N+fCADRIYYrGZOcmOR8ZNBOqhktWTB/bMUl5LvGtT201QKJZOOH5UsFyI3qtteM6ZAJbJqZoBcLqqxKIwjhw==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/tough-cookie/4.0.1: @@ -2497,13 +2497,13 @@ packages: /@types/tunnel/0.0.1: resolution: {integrity: sha512-AOqu6bQu5MSWwYvehMXLukFHnupHrpZ8nvgae5Ggie9UwzDR1CCwoXgSSWNZJuyOlCdfdsWMA5F2LlmvyoTv8A==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/tunnel/0.0.3: resolution: {integrity: sha512-sOUTGn6h1SfQ+gbgqC364jLFBw2lnFqkgF3q0WovEHRLMrVD1sd5aufqi/aJObLekJO+Aq5z646U4Oxy6shXMA==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/underscore/1.11.4: @@ -2521,26 +2521,26 @@ packages: /@types/ws/7.4.7: resolution: {integrity: sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/ws/8.5.3: resolution: {integrity: sha512-6YOoWjruKj1uLf3INHH7D3qTXwFfEsg1kf3c0uDdSBJwfa/llkwIjrAGV7j7mVgGNbzTQ3HiHKKDXl6bJPD97w==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/xml2js/0.4.9: resolution: {integrity: sha512-CHiCKIihl1pychwR2RNX5mAYmJDACgFVCMT5OArMaO3erzwXVcBqPcusr+Vl8yeeXukxZqtF8mZioqX+mpjjdw==} dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false /@types/yauzl/2.10.0: resolution: {integrity: sha512-Cn6WYCm0tXv8p6k+A8PvbDG763EDpBoTzHdA+Q/MF6H3sapGjCm9NzoaJncJS9tUKSuCoDs9XHxYYsQDgxR6kw==} requiresBuild: true dependencies: - '@types/node': 12.20.47 + '@types/node': 17.0.23 dev: false optional: true @@ -3522,7 +3522,7 @@ packages: resolution: {integrity: sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==} deprecated: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) dependencies: - ms: 2.1.1 + ms: 2.1.3 dev: false /debug/3.2.7: @@ -3725,7 +3725,7 @@ packages: dependencies: semver: 7.3.7 shelljs: 0.8.5 - typescript: 4.2.4 + typescript: 4.5.5 dev: false /ecdsa-sig-formatter/1.0.11: @@ -3778,7 +3778,7 @@ packages: dependencies: '@types/cookie': 0.4.1 '@types/cors': 2.8.12 - '@types/node': 12.20.47 + '@types/node': 17.0.23 accepts: 1.3.8 base64id: 2.0.0 cookie: 0.4.2 @@ -4625,7 +4625,7 @@ packages: fs.realpath: 1.0.0 inflight: 1.0.6 inherits: 2.0.4 - minimatch: 3.0.4 + minimatch: 3.1.2 once: 1.4.0 path-is-absolute: 1.0.1 dev: false @@ -8477,7 +8477,7 @@ packages: /wide-align/1.1.5: resolution: {integrity: sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==} dependencies: - string-width: 1.0.2 + string-width: 4.2.3 dev: false /word-wrap/1.2.3: @@ -12845,23 +12845,23 @@ packages: dev: false file:projects/arm-servicebus.tgz: - resolution: {integrity: sha512-2/hJdpvvsY94v4z/vmn8UDCZ09t33Smt4S10uvMz4KnWMHZOahKZW9VpjfPG2X2UBefNsYiaPl7XPApbJ/nNEg==, tarball: file:projects/arm-servicebus.tgz} + resolution: {integrity: sha512-GamuNRwpsVHBM8v5RAcUXpQSk7GX3d6OyNSNrFMWrLXSWOTKWe9qFXpAwJ4b013JiPC7143sCu2gSvEyGww9tA==, tarball: file:projects/arm-servicebus.tgz} name: '@rush-temp/arm-servicebus' version: 0.0.0 dependencies: '@azure-tools/test-recorder': 1.0.2 '@azure/identity': 2.0.4 '@microsoft/api-extractor': 7.22.1 - '@rollup/plugin-commonjs': 21.0.3_rollup@2.70.1 - '@rollup/plugin-json': 4.1.0_rollup@2.70.1 - '@rollup/plugin-multi-entry': 3.0.1_rollup@2.70.1 - '@rollup/plugin-node-resolve': 8.4.0_rollup@2.70.1 + '@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1 + '@rollup/plugin-json': 4.1.0_rollup@1.32.1 + '@rollup/plugin-multi-entry': 3.0.1_rollup@1.32.1 + '@rollup/plugin-node-resolve': 8.4.0_rollup@1.32.1 cross-env: 7.0.3 mkdirp: 1.0.4 mocha: 7.2.0 rimraf: 3.0.2 - rollup: 2.70.1 - rollup-plugin-sourcemaps: 0.4.2_rollup@2.70.1 + rollup: 1.32.1 + rollup-plugin-sourcemaps: 0.4.2_rollup@1.32.1 tslib: 2.3.1 typescript: 4.2.4 uglify-js: 3.15.4 diff --git a/sdk/servicebus/arm-servicebus/CHANGELOG.md b/sdk/servicebus/arm-servicebus/CHANGELOG.md index 433260b1dde5..44089f512325 100644 --- a/sdk/servicebus/arm-servicebus/CHANGELOG.md +++ b/sdk/servicebus/arm-servicebus/CHANGELOG.md @@ -1,15 +1,40 @@ # Release History - -## 5.0.1 (Unreleased) - -### Features Added - -### Breaking Changes - -### Bugs Fixed - -### Other Changes - + +## 6.0.0 (2022-04-14) + +**Features** + + - Added Interface ProxyResource + - Interface Operation has a new optional parameter isDataAction + - Interface Operation has a new optional parameter origin + - Interface Operation has a new optional parameter properties + - Interface OperationDisplay has a new optional parameter description + - Add parameters of ProxyResource to TypeAlias ArmDisasterRecovery + - Add parameters of ProxyResource to TypeAlias MigrationConfigProperties + - Add parameters of ProxyResource to TypeAlias NetworkRuleSet + - Add parameters of ProxyResource to TypeAlias PrivateEndpointConnection + - Add parameters of ProxyResource to TypeAlias Rule + - Add parameters of ProxyResource to TypeAlias SBAuthorizationRule + - Add parameters of ProxyResource to TypeAlias SBQueue + - Add parameters of ProxyResource to TypeAlias SBSubscription + - Add parameters of ProxyResource to TypeAlias SBTopic + - Type Alias SBNamespace has a new parameter alternateName + - Type Alias SBNamespaceUpdateParameters has a new parameter alternateName + +**Breaking Changes** + + - Delete parameters of Resource in TypeAlias ArmDisasterRecovery + - Delete parameters of Resource in TypeAlias MigrationConfigProperties + - Delete parameters of Resource in TypeAlias NetworkRuleSet + - Delete parameters of Resource in TypeAlias PrivateEndpointConnection + - Delete parameters of Resource in TypeAlias Rule + - Delete parameters of Resource in TypeAlias SBAuthorizationRule + - Delete parameters of Resource in TypeAlias SBQueue + - Delete parameters of Resource in TypeAlias SBSubscription + - Delete parameters of Resource in TypeAlias SBTopic + - Type Alias SBNamespaceUpdateParameters no longer has parameter zoneRedundant + + ## 5.0.0 (2021-12-14) The package of @azure/arm-servicebus is using our next generation design principles since version 5.0.0-beta.2, which contains breaking changes. diff --git a/sdk/servicebus/arm-servicebus/LICENSE b/sdk/servicebus/arm-servicebus/LICENSE index ccb63b166732..5d1d36e0af80 100644 --- a/sdk/servicebus/arm-servicebus/LICENSE +++ b/sdk/servicebus/arm-servicebus/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2021 Microsoft +Copyright (c) 2022 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/sdk/servicebus/arm-servicebus/_meta.json b/sdk/servicebus/arm-servicebus/_meta.json index c9b13deb24ea..57e02bcba43b 100644 --- a/sdk/servicebus/arm-servicebus/_meta.json +++ b/sdk/servicebus/arm-servicebus/_meta.json @@ -1,7 +1,8 @@ { - "commit": "6654157972dbf54b187150e389237494f35145f4", + "commit": "e4cd2cd3c80c468035fb120113fe68c7b5443502", "readme": "specification/servicebus/resource-manager/readme.md", - "autorest_command": "autorest --version=3.1.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\mydev\\azure-sdk-for-js ../azure-rest-api-specs/specification/servicebus/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.16.20211207.1", + "autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/servicebus/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.16.20220105.1", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "use": "@autorest/typescript@6.0.0-alpha.16.20211207.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.2.6", + "use": "@autorest/typescript@6.0.0-alpha.16.20220105.1" } \ No newline at end of file diff --git a/sdk/servicebus/arm-servicebus/api-extractor.json b/sdk/servicebus/arm-servicebus/api-extractor.json index 717703a7fb1a..19a08d6d2081 100644 --- a/sdk/servicebus/arm-servicebus/api-extractor.json +++ b/sdk/servicebus/arm-servicebus/api-extractor.json @@ -1,18 +1,31 @@ { "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json", "mainEntryPointFilePath": "./dist-esm/src/index.d.ts", - "docModel": { "enabled": true }, - "apiReport": { "enabled": true, "reportFolder": "./review" }, + "docModel": { + "enabled": true + }, + "apiReport": { + "enabled": true, + "reportFolder": "./review" + }, "dtsRollup": { "enabled": true, "untrimmedFilePath": "", "publicTrimmedFilePath": "./types/arm-servicebus.d.ts" }, "messages": { - "tsdocMessageReporting": { "default": { "logLevel": "none" } }, + "tsdocMessageReporting": { + "default": { + "logLevel": "none" + } + }, "extractorMessageReporting": { - "ae-missing-release-tag": { "logLevel": "none" }, - "ae-unresolved-link": { "logLevel": "none" } + "ae-missing-release-tag": { + "logLevel": "none" + }, + "ae-unresolved-link": { + "logLevel": "none" + } } } -} +} \ No newline at end of file diff --git a/sdk/servicebus/arm-servicebus/package.json b/sdk/servicebus/arm-servicebus/package.json index 5374da13058f..d50b028bb9a5 100644 --- a/sdk/servicebus/arm-servicebus/package.json +++ b/sdk/servicebus/arm-servicebus/package.json @@ -3,7 +3,7 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ServiceBusManagementClient.", - "version": "5.0.1", + "version": "6.0.0", "engines": { "node": ">=12.0.0" }, @@ -29,12 +29,12 @@ "types": "./types/arm-servicebus.d.ts", "devDependencies": { "@microsoft/api-extractor": "^7.18.11", - "@rollup/plugin-commonjs": "^21.0.1", + "@rollup/plugin-commonjs": "11.0.2", "@rollup/plugin-json": "^4.0.0", "@rollup/plugin-multi-entry": "^3.0.0", "@rollup/plugin-node-resolve": "^8.0.0", "mkdirp": "^1.0.4", - "rollup": "^2.0.0", + "rollup": "^1.16.3", "rollup-plugin-sourcemaps": "^0.4.2", "typescript": "~4.2.0", "uglify-js": "^3.4.9", @@ -99,4 +99,4 @@ }, "sideEffects": false, "autoPublish": true -} +} \ No newline at end of file diff --git a/sdk/servicebus/arm-servicebus/review/arm-servicebus.api.md b/sdk/servicebus/arm-servicebus/review/arm-servicebus.api.md index 56e8dff147bb..f2966d909123 100644 --- a/sdk/servicebus/arm-servicebus/review/arm-servicebus.api.md +++ b/sdk/servicebus/arm-servicebus/review/arm-servicebus.api.md @@ -32,7 +32,7 @@ export interface Action { } // @public -export type ArmDisasterRecovery = Resource & { +export type ArmDisasterRecovery = ProxyResource & { readonly systemData?: SystemData; readonly provisioningState?: ProvisioningStateDR; readonly pendingReplicationOperationsCount?: number; @@ -328,7 +328,7 @@ export interface MigrationConfigListResult { } // @public -export type MigrationConfigProperties = Resource & { +export type MigrationConfigProperties = ProxyResource & { readonly systemData?: SystemData; readonly provisioningState?: string; readonly pendingReplicationOperationsCount?: number; @@ -557,7 +557,7 @@ export type NamespacesUpdateResponse = SBNamespace; export type NetworkRuleIPAction = string; // @public -export type NetworkRuleSet = Resource & { +export type NetworkRuleSet = ProxyResource & { readonly systemData?: SystemData; trustedServiceAccessEnabled?: boolean; defaultAction?: DefaultAction; @@ -587,11 +587,15 @@ export interface NWRuleSetVirtualNetworkRules { // @public export interface Operation { display?: OperationDisplay; + isDataAction?: boolean; readonly name?: string; + origin?: string; + properties?: Record; } // @public export interface OperationDisplay { + readonly description?: string; readonly operation?: string; readonly provider?: string; readonly resource?: string; @@ -628,7 +632,7 @@ export interface PrivateEndpoint { } // @public -export type PrivateEndpointConnection = Resource & { +export type PrivateEndpointConnection = ProxyResource & { readonly systemData?: SystemData; privateEndpoint?: PrivateEndpoint; privateLinkServiceConnectionState?: ConnectionState; @@ -719,6 +723,14 @@ export interface PrivateLinkResourcesListResult { // @public export type ProvisioningStateDR = "Accepted" | "Succeeded" | "Failed"; +// @public +export interface ProxyResource { + readonly id?: string; + readonly location?: string; + readonly name?: string; + readonly type?: string; +} + // @public export type PublicNetworkAccessFlag = string; @@ -843,7 +855,7 @@ export type ResourceNamespacePatch = Resource & { export type RoleDisasterRecovery = "Primary" | "PrimaryNotReplicating" | "Secondary"; // @public -export type Rule = Resource & { +export type Rule = ProxyResource & { readonly systemData?: SystemData; action?: Action; filterType?: FilterType; @@ -902,7 +914,7 @@ export interface RulesListBySubscriptionsOptionalParams extends coreClient.Opera export type RulesListBySubscriptionsResponse = RuleListResult; // @public -export type SBAuthorizationRule = Resource & { +export type SBAuthorizationRule = ProxyResource & { readonly systemData?: SystemData; rights?: AccessRights[]; }; @@ -935,6 +947,7 @@ export type SBNamespace = TrackedResource & { encryption?: Encryption; privateEndpointConnections?: PrivateEndpointConnection[]; disableLocalAuth?: boolean; + alternateName?: string; }; // @public @@ -953,14 +966,14 @@ export type SBNamespaceUpdateParameters = ResourceNamespacePatch & { readonly updatedAt?: Date; readonly serviceBusEndpoint?: string; readonly metricId?: string; - zoneRedundant?: boolean; encryption?: Encryption; privateEndpointConnections?: PrivateEndpointConnection[]; disableLocalAuth?: boolean; + alternateName?: string; }; // @public -export type SBQueue = Resource & { +export type SBQueue = ProxyResource & { readonly systemData?: SystemData; readonly countDetails?: MessageCountDetails; readonly createdAt?: Date; @@ -1000,7 +1013,7 @@ export interface SBSku { } // @public -export type SBSubscription = Resource & { +export type SBSubscription = ProxyResource & { readonly systemData?: SystemData; readonly messageCount?: number; readonly createdAt?: Date; @@ -1030,7 +1043,7 @@ export interface SBSubscriptionListResult { } // @public -export type SBTopic = Resource & { +export type SBTopic = ProxyResource & { readonly systemData?: SystemData; readonly sizeInBytes?: number; readonly createdAt?: Date; diff --git a/sdk/servicebus/arm-servicebus/src/models/index.ts b/sdk/servicebus/arm-servicebus/src/models/index.ts index 106779bd4c10..acf9549edc51 100644 --- a/sdk/servicebus/arm-servicebus/src/models/index.ts +++ b/sdk/servicebus/arm-servicebus/src/models/index.ts @@ -114,6 +114,30 @@ export interface ConnectionState { description?: string; } +/** Common fields that are returned in the response for all Azure Resource Manager resources */ +export interface ProxyResource { + /** + * Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly id?: string; + /** + * The name of the resource + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly name?: string; + /** + * The type of the resource. E.g. "Microsoft.EventHub/Namespaces" or "Microsoft.EventHub/Namespaces/EventHubs" + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly type?: string; + /** + * The geo-location where the resource lives + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly location?: string; +} + /** The Resource definition for other than namespace. */ export interface Resource { /** @@ -227,53 +251,45 @@ export interface OperationListResult { readonly nextLink?: string; } -/** A ServiceBus REST API operation */ +/** A Service Bus REST API operation */ export interface Operation { /** * Operation name: {provider}/{resource}/{operation} * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly name?: string; - /** The object that represents the operation. */ + /** Indicates whether the operation is a data action */ + isDataAction?: boolean; + /** Display of the operation */ display?: OperationDisplay; + /** Origin of the operation */ + origin?: string; + /** Properties of the operation */ + properties?: Record; } -/** The object that represents the operation. */ +/** Operation display payload */ export interface OperationDisplay { /** - * Service provider: Microsoft.ServiceBus + * Resource provider of the operation * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provider?: string; /** - * Resource on which the operation is performed: Invoice, etc. + * Resource of the operation * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly resource?: string; /** - * Operation type: Read, write, delete, etc. + * Localized friendly name for the operation * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly operation?: string; -} - -/** Description of a Check Name availability request properties. */ -export interface CheckNameAvailability { - /** The Name to check the namespace name availability and The namespace name can contain only letters, numbers, and hyphens. The namespace must start with a letter, and it must end with a letter or number. */ - name: string; -} - -/** Description of a Check Name availability request properties. */ -export interface CheckNameAvailabilityResult { /** - * The detailed info regarding the reason associated with the namespace. + * Localized friendly description for the operation * NOTE: This property will not be serialized. It can only be populated by the server. */ - readonly message?: string; - /** Value indicating namespace is availability, true if the namespace is available; otherwise, false. */ - nameAvailable?: boolean; - /** The reason for unavailability of a namespace. */ - reason?: UnavailableReason; + readonly description?: string; } /** The result of the List Alias(Disaster Recovery configuration) operation. */ @@ -293,6 +309,47 @@ export interface FailoverProperties { isSafeFailover?: boolean; } +/** The result of the List migrationConfigurations operation. */ +export interface MigrationConfigListResult { + /** List of Migration Configs */ + value?: MigrationConfigProperties[]; + /** + * Link to the next set of results. Not empty if Value contains incomplete list of migrationConfigurations + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly nextLink?: string; +} + +/** Description of VirtualNetworkRules - NetworkRules resource. */ +export interface NWRuleSetVirtualNetworkRules { + /** Subnet properties */ + subnet?: Subnet; + /** Value that indicates whether to ignore missing VNet Service Endpoint */ + ignoreMissingVnetServiceEndpoint?: boolean; +} + +/** Properties supplied for Subnet */ +export interface Subnet { + /** Resource ID of Virtual Network Subnet */ + id: string; +} + +/** Description of NetWorkRuleSet - IpRules resource. */ +export interface NWRuleSetIpRules { + /** IP Mask */ + ipMask?: string; + /** The IP Filter Action */ + action?: NetworkRuleIPAction; +} + +/** The response of the List NetworkRuleSet operation. */ +export interface NetworkRuleSetListResult { + /** Result of the List NetworkRuleSet operation. */ + value?: NetworkRuleSet[]; + /** Link to the next set of results. Not empty if Value contains incomplete list of NetworkRuleSet. */ + nextLink?: string; +} + /** The response to the List Namespace operation. */ export interface SBAuthorizationRuleListResult { /** Result of the List Authorization Rules operation. */ @@ -340,47 +397,6 @@ export interface AccessKeys { readonly keyName?: string; } -/** The result of the List migrationConfigurations operation. */ -export interface MigrationConfigListResult { - /** List of Migration Configs */ - value?: MigrationConfigProperties[]; - /** - * Link to the next set of results. Not empty if Value contains incomplete list of migrationConfigurations - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly nextLink?: string; -} - -/** Description of VirtualNetworkRules - NetworkRules resource. */ -export interface NWRuleSetVirtualNetworkRules { - /** Subnet properties */ - subnet?: Subnet; - /** Value that indicates whether to ignore missing VNet Service Endpoint */ - ignoreMissingVnetServiceEndpoint?: boolean; -} - -/** Properties supplied for Subnet */ -export interface Subnet { - /** Resource ID of Virtual Network Subnet */ - id: string; -} - -/** Description of NetWorkRuleSet - IpRules resource. */ -export interface NWRuleSetIpRules { - /** IP Mask */ - ipMask?: string; - /** The IP Filter Action */ - action?: NetworkRuleIPAction; -} - -/** The response of the List NetworkRuleSet operation. */ -export interface NetworkRuleSetListResult { - /** Result of the List NetworkRuleSet operation. */ - value?: NetworkRuleSet[]; - /** Link to the next set of results. Not empty if Value contains incomplete list of NetworkRuleSet. */ - nextLink?: string; -} - /** Parameters supplied to the Regenerate Authorization Rule operation, specifies which key needs to be reset. */ export interface RegenerateAccessKeyParameters { /** The access key to regenerate. */ @@ -504,8 +520,27 @@ export interface SBClientAffineProperties { isShared?: boolean; } +/** Description of a Check Name availability request properties. */ +export interface CheckNameAvailability { + /** The Name to check the namespace name availability and The namespace name can contain only letters, numbers, and hyphens. The namespace must start with a letter, and it must end with a letter or number. */ + name: string; +} + +/** Description of a Check Name availability request properties. */ +export interface CheckNameAvailabilityResult { + /** + * The detailed info regarding the reason associated with the namespace. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly message?: string; + /** Value indicating namespace is availability, true if the namespace is available; otherwise, false. */ + nameAvailable?: boolean; + /** The reason for unavailability of a namespace. */ + reason?: UnavailableReason; +} + /** Properties of the PrivateEndpointConnection. */ -export type PrivateEndpointConnection = Resource & { +export type PrivateEndpointConnection = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -519,24 +554,8 @@ export type PrivateEndpointConnection = Resource & { provisioningState?: EndPointProvisioningState; }; -/** The Resource definition. */ -export type TrackedResource = Resource & { - /** The Geo-location where the resource lives */ - location: string; - /** Resource tags */ - tags?: { [propertyName: string]: string }; -}; - -/** The Resource definition. */ -export type ResourceNamespacePatch = Resource & { - /** Resource location */ - location?: string; - /** Resource tags */ - tags?: { [propertyName: string]: string }; -}; - /** Single item in List or Get Alias(Disaster Recovery configuration) operation */ -export type ArmDisasterRecovery = Resource & { +export type ArmDisasterRecovery = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -563,19 +582,8 @@ export type ArmDisasterRecovery = Resource & { readonly role?: RoleDisasterRecovery; }; -/** Description of a namespace authorization rule. */ -export type SBAuthorizationRule = Resource & { - /** - * The system meta data relating to this resource. - * NOTE: This property will not be serialized. It can only be populated by the server. - */ - readonly systemData?: SystemData; - /** The rights associated with the rule. */ - rights?: AccessRights[]; -}; - /** Single item in List or Get Migration Config operation */ -export type MigrationConfigProperties = Resource & { +export type MigrationConfigProperties = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -603,7 +611,7 @@ export type MigrationConfigProperties = Resource & { }; /** Description of NetworkRuleSet resource. */ -export type NetworkRuleSet = Resource & { +export type NetworkRuleSet = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -621,8 +629,19 @@ export type NetworkRuleSet = Resource & { publicNetworkAccess?: PublicNetworkAccessFlag; }; +/** Description of a namespace authorization rule. */ +export type SBAuthorizationRule = ProxyResource & { + /** + * The system meta data relating to this resource. + * NOTE: This property will not be serialized. It can only be populated by the server. + */ + readonly systemData?: SystemData; + /** The rights associated with the rule. */ + rights?: AccessRights[]; +}; + /** Description of queue Resource. */ -export type SBQueue = Resource & { +export type SBQueue = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -693,7 +712,7 @@ export type SBQueue = Resource & { }; /** Description of topic resource. */ -export type SBTopic = Resource & { +export type SBTopic = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -754,7 +773,7 @@ export type SBTopic = Resource & { }; /** Description of Rule Resource. */ -export type Rule = Resource & { +export type Rule = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -771,7 +790,7 @@ export type Rule = Resource & { }; /** Description of subscription resource. */ -export type SBSubscription = Resource & { +export type SBSubscription = ProxyResource & { /** * The system meta data relating to this resource. * NOTE: This property will not be serialized. It can only be populated by the server. @@ -832,6 +851,22 @@ export type SBSubscription = Resource & { clientAffineProperties?: SBClientAffineProperties; }; +/** The Resource definition. */ +export type TrackedResource = Resource & { + /** The Geo-location where the resource lives */ + location: string; + /** Resource tags */ + tags?: { [propertyName: string]: string }; +}; + +/** The Resource definition. */ +export type ResourceNamespacePatch = Resource & { + /** Resource location */ + location?: string; + /** Resource tags */ + tags?: { [propertyName: string]: string }; +}; + /** Represents set of actions written in SQL language-based syntax that is performed against a ServiceBus.Messaging.BrokeredMessage */ export type SqlRuleAction = Action & {}; @@ -884,6 +919,8 @@ export type SBNamespace = TrackedResource & { privateEndpointConnections?: PrivateEndpointConnection[]; /** This property disables SAS authentication for the Service Bus namespace. */ disableLocalAuth?: boolean; + /** Alternate name for namespace */ + alternateName?: string; }; /** Description of a namespace resource. */ @@ -922,14 +959,14 @@ export type SBNamespaceUpdateParameters = ResourceNamespacePatch & { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly metricId?: string; - /** Enabling this property creates a Premium Service Bus Namespace in regions supported availability zones. */ - zoneRedundant?: boolean; /** Properties of BYOK Encryption description */ encryption?: Encryption; /** List of private endpoint connections. */ privateEndpointConnections?: PrivateEndpointConnection[]; /** This property disables SAS authentication for the Service Bus namespace. */ disableLocalAuth?: boolean; + /** Alternate name for namespace */ + alternateName?: string; }; /** Known values of {@link CreatedByType} that the service accepts. */ @@ -1065,14 +1102,6 @@ export type ManagedServiceIdentityType = | "UserAssigned" | "SystemAssigned, UserAssigned" | "None"; -/** Defines values for UnavailableReason. */ -export type UnavailableReason = - | "None" - | "InvalidName" - | "SubscriptionIsDisabled" - | "NameInUse" - | "NameInLockdown" - | "TooManyNamespaceInCurrentSubscription"; /** Defines values for ProvisioningStateDR. */ export type ProvisioningStateDR = "Accepted" | "Succeeded" | "Failed"; /** Defines values for RoleDisasterRecovery. */ @@ -1097,6 +1126,14 @@ export type EntityStatus = | "Unknown"; /** Defines values for FilterType. */ export type FilterType = "SqlFilter" | "CorrelationFilter"; +/** Defines values for UnavailableReason. */ +export type UnavailableReason = + | "None" + | "InvalidName" + | "SubscriptionIsDisabled" + | "NameInUse" + | "NameInLockdown" + | "TooManyNamespaceInCurrentSubscription"; /** Optional parameters. */ export interface NamespacesListOptionalParams @@ -1300,13 +1337,6 @@ export interface OperationsListNextOptionalParams /** Contains response data for the listNext operation. */ export type OperationsListNextResponse = OperationListResult; -/** Optional parameters. */ -export interface DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams - extends coreClient.OperationOptions {} - -/** Contains response data for the checkNameAvailability operation. */ -export type DisasterRecoveryConfigsCheckNameAvailabilityResponse = CheckNameAvailabilityResult; - /** Optional parameters. */ export interface DisasterRecoveryConfigsListOptionalParams extends coreClient.OperationOptions {} @@ -1364,6 +1394,13 @@ export interface DisasterRecoveryConfigsListKeysOptionalParams /** Contains response data for the listKeys operation. */ export type DisasterRecoveryConfigsListKeysResponse = AccessKeys; +/** Optional parameters. */ +export interface DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams + extends coreClient.OperationOptions {} + +/** Contains response data for the checkNameAvailability operation. */ +export type DisasterRecoveryConfigsCheckNameAvailabilityResponse = CheckNameAvailabilityResult; + /** Optional parameters. */ export interface DisasterRecoveryConfigsListNextOptionalParams extends coreClient.OperationOptions {} diff --git a/sdk/servicebus/arm-servicebus/src/models/mappers.ts b/sdk/servicebus/arm-servicebus/src/models/mappers.ts index 3a2e6a888644..ea8928ac5ab7 100644 --- a/sdk/servicebus/arm-servicebus/src/models/mappers.ts +++ b/sdk/servicebus/arm-servicebus/src/models/mappers.ts @@ -297,6 +297,43 @@ export const ConnectionState: coreClient.CompositeMapper = { } }; +export const ProxyResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ProxyResource", + modelProperties: { + id: { + serializedName: "id", + readOnly: true, + type: { + name: "String" + } + }, + name: { + serializedName: "name", + readOnly: true, + type: { + name: "String" + } + }, + type: { + serializedName: "type", + readOnly: true, + type: { + name: "String" + } + }, + location: { + serializedName: "location", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + export const Resource: coreClient.CompositeMapper = { type: { name: "Composite", @@ -573,12 +610,31 @@ export const Operation: coreClient.CompositeMapper = { name: "String" } }, + isDataAction: { + serializedName: "isDataAction", + type: { + name: "Boolean" + } + }, display: { serializedName: "display", type: { name: "Composite", className: "OperationDisplay" } + }, + origin: { + serializedName: "origin", + type: { + name: "String" + } + }, + properties: { + serializedName: "properties", + type: { + name: "Dictionary", + value: { type: { name: "any" } } + } } } } @@ -609,58 +665,13 @@ export const OperationDisplay: coreClient.CompositeMapper = { type: { name: "String" } - } - } - } -}; - -export const CheckNameAvailability: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CheckNameAvailability", - modelProperties: { - name: { - serializedName: "name", - required: true, - type: { - name: "String" - } - } - } - } -}; - -export const CheckNameAvailabilityResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "CheckNameAvailabilityResult", - modelProperties: { - message: { - serializedName: "message", + }, + description: { + serializedName: "description", readOnly: true, type: { name: "String" } - }, - nameAvailable: { - serializedName: "nameAvailable", - type: { - name: "Boolean" - } - }, - reason: { - serializedName: "reason", - type: { - name: "Enum", - allowedValues: [ - "None", - "InvalidName", - "SubscriptionIsDisabled", - "NameInUse", - "NameInLockdown", - "TooManyNamespaceInCurrentSubscription" - ] - } } } } @@ -709,91 +720,6 @@ export const FailoverProperties: coreClient.CompositeMapper = { } }; -export const SBAuthorizationRuleListResult: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SBAuthorizationRuleListResult", - modelProperties: { - value: { - serializedName: "value", - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "SBAuthorizationRule" - } - } - } - }, - nextLink: { - serializedName: "nextLink", - type: { - name: "String" - } - } - } - } -}; - -export const AccessKeys: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "AccessKeys", - modelProperties: { - primaryConnectionString: { - serializedName: "primaryConnectionString", - readOnly: true, - type: { - name: "String" - } - }, - secondaryConnectionString: { - serializedName: "secondaryConnectionString", - readOnly: true, - type: { - name: "String" - } - }, - aliasPrimaryConnectionString: { - serializedName: "aliasPrimaryConnectionString", - readOnly: true, - type: { - name: "String" - } - }, - aliasSecondaryConnectionString: { - serializedName: "aliasSecondaryConnectionString", - readOnly: true, - type: { - name: "String" - } - }, - primaryKey: { - serializedName: "primaryKey", - readOnly: true, - type: { - name: "String" - } - }, - secondaryKey: { - serializedName: "secondaryKey", - readOnly: true, - type: { - name: "String" - } - }, - keyName: { - serializedName: "keyName", - readOnly: true, - type: { - name: "String" - } - } - } - } -}; - export const MigrationConfigListResult: coreClient.CompositeMapper = { type: { name: "Composite", @@ -909,6 +835,91 @@ export const NetworkRuleSetListResult: coreClient.CompositeMapper = { } }; +export const SBAuthorizationRuleListResult: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SBAuthorizationRuleListResult", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SBAuthorizationRule" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AccessKeys: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "AccessKeys", + modelProperties: { + primaryConnectionString: { + serializedName: "primaryConnectionString", + readOnly: true, + type: { + name: "String" + } + }, + secondaryConnectionString: { + serializedName: "secondaryConnectionString", + readOnly: true, + type: { + name: "String" + } + }, + aliasPrimaryConnectionString: { + serializedName: "aliasPrimaryConnectionString", + readOnly: true, + type: { + name: "String" + } + }, + aliasSecondaryConnectionString: { + serializedName: "aliasSecondaryConnectionString", + readOnly: true, + type: { + name: "String" + } + }, + primaryKey: { + serializedName: "primaryKey", + readOnly: true, + type: { + name: "String" + } + }, + secondaryKey: { + serializedName: "secondaryKey", + readOnly: true, + type: { + name: "String" + } + }, + keyName: { + serializedName: "keyName", + readOnly: true, + type: { + name: "String" + } + } + } + } +}; + export const RegenerateAccessKeyParameters: coreClient.CompositeMapper = { type: { name: "Composite", @@ -1238,35 +1249,14 @@ export const SBClientAffineProperties: coreClient.CompositeMapper = { } }; -export const PrivateEndpointConnection: coreClient.CompositeMapper = { +export const CheckNameAvailability: coreClient.CompositeMapper = { type: { name: "Composite", - className: "PrivateEndpointConnection", + className: "CheckNameAvailability", modelProperties: { - ...Resource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, - privateEndpoint: { - serializedName: "properties.privateEndpoint", - type: { - name: "Composite", - className: "PrivateEndpoint" - } - }, - privateLinkServiceConnectionState: { - serializedName: "properties.privateLinkServiceConnectionState", - type: { - name: "Composite", - className: "ConnectionState" - } - }, - provisioningState: { - serializedName: "properties.provisioningState", + name: { + serializedName: "name", + required: true, type: { name: "String" } @@ -1275,47 +1265,73 @@ export const PrivateEndpointConnection: coreClient.CompositeMapper = { } }; -export const TrackedResource: coreClient.CompositeMapper = { +export const CheckNameAvailabilityResult: coreClient.CompositeMapper = { type: { name: "Composite", - className: "TrackedResource", + className: "CheckNameAvailabilityResult", modelProperties: { - ...Resource.type.modelProperties, - location: { - serializedName: "location", - required: true, + message: { + serializedName: "message", + readOnly: true, type: { name: "String" } }, - tags: { - serializedName: "tags", + nameAvailable: { + serializedName: "nameAvailable", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "Boolean" + } + }, + reason: { + serializedName: "reason", + type: { + name: "Enum", + allowedValues: [ + "None", + "InvalidName", + "SubscriptionIsDisabled", + "NameInUse", + "NameInLockdown", + "TooManyNamespaceInCurrentSubscription" + ] } } } } }; -export const ResourceNamespacePatch: coreClient.CompositeMapper = { +export const PrivateEndpointConnection: coreClient.CompositeMapper = { type: { name: "Composite", - className: "ResourceNamespacePatch", + className: "PrivateEndpointConnection", modelProperties: { - ...Resource.type.modelProperties, - location: { - serializedName: "location", + ...ProxyResource.type.modelProperties, + systemData: { + serializedName: "systemData", type: { - name: "String" + name: "Composite", + className: "SystemData" } }, - tags: { - serializedName: "tags", + privateEndpoint: { + serializedName: "properties.privateEndpoint", type: { - name: "Dictionary", - value: { type: { name: "String" } } + name: "Composite", + className: "PrivateEndpoint" + } + }, + privateLinkServiceConnectionState: { + serializedName: "properties.privateLinkServiceConnectionState", + type: { + name: "Composite", + className: "ConnectionState" + } + }, + provisioningState: { + serializedName: "properties.provisioningState", + type: { + name: "String" } } } @@ -1327,7 +1343,7 @@ export const ArmDisasterRecovery: coreClient.CompositeMapper = { name: "Composite", className: "ArmDisasterRecovery", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1374,41 +1390,12 @@ export const ArmDisasterRecovery: coreClient.CompositeMapper = { } }; -export const SBAuthorizationRule: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SBAuthorizationRule", - modelProperties: { - ...Resource.type.modelProperties, - systemData: { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData" - } - }, - rights: { - serializedName: "properties.rights", - type: { - name: "Sequence", - element: { - type: { - name: "Enum", - allowedValues: ["Manage", "Send", "Listen"] - } - } - } - } - } - } -}; - export const MigrationConfigProperties: coreClient.CompositeMapper = { type: { name: "Composite", className: "MigrationConfigProperties", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1458,7 +1445,7 @@ export const NetworkRuleSet: coreClient.CompositeMapper = { name: "Composite", className: "NetworkRuleSet", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1513,12 +1500,41 @@ export const NetworkRuleSet: coreClient.CompositeMapper = { } }; +export const SBAuthorizationRule: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SBAuthorizationRule", + modelProperties: { + ...ProxyResource.type.modelProperties, + systemData: { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + }, + rights: { + serializedName: "properties.rights", + type: { + name: "Sequence", + element: { + type: { + name: "Enum", + allowedValues: ["Manage", "Send", "Listen"] + } + } + } + } + } + } +}; + export const SBQueue: coreClient.CompositeMapper = { type: { name: "Composite", className: "SBQueue", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1684,7 +1700,7 @@ export const SBTopic: coreClient.CompositeMapper = { name: "Composite", className: "SBTopic", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1820,7 +1836,7 @@ export const Rule: coreClient.CompositeMapper = { name: "Composite", className: "Rule", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -1865,7 +1881,7 @@ export const SBSubscription: coreClient.CompositeMapper = { name: "Composite", className: "SBSubscription", modelProperties: { - ...Resource.type.modelProperties, + ...ProxyResource.type.modelProperties, systemData: { serializedName: "systemData", type: { @@ -2008,6 +2024,53 @@ export const SBSubscription: coreClient.CompositeMapper = { } }; +export const TrackedResource: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "TrackedResource", + modelProperties: { + ...Resource.type.modelProperties, + location: { + serializedName: "location", + required: true, + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + } + } + } +}; + +export const ResourceNamespacePatch: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "ResourceNamespacePatch", + modelProperties: { + ...Resource.type.modelProperties, + location: { + serializedName: "location", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { type: { name: "String" } } + } + } + } + } +}; + export const SqlRuleAction: coreClient.CompositeMapper = { type: { name: "Composite", @@ -2117,6 +2180,12 @@ export const SBNamespace: coreClient.CompositeMapper = { type: { name: "Boolean" } + }, + alternateName: { + serializedName: "properties.alternateName", + type: { + name: "String" + } } } } @@ -2184,12 +2253,6 @@ export const SBNamespaceUpdateParameters: coreClient.CompositeMapper = { name: "String" } }, - zoneRedundant: { - serializedName: "properties.zoneRedundant", - type: { - name: "Boolean" - } - }, encryption: { serializedName: "properties.encryption", type: { @@ -2214,6 +2277,12 @@ export const SBNamespaceUpdateParameters: coreClient.CompositeMapper = { type: { name: "Boolean" } + }, + alternateName: { + serializedName: "properties.alternateName", + type: { + name: "String" + } } } } diff --git a/sdk/servicebus/arm-servicebus/src/models/parameters.ts b/sdk/servicebus/arm-servicebus/src/models/parameters.ts index ccd12b447d7c..67b35a71e23f 100644 --- a/sdk/servicebus/arm-servicebus/src/models/parameters.ts +++ b/sdk/servicebus/arm-servicebus/src/models/parameters.ts @@ -55,7 +55,7 @@ export const $host: OperationURLParameter = { export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2021-06-01-preview", + defaultValue: "2021-11-01", isConstant: true, serializedName: "api-version", type: { diff --git a/sdk/servicebus/arm-servicebus/src/operations/disasterRecoveryConfigs.ts b/sdk/servicebus/arm-servicebus/src/operations/disasterRecoveryConfigs.ts index 1d1f5610c24e..2aa9fbd99acf 100644 --- a/sdk/servicebus/arm-servicebus/src/operations/disasterRecoveryConfigs.ts +++ b/sdk/servicebus/arm-servicebus/src/operations/disasterRecoveryConfigs.ts @@ -19,9 +19,6 @@ import { SBAuthorizationRule, DisasterRecoveryConfigsListAuthorizationRulesNextOptionalParams, DisasterRecoveryConfigsListAuthorizationRulesOptionalParams, - CheckNameAvailability, - DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams, - DisasterRecoveryConfigsCheckNameAvailabilityResponse, DisasterRecoveryConfigsListResponse, DisasterRecoveryConfigsCreateOrUpdateOptionalParams, DisasterRecoveryConfigsCreateOrUpdateResponse, @@ -35,6 +32,9 @@ import { DisasterRecoveryConfigsGetAuthorizationRuleResponse, DisasterRecoveryConfigsListKeysOptionalParams, DisasterRecoveryConfigsListKeysResponse, + CheckNameAvailability, + DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams, + DisasterRecoveryConfigsCheckNameAvailabilityResponse, DisasterRecoveryConfigsListNextResponse, DisasterRecoveryConfigsListAuthorizationRulesNextResponse } from "../models"; @@ -191,25 +191,6 @@ export class DisasterRecoveryConfigsImpl implements DisasterRecoveryConfigs { } } - /** - * Check the give namespace name availability. - * @param resourceGroupName Name of the Resource group within the Azure subscription. - * @param namespaceName The namespace name - * @param parameters Parameters to check availability of the given namespace name - * @param options The options parameters. - */ - checkNameAvailability( - resourceGroupName: string, - namespaceName: string, - parameters: CheckNameAvailability, - options?: DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams - ): Promise { - return this.client.sendOperationRequest( - { resourceGroupName, namespaceName, parameters, options }, - checkNameAvailabilityOperationSpec - ); - } - /** * Gets all Alias(Disaster Recovery configurations) * @param resourceGroupName Name of the Resource group within the Azure subscription. @@ -398,6 +379,25 @@ export class DisasterRecoveryConfigsImpl implements DisasterRecoveryConfigs { ); } + /** + * Check the give namespace name availability. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param namespaceName The namespace name + * @param parameters Parameters to check availability of the given namespace name + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + namespaceName: string, + parameters: CheckNameAvailability, + options?: DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams + ): Promise { + return this.client.sendOperationRequest( + { resourceGroupName, namespaceName, parameters, options }, + checkNameAvailabilityOperationSpec + ); + } + /** * ListNext * @param resourceGroupName Name of the Resource group within the Azure subscription. @@ -441,30 +441,6 @@ export class DisasterRecoveryConfigsImpl implements DisasterRecoveryConfigs { // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); -const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceBus/namespaces/{namespaceName}/disasterRecoveryConfigs/CheckNameAvailability", - httpMethod: "POST", - responses: { - 200: { - bodyMapper: Mappers.CheckNameAvailabilityResult - }, - default: { - bodyMapper: Mappers.ErrorResponse - } - }, - requestBody: Parameters.parameters5, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.namespaceName1 - ], - headerParameters: [Parameters.accept, Parameters.contentType], - mediaType: "json", - serializer -}; const listOperationSpec: coreClient.OperationSpec = { path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceBus/namespaces/{namespaceName}/disasterRecoveryConfigs", @@ -519,6 +495,7 @@ const deleteOperationSpec: coreClient.OperationSpec = { httpMethod: "DELETE", responses: { 200: {}, + 204: {}, default: { bodyMapper: Mappers.ErrorResponse } @@ -672,6 +649,30 @@ const listKeysOperationSpec: coreClient.OperationSpec = { headerParameters: [Parameters.accept], serializer }; +const checkNameAvailabilityOperationSpec: coreClient.OperationSpec = { + path: + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceBus/namespaces/{namespaceName}/disasterRecoveryConfigs/CheckNameAvailability", + httpMethod: "POST", + responses: { + 200: { + bodyMapper: Mappers.CheckNameAvailabilityResult + }, + default: { + bodyMapper: Mappers.ErrorResponse + } + }, + requestBody: Parameters.parameters5, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.namespaceName1 + ], + headerParameters: [Parameters.accept, Parameters.contentType], + mediaType: "json", + serializer +}; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", diff --git a/sdk/servicebus/arm-servicebus/src/operationsInterfaces/disasterRecoveryConfigs.ts b/sdk/servicebus/arm-servicebus/src/operationsInterfaces/disasterRecoveryConfigs.ts index 49423c7f7895..8aa9c05e9c83 100644 --- a/sdk/servicebus/arm-servicebus/src/operationsInterfaces/disasterRecoveryConfigs.ts +++ b/sdk/servicebus/arm-servicebus/src/operationsInterfaces/disasterRecoveryConfigs.ts @@ -12,9 +12,6 @@ import { DisasterRecoveryConfigsListOptionalParams, SBAuthorizationRule, DisasterRecoveryConfigsListAuthorizationRulesOptionalParams, - CheckNameAvailability, - DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams, - DisasterRecoveryConfigsCheckNameAvailabilityResponse, DisasterRecoveryConfigsCreateOrUpdateOptionalParams, DisasterRecoveryConfigsCreateOrUpdateResponse, DisasterRecoveryConfigsDeleteOptionalParams, @@ -25,7 +22,10 @@ import { DisasterRecoveryConfigsGetAuthorizationRuleOptionalParams, DisasterRecoveryConfigsGetAuthorizationRuleResponse, DisasterRecoveryConfigsListKeysOptionalParams, - DisasterRecoveryConfigsListKeysResponse + DisasterRecoveryConfigsListKeysResponse, + CheckNameAvailability, + DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams, + DisasterRecoveryConfigsCheckNameAvailabilityResponse } from "../models"; /// @@ -55,19 +55,6 @@ export interface DisasterRecoveryConfigs { alias: string, options?: DisasterRecoveryConfigsListAuthorizationRulesOptionalParams ): PagedAsyncIterableIterator; - /** - * Check the give namespace name availability. - * @param resourceGroupName Name of the Resource group within the Azure subscription. - * @param namespaceName The namespace name - * @param parameters Parameters to check availability of the given namespace name - * @param options The options parameters. - */ - checkNameAvailability( - resourceGroupName: string, - namespaceName: string, - parameters: CheckNameAvailability, - options?: DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams - ): Promise; /** * Creates or updates a new Alias(Disaster Recovery configuration) * @param resourceGroupName Name of the Resource group within the Azure subscription. @@ -166,4 +153,17 @@ export interface DisasterRecoveryConfigs { authorizationRuleName: string, options?: DisasterRecoveryConfigsListKeysOptionalParams ): Promise; + /** + * Check the give namespace name availability. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param namespaceName The namespace name + * @param parameters Parameters to check availability of the given namespace name + * @param options The options parameters. + */ + checkNameAvailability( + resourceGroupName: string, + namespaceName: string, + parameters: CheckNameAvailability, + options?: DisasterRecoveryConfigsCheckNameAvailabilityOptionalParams + ): Promise; } diff --git a/sdk/servicebus/arm-servicebus/src/serviceBusManagementClient.ts b/sdk/servicebus/arm-servicebus/src/serviceBusManagementClient.ts index 24e60599375c..0af071cd59f7 100644 --- a/sdk/servicebus/arm-servicebus/src/serviceBusManagementClient.ts +++ b/sdk/servicebus/arm-servicebus/src/serviceBusManagementClient.ts @@ -67,7 +67,7 @@ export class ServiceBusManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-servicebus/5.0.0`; + const packageDetails = `azsdk-js-arm-servicebus/6.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -90,7 +90,7 @@ export class ServiceBusManagementClient extends coreClient.ServiceClient { // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2021-06-01-preview"; + this.apiVersion = options.apiVersion || "2021-11-01"; this.namespaces = new NamespacesImpl(this); this.privateEndpointConnections = new PrivateEndpointConnectionsImpl(this); this.privateLinkResources = new PrivateLinkResourcesImpl(this); diff --git a/sdk/servicebus/arm-servicebus/test/sampleTest.ts b/sdk/servicebus/arm-servicebus/test/sampleTest.ts index 39667151b076..7ed89b043e1b 100644 --- a/sdk/servicebus/arm-servicebus/test/sampleTest.ts +++ b/sdk/servicebus/arm-servicebus/test/sampleTest.ts @@ -10,13 +10,9 @@ import { env, record, RecorderEnvironmentSetup, - Recorder, - delay, - isPlaybackMode + Recorder } from "@azure-tools/test-recorder"; import * as assert from "assert"; -import { ClientSecretCredential } from "@azure/identity"; -import { ServiceBusManagementClient } from "../src/serviceBusManagementClient"; const recorderEnvSetup: RecorderEnvironmentSetup = { replaceableVariables: { @@ -35,115 +31,18 @@ const recorderEnvSetup: RecorderEnvironmentSetup = { queryParametersToSkip: [] }; -export const testPollingOptions = { - updateIntervalInMs: isPlaybackMode() ? 0 : undefined, -}; - -describe("ServiceBus test", () => { +describe("My test", () => { let recorder: Recorder; - let subscriptionId: string; - let client: ServiceBusManagementClient; - let location: string; - let resourceGroup: string; - let namespacesName: string; - let authorizationRuleName: string; - let queueName: string; - let topicName: string; beforeEach(async function() { recorder = record(this, recorderEnvSetup); - subscriptionId = env.SUBSCRIPTION_ID; - // This is an example of how the environment variables are used - const credential = new ClientSecretCredential( - env.AZURE_TENANT_ID, - env.AZURE_CLIENT_ID, - env.AZURE_CLIENT_SECRET - ); - client = new ServiceBusManagementClient(credential, subscriptionId); - location = "eastus"; - resourceGroup = "myjstest"; - namespacesName = "mynamespacexxx"; - authorizationRuleName = "myAuthoriztionRule"; - queueName = "myQueue"; - topicName = "mytopic"; }); afterEach(async function() { await recorder.stop(); }); - it("namespaces create test", async function() { - const res = await client.namespaces.beginCreateOrUpdateAndWait(resourceGroup,namespacesName,{ - sku: { - name: "Standard", - tier: "Standard", - }, - location: location, - tags: { - tag1: "value1", - tag2: "value2", - } - },testPollingOptions) - assert.equal(res.name,namespacesName); - }); - - it("queues create test", async function() { - const res = await client.queues.createOrUpdate(resourceGroup,namespacesName,queueName,{enablePartitioning: true}); - assert.equal(res.name,queueName); - }); - - it("queues get test", async function() { - const res = await client.queues.get(resourceGroup,namespacesName,queueName); - assert.equal(res.name,queueName); - }); - - it("queues list test", async function() { - const resArray = new Array(); - for await (let item of client.queues.listByNamespace(resourceGroup,namespacesName)){ - resArray.push(item); - } - assert.equal(resArray.length,1); - }); - - it("topics create test", async function() { - const res = await client.topics.createOrUpdate(resourceGroup,namespacesName,topicName,{ - enableExpress: true - }) - assert.equal(res.name,topicName); - }); - - it("topics get test", async function() { - const res = await client.topics.get(resourceGroup,namespacesName,topicName); - assert.equal(res.name,topicName); - }); - - it("topics list test", async function() { - const resArray = new Array(); - for await (let item of client.topics.listByNamespace(resourceGroup,namespacesName)){ - resArray.push(item); - } - assert.equal(resArray.length,1); - }); - - it("queues delete test", async function() { - const res = await client.queues.delete(resourceGroup,namespacesName,queueName); - const resArray = new Array(); - for await (let item of client.queues.listByNamespace(resourceGroup,namespacesName)){ - resArray.push(item); - } - assert.equal(resArray.length,0); - }); - - it("topics delete test", async function() { - const res = await client.topics.delete(resourceGroup,namespacesName,topicName); - const resArray = new Array(); - for await (let item of client.topics.listByNamespace(resourceGroup,namespacesName)){ - resArray.push(item); - } - assert.equal(resArray.length,0); - }); - - it("namespaces delete test", async function() { - const res = await client.namespaces.beginDeleteAndWait(resourceGroup,namespacesName,testPollingOptions); + it("sample test", async function() { + console.log("Hi, I'm a test!"); }); }); diff --git a/sdk/servicebus/arm-servicebus/tsconfig.json b/sdk/servicebus/arm-servicebus/tsconfig.json index 6e3251194117..3e6ae96443f3 100644 --- a/sdk/servicebus/arm-servicebus/tsconfig.json +++ b/sdk/servicebus/arm-servicebus/tsconfig.json @@ -9,11 +9,19 @@ "esModuleInterop": true, "allowSyntheticDefaultImports": true, "forceConsistentCasingInFileNames": true, - "lib": ["es6", "dom"], + "lib": [ + "es6", + "dom" + ], "declaration": true, "outDir": "./dist-esm", "importHelpers": true }, - "include": ["./src/**/*.ts", "./test/**/*.ts"], - "exclude": ["node_modules"] -} + "include": [ + "./src/**/*.ts", + "./test/**/*.ts" + ], + "exclude": [ + "node_modules" + ] +} \ No newline at end of file diff --git a/sdk/servicebus/ci.mgmt.yml b/sdk/servicebus/ci.mgmt.yml index 708e170938c4..1b031cbe4581 100644 --- a/sdk/servicebus/ci.mgmt.yml +++ b/sdk/servicebus/ci.mgmt.yml @@ -1,5 +1,5 @@ # NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file. - + trigger: branches: include: @@ -10,6 +10,8 @@ trigger: include: - sdk/servicebus-map/ci.mgmt.yml - sdk/servicebus-map/arm-servicebus/ + - sdk/servicebus/arm-servicebus + - sdk/servicebus/ci.mgmt.yml pr: branches: include: @@ -23,11 +25,12 @@ pr: include: - sdk/servicebus-map/ci.mgmt.yml - sdk/servicebus-map/arm-servicebus/ - + - sdk/servicebus/arm-servicebus + - sdk/servicebus/ci.mgmt.yml extends: template: /eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: ServiceDirectory: servicebus Artifacts: - name: azure-arm-servicebus - safeName: azurearmservicebus \ No newline at end of file + safeName: azurearmservicebus diff --git a/sdk/servicebus/ci.yml b/sdk/servicebus/ci.yml index a649522437d0..c5f70a45adce 100644 --- a/sdk/servicebus/ci.yml +++ b/sdk/servicebus/ci.yml @@ -1,4 +1,5 @@ # NOTE: Please refer to https://aka.ms/azsdk/engsys/ci-yaml before editing this file. + trigger: branches: include: @@ -11,6 +12,8 @@ trigger: exclude: - sdk/servicebus-map/ci.mgmt.yml - sdk/servicebus-map/arm-servicebus/ + - sdk/servicebus/arm-servicebus + - sdk/servicebus/ci.mgmt.yml pr: branches: include: @@ -26,6 +29,8 @@ pr: exclude: - sdk/servicebus-map/ci.mgmt.yml - sdk/servicebus-map/arm-servicebus/ + - sdk/servicebus/arm-servicebus + - sdk/servicebus/ci.mgmt.yml extends: template: ../../eng/pipelines/templates/stages/archetype-sdk-client.yml parameters: