diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index 618cd74b6549..a5c03418735a 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -3928,7 +3928,7 @@ packages: dependencies: semver: 7.3.8 shelljs: 0.8.5 - typescript: 5.0.0-dev.20230216 + typescript: 5.0.0-dev.20230219 dev: false /downlevel-dts/0.7.0: @@ -8712,8 +8712,8 @@ packages: hasBin: true dev: false - /typescript/5.0.0-dev.20230216: - resolution: {integrity: sha512-yeZZGWiNc5pbGg4J/bgN7vq2Lrs4YTNzhG5dv8owIe1PyYX4tMDla8NnXipy9h4Cmw6+DQA8FG9XZbymgmzSbA==} + /typescript/5.0.0-dev.20230219: + resolution: {integrity: sha512-CjlwGu0BGvavGAPs7/2sng1K0EYubaZc3irzGboNBs83OI2+ij4QixjS8+nXcoR4H3uumDnyd7Vo/LoIgdSa7Q==} engines: {node: '>=4.2.0'} hasBin: true dev: false @@ -14818,15 +14818,15 @@ packages: dev: false file:projects/arm-storage.tgz: - resolution: {integrity: sha512-JKl5iYV6SJpnE1inwq1qvS9Prr04vm3Kim4OZBTXAwDUF6wE7XCEZxCOGBqcP1KCSeN8ATecp5Aoercva6jIEg==, tarball: file:projects/arm-storage.tgz} + resolution: {integrity: sha512-870Sdai/XCdwUeGkgS8F6wcDfxSJYH2WNJ13c/f3jHUXv3XxhSaTN74sBOurfKkUgLo8712rLEwrELn9EmyTyA==, tarball: file:projects/arm-storage.tgz} name: '@rush-temp/arm-storage' version: 0.0.0 dependencies: '@azure/identity': 2.1.0 '@microsoft/api-extractor': 7.34.3_@types+node@14.18.36 - '@rollup/plugin-commonjs': 24.0.1_rollup@2.79.1 - '@rollup/plugin-json': 6.0.0_rollup@2.79.1 - '@rollup/plugin-multi-entry': 6.0.0_rollup@2.79.1 + '@rollup/plugin-commonjs': 21.1.0_rollup@2.79.1 + '@rollup/plugin-json': 4.1.0_rollup@2.79.1 + '@rollup/plugin-multi-entry': 4.1.0_rollup@2.79.1 '@rollup/plugin-node-resolve': 13.3.0_rollup@2.79.1 '@types/chai': 4.3.4 '@types/node': 14.18.36 diff --git a/sdk/storage/arm-storage/CHANGELOG.md b/sdk/storage/arm-storage/CHANGELOG.md index 94bbdce0b6c6..662c9b17a1d8 100644 --- a/sdk/storage/arm-storage/CHANGELOG.md +++ b/sdk/storage/arm-storage/CHANGELOG.md @@ -1,15 +1,22 @@ # Release History + +## 19.0.0 (2023-02-20) + +**Breaking Changes** -## 18.1.1 (Unreleased) - -### Features Added - -### Breaking Changes - -### Bugs Fixed - -### Other Changes - + - Interface BlobContainersListNextOptionalParams no longer has parameter filter + - Interface BlobContainersListNextOptionalParams no longer has parameter include + - Interface BlobContainersListNextOptionalParams no longer has parameter maxpagesize + - Interface EncryptionScopesListNextOptionalParams no longer has parameter filter + - Interface EncryptionScopesListNextOptionalParams no longer has parameter include + - Interface EncryptionScopesListNextOptionalParams no longer has parameter maxpagesize + - Interface FileSharesListNextOptionalParams no longer has parameter expand + - Interface FileSharesListNextOptionalParams no longer has parameter filter + - Interface FileSharesListNextOptionalParams no longer has parameter maxpagesize + - Interface QueueListNextOptionalParams no longer has parameter filter + - Interface QueueListNextOptionalParams no longer has parameter maxpagesize + + ## 18.1.0 (2022-11-24) **Features** diff --git a/sdk/storage/arm-storage/LICENSE b/sdk/storage/arm-storage/LICENSE index 5d1d36e0af80..3a1d9b6f24f7 100644 --- a/sdk/storage/arm-storage/LICENSE +++ b/sdk/storage/arm-storage/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2022 Microsoft +Copyright (c) 2023 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/storage/arm-storage/_meta.json b/sdk/storage/arm-storage/_meta.json index b14aceb18f6b..47644fd378e5 100644 --- a/sdk/storage/arm-storage/_meta.json +++ b/sdk/storage/arm-storage/_meta.json @@ -1,8 +1,8 @@ { - "commit": "c583b05741fadfdca116be3b9ccb1c4be8a73258", + "commit": "141ff1e194e86f0742c0a876081c24f75a7780a4", "readme": "specification/storage/resource-manager/readme.md", - "autorest_command": "autorest --version=3.8.4 --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\\storage\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.3.20221108.1 --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/storage/resource-manager/readme.md --use=@autorest/typescript@6.0.0-rc.5", "repository_url": "https://github.com/Azure/azure-rest-api-specs.git", - "release_tool": "@azure-tools/js-sdk-release-tools@2.4.2", - "use": "@autorest/typescript@6.0.0-rc.3.20221108.1" + "release_tool": "@azure-tools/js-sdk-release-tools@2.6.2", + "use": "@autorest/typescript@6.0.0-rc.5" } \ No newline at end of file diff --git a/sdk/storage/arm-storage/package.json b/sdk/storage/arm-storage/package.json index 503f1cc0997f..02dcce35a74e 100644 --- a/sdk/storage/arm-storage/package.json +++ b/sdk/storage/arm-storage/package.json @@ -3,7 +3,7 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for StorageManagementClient.", - "version": "18.1.1", + "version": "19.0.0", "engines": { "node": ">=14.0.0" }, @@ -29,9 +29,9 @@ "types": "./types/arm-storage.d.ts", "devDependencies": { "@microsoft/api-extractor": "^7.31.1", - "@rollup/plugin-commonjs": "^24.0.0", - "@rollup/plugin-json": "^6.0.0", - "@rollup/plugin-multi-entry": "^6.0.0", + "@rollup/plugin-commonjs": "^21.0.1", + "@rollup/plugin-json": "^4.1.0", + "@rollup/plugin-multi-entry": "^4.1.0", "@rollup/plugin-node-resolve": "^13.1.3", "mkdirp": "^1.0.4", "rollup": "^2.66.1", @@ -110,13 +110,5 @@ } ] }, - "autoPublish": true, - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-storage?view=azure-node-preview" - } -} + "autoPublish": true +} \ No newline at end of file diff --git a/sdk/storage/arm-storage/review/arm-storage.api.md b/sdk/storage/arm-storage/review/arm-storage.api.md index b2e86a0236f5..346851949a1e 100644 --- a/sdk/storage/arm-storage/review/arm-storage.api.md +++ b/sdk/storage/arm-storage/review/arm-storage.api.md @@ -209,9 +209,6 @@ export type BlobContainersLeaseResponse = LeaseContainerResponse; // @public export interface BlobContainersListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - include?: ListContainersInclude; - maxpagesize?: string; } // @public @@ -604,9 +601,6 @@ export type EncryptionScopesGetResponse = EncryptionScope; // @public export interface EncryptionScopesListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - include?: ListEncryptionScopesInclude; - maxpagesize?: number; } // @public @@ -837,9 +831,6 @@ export type FileSharesLeaseResponse = FileSharesLeaseHeaders & LeaseShareRespons // @public export interface FileSharesListNextOptionalParams extends coreClient.OperationOptions { - expand?: string; - filter?: string; - maxpagesize?: string; } // @public @@ -1983,8 +1974,6 @@ export type QueueGetResponse = StorageQueue; // @public export interface QueueListNextOptionalParams extends coreClient.OperationOptions { - filter?: string; - maxpagesize?: string; } // @public diff --git a/sdk/storage/arm-storage/src/models/index.ts b/sdk/storage/arm-storage/src/models/index.ts index a744442d9d61..899baf610928 100644 --- a/sdk/storage/arm-storage/src/models/index.ts +++ b/sdk/storage/arm-storage/src/models/index.ts @@ -3979,14 +3979,7 @@ export type EncryptionScopesListResponse = EncryptionScopeListResult; /** Optional parameters. */ export interface EncryptionScopesListNextOptionalParams - extends coreClient.OperationOptions { - /** Optional, specifies the maximum number of encryption scopes that will be included in the list response. */ - maxpagesize?: number; - /** Optional. When specified, only encryption scope names starting with the filter will be listed. */ - filter?: string; - /** Optional, when specified, will list encryption scopes with the specific state. Defaults to All */ - include?: ListEncryptionScopesInclude; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type EncryptionScopesListNextResponse = EncryptionScopeListResult; @@ -4137,14 +4130,7 @@ export interface BlobContainersObjectLevelWormOptionalParams /** Optional parameters. */ export interface BlobContainersListNextOptionalParams - extends coreClient.OperationOptions { - /** Optional. When specified, only container names starting with the filter will be listed. */ - filter?: string; - /** Optional. Specified maximum number of containers that can be included in the list. */ - maxpagesize?: string; - /** Optional, used to include the properties for soft deleted blob containers. */ - include?: ListContainersInclude; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type BlobContainersListNextResponse = ListContainerItems; @@ -4241,14 +4227,7 @@ export type FileSharesLeaseResponse = FileSharesLeaseHeaders & /** Optional parameters. */ export interface FileSharesListNextOptionalParams - extends coreClient.OperationOptions { - /** Optional. When specified, only share names starting with the filter will be listed. */ - filter?: string; - /** Optional. Specified maximum number of shares that can be included in the list. */ - maxpagesize?: string; - /** Optional, used to expand the properties within share's properties. Valid values are: deleted, snapshots. Should be passed as a string with delimiter ',' */ - expand?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type FileSharesListNextResponse = FileShareItems; @@ -4311,12 +4290,7 @@ export type QueueListResponse = ListQueueResource; /** Optional parameters. */ export interface QueueListNextOptionalParams - extends coreClient.OperationOptions { - /** Optional, When specified, only the queues with a name starting with the given filter will be listed. */ - filter?: string; - /** Optional, a maximum number of queues that should be included in a list queue response */ - maxpagesize?: string; -} + extends coreClient.OperationOptions {} /** Contains response data for the listNext operation. */ export type QueueListNextResponse = ListQueueResource; diff --git a/sdk/storage/arm-storage/src/operations/blobContainers.ts b/sdk/storage/arm-storage/src/operations/blobContainers.ts index e8ef1dfc145c..1d1702eab55a 100644 --- a/sdk/storage/arm-storage/src/operations/blobContainers.ts +++ b/sdk/storage/arm-storage/src/operations/blobContainers.ts @@ -952,12 +952,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ListContainerItems } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.maxpagesize1, - Parameters.include1 - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/deletedAccounts.ts b/sdk/storage/arm-storage/src/operations/deletedAccounts.ts index cc672064ec95..1d39e7c8067e 100644 --- a/sdk/storage/arm-storage/src/operations/deletedAccounts.ts +++ b/sdk/storage/arm-storage/src/operations/deletedAccounts.ts @@ -185,7 +185,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.ErrorResponse } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/encryptionScopes.ts b/sdk/storage/arm-storage/src/operations/encryptionScopes.ts index 8d9740beba69..5e7089a8aff0 100644 --- a/sdk/storage/arm-storage/src/operations/encryptionScopes.ts +++ b/sdk/storage/arm-storage/src/operations/encryptionScopes.ts @@ -366,12 +366,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.EncryptionScopeListResult } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.maxpagesize, - Parameters.filter, - Parameters.include - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/fileShares.ts b/sdk/storage/arm-storage/src/operations/fileShares.ts index 7229805d8865..8b9f9fe107dc 100644 --- a/sdk/storage/arm-storage/src/operations/fileShares.ts +++ b/sdk/storage/arm-storage/src/operations/fileShares.ts @@ -513,12 +513,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.CloudError } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.maxpagesize1, - Parameters.expand2 - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/queue.ts b/sdk/storage/arm-storage/src/operations/queue.ts index ca40bc8a38e3..aca8ed2f4613 100644 --- a/sdk/storage/arm-storage/src/operations/queue.ts +++ b/sdk/storage/arm-storage/src/operations/queue.ts @@ -397,11 +397,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.CloudError } }, - queryParameters: [ - Parameters.apiVersion, - Parameters.filter, - Parameters.maxpagesize1 - ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/storageAccounts.ts b/sdk/storage/arm-storage/src/operations/storageAccounts.ts index d475e2741da1..d0c45f520713 100644 --- a/sdk/storage/arm-storage/src/operations/storageAccounts.ts +++ b/sdk/storage/arm-storage/src/operations/storageAccounts.ts @@ -512,7 +512,7 @@ export class StorageAccountsImpl implements StorageAccounts { * primary and secondary endpoints are available. The primary use case of a Planned Failover is * disaster recovery testing drills. This type of failover is invoked by setting FailoverType parameter * to 'Planned'. Learn more about the failover options here- - * https://learn.microsoft.com/azure/storage/common/storage-disaster-recovery-guidance + * https://learn.microsoft.com/en-us/azure/storage/common/storage-disaster-recovery-guidance * @param resourceGroupName The name of the resource group within the user's subscription. The name is * case insensitive. * @param accountName The name of the storage account within the specified resource group. Storage @@ -588,7 +588,7 @@ export class StorageAccountsImpl implements StorageAccounts { * primary and secondary endpoints are available. The primary use case of a Planned Failover is * disaster recovery testing drills. This type of failover is invoked by setting FailoverType parameter * to 'Planned'. Learn more about the failover options here- - * https://learn.microsoft.com/azure/storage/common/storage-disaster-recovery-guidance + * https://learn.microsoft.com/en-us/azure/storage/common/storage-disaster-recovery-guidance * @param resourceGroupName The name of the resource group within the user's subscription. The name is * case insensitive. * @param accountName The name of the storage account within the specified resource group. Storage @@ -1279,7 +1279,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.StorageAccountListResult } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, @@ -1296,7 +1295,6 @@ const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.StorageAccountListResult } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operations/tableOperations.ts b/sdk/storage/arm-storage/src/operations/tableOperations.ts index 25b857d927af..082115c6ac57 100644 --- a/sdk/storage/arm-storage/src/operations/tableOperations.ts +++ b/sdk/storage/arm-storage/src/operations/tableOperations.ts @@ -388,7 +388,6 @@ const listNextOperationSpec: coreClient.OperationSpec = { bodyMapper: Mappers.CloudError } }, - queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, diff --git a/sdk/storage/arm-storage/src/operationsInterfaces/storageAccounts.ts b/sdk/storage/arm-storage/src/operationsInterfaces/storageAccounts.ts index 60effd45b3ae..644e4d7a669d 100644 --- a/sdk/storage/arm-storage/src/operationsInterfaces/storageAccounts.ts +++ b/sdk/storage/arm-storage/src/operationsInterfaces/storageAccounts.ts @@ -245,7 +245,7 @@ export interface StorageAccounts { * primary and secondary endpoints are available. The primary use case of a Planned Failover is * disaster recovery testing drills. This type of failover is invoked by setting FailoverType parameter * to 'Planned'. Learn more about the failover options here- - * https://learn.microsoft.com/azure/storage/common/storage-disaster-recovery-guidanceS + * https://learn.microsoft.com/en-us/azure/storage/common/storage-disaster-recovery-guidance * @param resourceGroupName The name of the resource group within the user's subscription. The name is * case insensitive. * @param accountName The name of the storage account within the specified resource group. Storage @@ -268,7 +268,7 @@ export interface StorageAccounts { * primary and secondary endpoints are available. The primary use case of a Planned Failover is * disaster recovery testing drills. This type of failover is invoked by setting FailoverType parameter * to 'Planned'. Learn more about the failover options here- - * https://learn.microsoft.com/azure/storage/common/storage-disaster-recovery-guidance + * https://learn.microsoft.com/en-us/azure/storage/common/storage-disaster-recovery-guidance * @param resourceGroupName The name of the resource group within the user's subscription. The name is * case insensitive. * @param accountName The name of the storage account within the specified resource group. Storage diff --git a/sdk/storage/arm-storage/src/pagingHelper.ts b/sdk/storage/arm-storage/src/pagingHelper.ts index d85fc13bce1e..269a2b9814b5 100644 --- a/sdk/storage/arm-storage/src/pagingHelper.ts +++ b/sdk/storage/arm-storage/src/pagingHelper.ts @@ -13,11 +13,11 @@ export interface PageInfo { const pageMap = new WeakMap(); /** - * Given a result page from a pageable operation, returns a - * continuation token that can be used to begin paging from + * Given the last `.value` produced by the `byPage` iterator, + * returns a continuation token that can be used to begin paging from * that point later. - * @param page A result object from calling .byPage() on a paged operation. - * @returns The continuation token that can be passed into byPage(). + * @param page An object from accessing `value` on the IteratorResult from a `byPage` iterator. + * @returns The continuation token that can be passed into byPage() during future calls. */ export function getContinuationToken(page: unknown): string | undefined { if (typeof page !== "object" || page === null) { diff --git a/sdk/storage/arm-storage/src/storageManagementClient.ts b/sdk/storage/arm-storage/src/storageManagementClient.ts index 68fd46e81f7c..89996cfdbcfd 100644 --- a/sdk/storage/arm-storage/src/storageManagementClient.ts +++ b/sdk/storage/arm-storage/src/storageManagementClient.ts @@ -92,7 +92,7 @@ export class StorageManagementClient extends coreClient.ServiceClient { credential: credentials }; - const packageDetails = `azsdk-js-arm-storage/18.1.1`; + const packageDetails = `azsdk-js-arm-storage/19.0.0`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` diff --git a/sdk/storage/arm-storage/test/sampleTest.ts b/sdk/storage/arm-storage/test/sampleTest.ts new file mode 100644 index 000000000000..25aeb3ebcc36 --- /dev/null +++ b/sdk/storage/arm-storage/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/storage/arm-storage/tsconfig.json b/sdk/storage/arm-storage/tsconfig.json index 2792c048bc1f..3e6ae96443f3 100644 --- a/sdk/storage/arm-storage/tsconfig.json +++ b/sdk/storage/arm-storage/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-storage": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"