From 16fa0ce4a74e73a9a92021de9c7f408838633afa Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Wed, 25 Sep 2024 15:36:04 +0000 Subject: [PATCH] CodeGen from PR 30569 in Azure/azure-rest-api-specs Merge 3e4cf8250734244ac5f84b80452001c45bf25ebd into befbed40f82c444b19d6aaf5d4ac6bdf50960d54 --- common/config/rush/pnpm-lock.yaml | 42 +- .../arm-containerinstance/CHANGELOG.md | 23 +- .../arm-containerinstance/LICENSE | 2 +- .../arm-containerinstance/README.md | 2 +- .../arm-containerinstance/_meta.json | 8 +- .../arm-containerinstance/package.json | 38 +- .../review/arm-containerinstance.api.md | 14 + .../src/containerInstanceManagementClient.ts | 37 +- .../arm-containerinstance/src/lroImpl.ts | 6 +- .../arm-containerinstance/src/models/index.ts | 50 +- .../src/models/mappers.ts | 1482 +++++++++-------- .../src/models/parameters.ts | 96 +- .../src/operations/containerGroups.ts | 359 ++-- .../src/operations/containers.ts | 57 +- .../src/operations/location.ts | 113 +- .../src/operations/operations.ts | 32 +- .../subnetServiceAssociationLink.ts | 45 +- .../operationsInterfaces/containerGroups.ts | 30 +- .../src/operationsInterfaces/containers.ts | 8 +- .../src/operationsInterfaces/location.ts | 8 +- .../src/operationsInterfaces/operations.ts | 2 +- .../subnetServiceAssociationLink.ts | 4 +- .../arm-containerinstance/src/pagingHelper.ts | 2 +- .../arm-containerinstance/test/sampleTest.ts | 43 + .../arm-containerinstance/tsconfig.json | 10 +- 25 files changed, 1332 insertions(+), 1181 deletions(-) create mode 100644 sdk/containerinstance/arm-containerinstance/test/sampleTest.ts diff --git a/common/config/rush/pnpm-lock.yaml b/common/config/rush/pnpm-lock.yaml index a8e70ed80234..a218553ec97b 100644 --- a/common/config/rush/pnpm-lock.yaml +++ b/common/config/rush/pnpm-lock.yaml @@ -10634,6 +10634,37 @@ packages: yn: 3.1.1 dev: false + /ts-node@10.9.2(@types/node@18.19.50)(typescript@5.5.4): + resolution: {integrity: sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==} + hasBin: true + peerDependencies: + '@swc/core': '>=1.2.50' + '@swc/wasm': '>=1.2.50' + '@types/node': '*' + typescript: '>=2.7' + peerDependenciesMeta: + '@swc/core': + optional: true + '@swc/wasm': + optional: true + dependencies: + '@cspotcode/source-map-support': 0.8.1 + '@tsconfig/node10': 1.0.11 + '@tsconfig/node12': 1.0.11 + '@tsconfig/node14': 1.0.3 + '@tsconfig/node16': 1.0.4 + '@types/node': 18.19.50 + acorn: 8.12.1 + acorn-walk: 8.3.4 + arg: 4.1.3 + create-require: 1.1.1 + diff: 4.0.2 + make-error: 1.3.6 + typescript: 5.5.4 + v8-compile-cache-lib: 3.0.1 + yn: 3.1.1 + dev: false + /ts-node@10.9.2(@types/node@18.19.50)(typescript@5.6.2): resolution: {integrity: sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==} hasBin: true @@ -13845,7 +13876,7 @@ packages: dev: false file:projects/arm-containerinstance.tgz: - resolution: {integrity: sha512-SaSrVVISz1ZjPeO8jG5TiqvC+1hhhHv4PtTMZfzgDCxcfKp5zRXmcNRQ7CcRIjk4JPbWPLMwXELm78E9ykeRPw==, tarball: file:projects/arm-containerinstance.tgz} + resolution: {integrity: sha512-8a2fLFTxLQ0JMKVJzm8KpRI5LMacnO8+MDFHc7qv9Ig+Ji1oOd1vGYTeuOJNI83Ru14weGLDgXUpSB2HYbyVoQ==, tarball: file:projects/arm-containerinstance.tgz} name: '@rush-temp/arm-containerinstance' version: 0.0.0 dependencies: @@ -13864,9 +13895,10 @@ packages: mkdirp: 3.0.1 mocha: 10.7.3 rimraf: 5.0.10 - ts-node: 10.9.2(@types/node@18.19.50)(typescript@5.6.2) + ts-node: 10.9.2(@types/node@18.19.50)(typescript@5.5.4) tslib: 2.7.0 - typescript: 5.6.2 + tsx: 4.19.1 + typescript: 5.5.4 uglify-js: 3.19.3 transitivePeerDependencies: - '@swc/core' @@ -20809,7 +20841,7 @@ packages: dev: false file:projects/core-lro.tgz: - resolution: {integrity: sha512-47/kkb4O77Sd/sbaufL6N0x8/ixayXB4IO+FBOY2FdXpSgHpnHufTo5p6JTmN5N+Hqamg8VXopI+qFVc5wigzA==, tarball: file:projects/core-lro.tgz} + resolution: {integrity: sha512-4GV4wbgJYAOlDJ4oWpeMIeanXGTk+lxzNuO+9eSyZtM7qkGSSXjkxVQyb5xVLPRn5LZP6UNqe4OFuQdZ116fDw==, tarball: file:projects/core-lro.tgz} name: '@rush-temp/core-lro' version: 0.0.0 dependencies: @@ -20925,7 +20957,7 @@ packages: dev: false file:projects/core-sse.tgz: - resolution: {integrity: sha512-zx3dvzydyjacBNo/nrZ7pDWeAPAhugBwnqhqoffkFWQ3VjQQxfcDMYqaXj0Po7EdGJYOUrsCV1giVBc3e3SYkg==, tarball: file:projects/core-sse.tgz} + resolution: {integrity: sha512-N55V/xjWTICcNsfiO74ElWoKTlCVrduN/Gba2rGL7gYTcgrqu3WL1XCk85fVRBi7gRM4ePVXtS20MaTRSOHgEg==, tarball: file:projects/core-sse.tgz} name: '@rush-temp/core-sse' version: 0.0.0 dependencies: diff --git a/sdk/containerinstance/arm-containerinstance/CHANGELOG.md b/sdk/containerinstance/arm-containerinstance/CHANGELOG.md index 40b0e39ec592..1120199553fa 100644 --- a/sdk/containerinstance/arm-containerinstance/CHANGELOG.md +++ b/sdk/containerinstance/arm-containerinstance/CHANGELOG.md @@ -1,15 +1,18 @@ # Release History - -## 9.1.1 (Unreleased) - + +## 9.2.0-beta.1 (2024-09-25) +Compared with version 9.1.0 + ### Features Added -### Breaking Changes - -### Bugs Fixed - -### Other Changes - + - Added Interface SecretReference + - Interface AzureFileVolume has a new optional parameter storageAccountKeyReference + - Interface ContainerGroupProperties has a new optional parameter secretReferences + - Interface EnvironmentVariable has a new optional parameter secureValueReference + - Interface ImageRegistryCredential has a new optional parameter passwordReference + - Interface Volume has a new optional parameter secretReference + + ## 9.1.0 (2023-04-24) ### Features Added @@ -89,4 +92,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka. To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide). -To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ). +To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart). diff --git a/sdk/containerinstance/arm-containerinstance/LICENSE b/sdk/containerinstance/arm-containerinstance/LICENSE index 3a1d9b6f24f7..7d5934740965 100644 --- a/sdk/containerinstance/arm-containerinstance/LICENSE +++ b/sdk/containerinstance/arm-containerinstance/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2023 Microsoft +Copyright (c) 2024 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/containerinstance/arm-containerinstance/README.md b/sdk/containerinstance/arm-containerinstance/README.md index e28b289cba0d..8b91c74654a4 100644 --- a/sdk/containerinstance/arm-containerinstance/README.md +++ b/sdk/containerinstance/arm-containerinstance/README.md @@ -6,7 +6,7 @@ This package contains an isomorphic SDK (runs both in Node.js and in browsers) f [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerinstance/arm-containerinstance) | [Package (NPM)](https://www.npmjs.com/package/@azure/arm-containerinstance) | -[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-containerinstance) | +[API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-containerinstance?view=azure-node-preview) | [Samples](https://github.com/Azure-Samples/azure-samples-js-management) ## Getting started diff --git a/sdk/containerinstance/arm-containerinstance/_meta.json b/sdk/containerinstance/arm-containerinstance/_meta.json index 18b8bd7a536c..f6a810c5ee73 100644 --- a/sdk/containerinstance/arm-containerinstance/_meta.json +++ b/sdk/containerinstance/arm-containerinstance/_meta.json @@ -1,8 +1,8 @@ { - "commit": "7a65f22cf67826187f75981e914c7e679039257b", + "commit": "cec8377c861c3e6dfdcd634fdfcdc45b451919d0", "readme": "specification/containerinstance/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\\containerinstance\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-rc.10 --generate-sample=true", + "autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/containerinstance/resource-manager/readme.md --use=@autorest/typescript@^6.0.12", "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.10" + "release_tool": "@azure-tools/js-sdk-release-tools@2.7.14", + "use": "@autorest/typescript@^6.0.12" } \ No newline at end of file diff --git a/sdk/containerinstance/arm-containerinstance/package.json b/sdk/containerinstance/arm-containerinstance/package.json index f4873f394db2..9f1ba8f7624b 100644 --- a/sdk/containerinstance/arm-containerinstance/package.json +++ b/sdk/containerinstance/arm-containerinstance/package.json @@ -3,17 +3,17 @@ "sdk-type": "mgmt", "author": "Microsoft Corporation", "description": "A generated SDK for ContainerInstanceManagementClient.", - "version": "9.1.1", + "version": "9.2.0-beta.1", "engines": { "node": ">=18.0.0" }, "dependencies": { - "@azure/core-lro": "^2.5.0", - "@azure/abort-controller": "^1.0.0", + "@azure/core-lro": "^2.5.4", + "@azure/abort-controller": "^2.1.2", "@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-auth": "^1.6.0", + "@azure/core-rest-pipeline": "^1.14.0", "tslib": "^2.2.0" }, "keywords": [ @@ -30,21 +30,22 @@ "devDependencies": { "@microsoft/api-extractor": "^7.31.1", "mkdirp": "^3.0.1", - "typescript": "~5.6.2", + "typescript": "~5.5.3", "uglify-js": "^3.4.9", - "rimraf": "^5.0.5", + "rimraf": "^5.0.0", "dotenv": "^16.0.0", - "@azure/identity": "^4.0.1", + "@azure/dev-tool": "^1.0.0", + "@azure/identity": "^4.2.1", "@azure-tools/test-recorder": "^3.0.0", - "@azure-tools/test-credential": "^1.0.0", + "@azure-tools/test-credential": "^1.1.0", "mocha": "^10.0.0", + "@types/mocha": "^10.0.0", + "tsx": "^4.7.1", "@types/chai": "^4.2.8", "chai": "^4.2.0", "cross-env": "^7.0.2", "@types/node": "^18.0.0", - "@azure/dev-tool": "^1.0.0", - "ts-node": "^10.0.0", - "@types/mocha": "^10.0.0" + "ts-node": "^10.0.0" }, "repository": { "type": "git", @@ -77,7 +78,6 @@ "pack": "npm pack 2>&1", "extract-api": "dev-tool run extract-api", "lint": "echo skipped", - "audit": "echo skipped", "clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log", "build:node": "echo skipped", "build:browser": "echo skipped", @@ -106,13 +106,5 @@ ] }, "autoPublish": true, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerinstance/arm-containerinstance", - "//sampleConfiguration": { - "productName": "", - "productSlugs": [ - "azure" - ], - "disableDocsMs": true, - "apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-containerinstance?view=azure-node-preview" - } -} + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerinstance/arm-containerinstance" +} \ No newline at end of file diff --git a/sdk/containerinstance/arm-containerinstance/review/arm-containerinstance.api.md b/sdk/containerinstance/arm-containerinstance/review/arm-containerinstance.api.md index c0a22659618c..ca27644fef61 100644 --- a/sdk/containerinstance/arm-containerinstance/review/arm-containerinstance.api.md +++ b/sdk/containerinstance/arm-containerinstance/review/arm-containerinstance.api.md @@ -15,6 +15,7 @@ export interface AzureFileVolume { readOnly?: boolean; shareName: string; storageAccountKey?: string; + storageAccountKeyReference?: string; storageAccountName: string; } @@ -166,6 +167,7 @@ export interface ContainerGroupProperties { priority?: ContainerGroupPriority; readonly provisioningState?: string; restartPolicy?: ContainerGroupRestartPolicy; + secretReferences?: SecretReference[]; sku?: ContainerGroupSku; subnetIds?: ContainerGroupSubnetId[]; volumes?: Volume[]; @@ -429,6 +431,7 @@ export interface EncryptionProperties { export interface EnvironmentVariable { name: string; secureValue?: string; + secureValueReference?: string; value?: string; } @@ -473,6 +476,7 @@ export interface ImageRegistryCredential { identity?: string; identityUrl?: string; password?: string; + passwordReference?: string; server: string; username?: string; } @@ -734,6 +738,13 @@ export interface ResourceRequirements { // @public export type Scheme = string; +// @public +export interface SecretReference { + identity: string; + name: string; + secretReferenceUri: string; +} + // @public export interface SecurityContextCapabilitiesDefinition { add?: string[]; @@ -797,6 +808,9 @@ export interface Volume { secret?: { [propertyName: string]: string; }; + secretReference?: { + [propertyName: string]: string; + }; } // @public diff --git a/sdk/containerinstance/arm-containerinstance/src/containerInstanceManagementClient.ts b/sdk/containerinstance/arm-containerinstance/src/containerInstanceManagementClient.ts index 145566f2f459..aa0b76dfbbd3 100644 --- a/sdk/containerinstance/arm-containerinstance/src/containerInstanceManagementClient.ts +++ b/sdk/containerinstance/arm-containerinstance/src/containerInstanceManagementClient.ts @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline"; import { PipelineRequest, PipelineResponse, - SendRequest + SendRequest, } from "@azure/core-rest-pipeline"; import * as coreAuth from "@azure/core-auth"; import { @@ -19,14 +19,14 @@ import { OperationsImpl, LocationImpl, ContainersImpl, - SubnetServiceAssociationLinkImpl + SubnetServiceAssociationLinkImpl, } from "./operations"; import { ContainerGroups, Operations, Location, Containers, - SubnetServiceAssociationLink + SubnetServiceAssociationLink, } from "./operationsInterfaces"; import { ContainerInstanceManagementClientOptionalParams } from "./models"; @@ -45,7 +45,7 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient constructor( credentials: coreAuth.TokenCredential, subscriptionId: string, - options?: ContainerInstanceManagementClientOptionalParams + options?: ContainerInstanceManagementClientOptionalParams, ) { if (credentials === undefined) { throw new Error("'credentials' cannot be null"); @@ -60,10 +60,10 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient } const defaults: ContainerInstanceManagementClientOptionalParams = { requestContentType: "application/json; charset=utf-8", - credential: credentials + credential: credentials, }; - const packageDetails = `azsdk-js-arm-containerinstance/9.1.1`; + const packageDetails = `azsdk-js-arm-containerinstance/9.2.0-beta.1`; const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` @@ -73,20 +73,21 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient ...defaults, ...options, userAgentOptions: { - userAgentPrefix + userAgentPrefix, }, endpoint: - options.endpoint ?? options.baseUri ?? "https://management.azure.com" + options.endpoint ?? options.baseUri ?? "https://management.azure.com", }; super(optionsWithDefaults); let bearerTokenAuthenticationPolicyFound: boolean = false; if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) { - const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies(); + const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = + options.pipeline.getOrderedPolicies(); bearerTokenAuthenticationPolicyFound = pipelinePolicies.some( (pipelinePolicy) => pipelinePolicy.name === - coreRestPipeline.bearerTokenAuthenticationPolicyName + coreRestPipeline.bearerTokenAuthenticationPolicyName, ); } if ( @@ -96,7 +97,7 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient !bearerTokenAuthenticationPolicyFound ) { this.pipeline.removePolicy({ - name: coreRestPipeline.bearerTokenAuthenticationPolicyName + name: coreRestPipeline.bearerTokenAuthenticationPolicyName, }); this.pipeline.addPolicy( coreRestPipeline.bearerTokenAuthenticationPolicy({ @@ -106,9 +107,9 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient `${optionsWithDefaults.endpoint}/.default`, challengeCallbacks: { authorizeRequestOnChallenge: - coreClient.authorizeRequestOnClaimChallenge - } - }) + coreClient.authorizeRequestOnClaimChallenge, + }, + }), ); } // Parameter assignments @@ -116,13 +117,13 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient // Assigning values to Constant parameters this.$host = options.$host || "https://management.azure.com"; - this.apiVersion = options.apiVersion || "2023-05-01"; + this.apiVersion = options.apiVersion || "2024-10-01-preview"; this.containerGroups = new ContainerGroupsImpl(this); this.operations = new OperationsImpl(this); this.location = new LocationImpl(this); this.containers = new ContainersImpl(this); this.subnetServiceAssociationLink = new SubnetServiceAssociationLinkImpl( - this + this, ); this.addCustomApiVersionPolicy(options.apiVersion); } @@ -136,7 +137,7 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient name: "CustomApiVersionPolicy", async sendRequest( request: PipelineRequest, - next: SendRequest + next: SendRequest, ): Promise { const param = request.url.split("?"); if (param.length > 1) { @@ -150,7 +151,7 @@ export class ContainerInstanceManagementClient extends coreClient.ServiceClient request.url = param[0] + "?" + newParams.join("&"); } return next(request); - } + }, }; this.pipeline.addPolicy(apiVersionPolicy); } diff --git a/sdk/containerinstance/arm-containerinstance/src/lroImpl.ts b/sdk/containerinstance/arm-containerinstance/src/lroImpl.ts index 52f6eaacfb83..5f88efab981b 100644 --- a/sdk/containerinstance/arm-containerinstance/src/lroImpl.ts +++ b/sdk/containerinstance/arm-containerinstance/src/lroImpl.ts @@ -28,15 +28,15 @@ export function createLroSpec(inputs: { sendInitialRequest: () => sendOperationFn(args, spec), sendPollRequest: ( path: string, - options?: { abortSignal?: AbortSignalLike } + options?: { abortSignal?: AbortSignalLike }, ) => { const { requestBody, ...restSpec } = spec; return sendOperationFn(args, { ...restSpec, httpMethod: "GET", path, - abortSignal: options?.abortSignal + abortSignal: options?.abortSignal, }); - } + }, }; } diff --git a/sdk/containerinstance/arm-containerinstance/src/models/index.ts b/sdk/containerinstance/arm-containerinstance/src/models/index.ts index a82edd98b8b1..e1e4d9b0c259 100644 --- a/sdk/containerinstance/arm-containerinstance/src/models/index.ts +++ b/sdk/containerinstance/arm-containerinstance/src/models/index.ts @@ -50,6 +50,8 @@ export interface ContainerGroupProperties { * NOTE: This property will not be serialized. It can only be populated by the server. */ readonly provisioningState?: string; + /** The secret references that will be referenced within the container group. */ + secretReferences?: SecretReference[]; /** The containers within the container group. */ containers: Container[]; /** The image registry credentials by which the container group is created from. */ @@ -125,6 +127,16 @@ export interface UserAssignedIdentities { readonly clientId?: string; } +/** A secret reference */ +export interface SecretReference { + /** The identifier of the secret reference */ + name: string; + /** The ARM resource id of the managed identity that has access to the secret in the key vault */ + identity: string; + /** The URI to the secret in key vault */ + secretReferenceUri: string; +} + /** A container instance. */ export interface Container { /** The user-provided name of the container instance. */ @@ -170,6 +182,8 @@ export interface EnvironmentVariable { value?: string; /** The value of the secure environment variable. */ secureValue?: string; + /** The reference of the secure environment variable. */ + secureValueReference?: string; } /** The instance view of the container instance. Only valid in response. */ @@ -381,6 +395,8 @@ export interface ImageRegistryCredential { username?: string; /** The password for the private registry. */ password?: string; + /** The reference for the private registry password. */ + passwordReference?: string; /** The identity for the private registry. */ identity?: string; /** The identity URL for the private registry. */ @@ -424,6 +440,8 @@ export interface Volume { emptyDir?: Record; /** The secret volume. */ secret?: { [propertyName: string]: string }; + /** The secret reference volume. */ + secretReference?: { [propertyName: string]: string }; /** The git repo volume. */ gitRepo?: GitRepoVolume; } @@ -438,6 +456,8 @@ export interface AzureFileVolume { storageAccountName: string; /** The storage account access key used to access the Azure File share. */ storageAccountKey?: string; + /** The reference to the storage account access key used to access the Azure File share. */ + storageAccountKeyReference?: string; } /** Represents a volume that is populated with the contents of a git repository */ @@ -804,7 +824,7 @@ export enum KnownContainerNetworkProtocol { /** TCP */ TCP = "TCP", /** UDP */ - UDP = "UDP" + UDP = "UDP", } /** @@ -824,7 +844,7 @@ export enum KnownGpuSku { /** P100 */ P100 = "P100", /** V100 */ - V100 = "V100" + V100 = "V100", } /** @@ -843,7 +863,7 @@ export enum KnownScheme { /** Http */ Http = "http", /** Https */ - Https = "https" + Https = "https", } /** @@ -863,7 +883,7 @@ export enum KnownContainerGroupRestartPolicy { /** OnFailure */ OnFailure = "OnFailure", /** Never */ - Never = "Never" + Never = "Never", } /** @@ -882,7 +902,7 @@ export enum KnownContainerGroupNetworkProtocol { /** TCP */ TCP = "TCP", /** UDP */ - UDP = "UDP" + UDP = "UDP", } /** @@ -900,7 +920,7 @@ export enum KnownContainerGroupIpAddressType { /** Public */ Public = "Public", /** Private */ - Private = "Private" + Private = "Private", } /** @@ -924,7 +944,7 @@ export enum KnownDnsNameLabelReusePolicy { /** ResourceGroupReuse */ ResourceGroupReuse = "ResourceGroupReuse", /** Noreuse */ - Noreuse = "Noreuse" + Noreuse = "Noreuse", } /** @@ -945,7 +965,7 @@ export enum KnownOperatingSystemTypes { /** Windows */ Windows = "Windows", /** Linux */ - Linux = "Linux" + Linux = "Linux", } /** @@ -963,7 +983,7 @@ export enum KnownLogAnalyticsLogType { /** ContainerInsights */ ContainerInsights = "ContainerInsights", /** ContainerInstanceLogs */ - ContainerInstanceLogs = "ContainerInstanceLogs" + ContainerInstanceLogs = "ContainerInstanceLogs", } /** @@ -983,7 +1003,7 @@ export enum KnownContainerGroupSku { /** Dedicated */ Dedicated = "Dedicated", /** Confidential */ - Confidential = "Confidential" + Confidential = "Confidential", } /** @@ -1002,7 +1022,7 @@ export enum KnownContainerGroupPriority { /** Regular */ Regular = "Regular", /** Spot */ - Spot = "Spot" + Spot = "Spot", } /** @@ -1020,7 +1040,7 @@ export enum KnownContainerInstanceOperationsOrigin { /** User */ User = "User", /** System */ - System = "System" + System = "System", } /** @@ -1051,7 +1071,8 @@ export interface ContainerGroupsListByResourceGroupOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listByResourceGroup operation. */ -export type ContainerGroupsListByResourceGroupResponse = ContainerGroupListResult; +export type ContainerGroupsListByResourceGroupResponse = + ContainerGroupListResult; /** Optional parameters. */ export interface ContainerGroupsGetOptionalParams @@ -1135,7 +1156,8 @@ export interface ContainerGroupsListByResourceGroupNextOptionalParams extends coreClient.OperationOptions {} /** Contains response data for the listByResourceGroupNext operation. */ -export type ContainerGroupsListByResourceGroupNextResponse = ContainerGroupListResult; +export type ContainerGroupsListByResourceGroupNextResponse = + ContainerGroupListResult; /** Optional parameters. */ export interface OperationsListOptionalParams diff --git a/sdk/containerinstance/arm-containerinstance/src/models/mappers.ts b/sdk/containerinstance/arm-containerinstance/src/models/mappers.ts index b4b482c66ac1..931f19466dd4 100644 --- a/sdk/containerinstance/arm-containerinstance/src/models/mappers.ts +++ b/sdk/containerinstance/arm-containerinstance/src/models/mappers.ts @@ -20,19 +20,19 @@ export const ContainerGroupListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ContainerGroup" - } - } - } + className: "ContainerGroup", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Resource: coreClient.CompositeMapper = { @@ -44,35 +44,35 @@ export const Resource: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, location: { serializedName: "location", type: { - name: "String" - } + name: "String", + }, }, tags: { serializedName: "tags", type: { name: "Dictionary", - value: { type: { name: "String" } } - } + value: { type: { name: "String" } }, + }, }, zones: { serializedName: "zones", @@ -80,13 +80,13 @@ export const Resource: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const ContainerGroupProperties: coreClient.CompositeMapper = { @@ -98,15 +98,27 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { serializedName: "identity", type: { name: "Composite", - className: "ContainerGroupIdentity" - } + className: "ContainerGroupIdentity", + }, }, provisioningState: { serializedName: "properties.provisioningState", readOnly: true, type: { - name: "String" - } + name: "String", + }, + }, + secretReferences: { + serializedName: "properties.secretReferences", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SecretReference", + }, + }, + }, }, containers: { serializedName: "properties.containers", @@ -116,10 +128,10 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Container" - } - } - } + className: "Container", + }, + }, + }, }, imageRegistryCredentials: { serializedName: "properties.imageRegistryCredentials", @@ -128,30 +140,30 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ImageRegistryCredential" - } - } - } + className: "ImageRegistryCredential", + }, + }, + }, }, restartPolicy: { serializedName: "properties.restartPolicy", type: { - name: "String" - } + name: "String", + }, }, ipAddress: { serializedName: "properties.ipAddress", type: { name: "Composite", - className: "IpAddress" - } + className: "IpAddress", + }, }, osType: { serializedName: "properties.osType", required: true, type: { - name: "String" - } + name: "String", + }, }, volumes: { serializedName: "properties.volumes", @@ -160,24 +172,24 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Volume" - } - } - } + className: "Volume", + }, + }, + }, }, instanceView: { serializedName: "properties.instanceView", type: { name: "Composite", - className: "ContainerGroupPropertiesInstanceView" - } + className: "ContainerGroupPropertiesInstanceView", + }, }, diagnostics: { serializedName: "properties.diagnostics", type: { name: "Composite", - className: "ContainerGroupDiagnostics" - } + className: "ContainerGroupDiagnostics", + }, }, subnetIds: { serializedName: "properties.subnetIds", @@ -186,30 +198,30 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ContainerGroupSubnetId" - } - } - } + className: "ContainerGroupSubnetId", + }, + }, + }, }, dnsConfig: { serializedName: "properties.dnsConfig", type: { name: "Composite", - className: "DnsConfiguration" - } + className: "DnsConfiguration", + }, }, sku: { serializedName: "properties.sku", type: { - name: "String" - } + name: "String", + }, }, encryptionProperties: { serializedName: "properties.encryptionProperties", type: { name: "Composite", - className: "EncryptionProperties" - } + className: "EncryptionProperties", + }, }, initContainers: { serializedName: "properties.initContainers", @@ -218,10 +230,10 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "InitContainerDefinition" - } - } - } + className: "InitContainerDefinition", + }, + }, + }, }, extensions: { serializedName: "properties.extensions", @@ -230,26 +242,26 @@ export const ContainerGroupProperties: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "DeploymentExtensionSpec" - } - } - } + className: "DeploymentExtensionSpec", + }, + }, + }, }, confidentialComputeProperties: { serializedName: "properties.confidentialComputeProperties", type: { name: "Composite", - className: "ConfidentialComputeProperties" - } + className: "ConfidentialComputeProperties", + }, }, priority: { serializedName: "properties.priority", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ContainerGroupIdentity: coreClient.CompositeMapper = { @@ -261,15 +273,15 @@ export const ContainerGroupIdentity: coreClient.CompositeMapper = { serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, tenantId: { serializedName: "tenantId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", @@ -279,21 +291,21 @@ export const ContainerGroupIdentity: coreClient.CompositeMapper = { "SystemAssigned", "UserAssigned", "SystemAssigned, UserAssigned", - "None" - ] - } + "None", + ], + }, }, userAssignedIdentities: { serializedName: "userAssignedIdentities", type: { name: "Dictionary", value: { - type: { name: "Composite", className: "UserAssignedIdentities" } - } - } - } - } - } + type: { name: "Composite", className: "UserAssignedIdentities" }, + }, + }, + }, + }, + }, }; export const UserAssignedIdentities: coreClient.CompositeMapper = { @@ -305,18 +317,48 @@ export const UserAssignedIdentities: coreClient.CompositeMapper = { serializedName: "principalId", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, clientId: { serializedName: "clientId", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, +}; + +export const SecretReference: coreClient.CompositeMapper = { + type: { + name: "Composite", + className: "SecretReference", + modelProperties: { + name: { + serializedName: "name", + required: true, + type: { + name: "String", + }, + }, + identity: { + serializedName: "identity", + required: true, + type: { + name: "String", + }, + }, + secretReferenceUri: { + serializedName: "secretReferenceUri", + required: true, + type: { + name: "String", + }, + }, + }, + }, }; export const Container: coreClient.CompositeMapper = { @@ -328,15 +370,15 @@ export const Container: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, image: { serializedName: "properties.image", required: true, type: { - name: "String" - } + name: "String", + }, }, command: { serializedName: "properties.command", @@ -344,10 +386,10 @@ export const Container: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, ports: { serializedName: "properties.ports", @@ -356,10 +398,10 @@ export const Container: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "ContainerPort" - } - } - } + className: "ContainerPort", + }, + }, + }, }, environmentVariables: { serializedName: "properties.environmentVariables", @@ -368,24 +410,24 @@ export const Container: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "EnvironmentVariable" - } - } - } + className: "EnvironmentVariable", + }, + }, + }, }, instanceView: { serializedName: "properties.instanceView", type: { name: "Composite", - className: "ContainerPropertiesInstanceView" - } + className: "ContainerPropertiesInstanceView", + }, }, resources: { serializedName: "properties.resources", type: { name: "Composite", - className: "ResourceRequirements" - } + className: "ResourceRequirements", + }, }, volumeMounts: { serializedName: "properties.volumeMounts", @@ -394,34 +436,34 @@ export const Container: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "VolumeMount" - } - } - } + className: "VolumeMount", + }, + }, + }, }, livenessProbe: { serializedName: "properties.livenessProbe", type: { name: "Composite", - className: "ContainerProbe" - } + className: "ContainerProbe", + }, }, readinessProbe: { serializedName: "properties.readinessProbe", type: { name: "Composite", - className: "ContainerProbe" - } + className: "ContainerProbe", + }, }, securityContext: { serializedName: "properties.securityContext", type: { name: "Composite", - className: "SecurityContextDefinition" - } - } - } - } + className: "SecurityContextDefinition", + }, + }, + }, + }, }; export const ContainerPort: coreClient.CompositeMapper = { @@ -432,18 +474,18 @@ export const ContainerPort: coreClient.CompositeMapper = { protocol: { serializedName: "protocol", type: { - name: "String" - } + name: "String", + }, }, port: { serializedName: "port", required: true, type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const EnvironmentVariable: coreClient.CompositeMapper = { @@ -455,23 +497,29 @@ export const EnvironmentVariable: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, value: { serializedName: "value", type: { - name: "String" - } + name: "String", + }, }, secureValue: { serializedName: "secureValue", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + secureValueReference: { + serializedName: "secureValueReference", + type: { + name: "String", + }, + }, + }, + }, }; export const ContainerPropertiesInstanceView: coreClient.CompositeMapper = { @@ -483,22 +531,22 @@ export const ContainerPropertiesInstanceView: coreClient.CompositeMapper = { serializedName: "restartCount", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, currentState: { serializedName: "currentState", type: { name: "Composite", - className: "ContainerState" - } + className: "ContainerState", + }, }, previousState: { serializedName: "previousState", type: { name: "Composite", - className: "ContainerState" - } + className: "ContainerState", + }, }, events: { serializedName: "events", @@ -508,13 +556,13 @@ export const ContainerPropertiesInstanceView: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Event" - } - } - } - } - } - } + className: "Event", + }, + }, + }, + }, + }, + }, }; export const ContainerState: coreClient.CompositeMapper = { @@ -526,39 +574,39 @@ export const ContainerState: coreClient.CompositeMapper = { serializedName: "state", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, startTime: { serializedName: "startTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, exitCode: { serializedName: "exitCode", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, finishTime: { serializedName: "finishTime", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, detailStatus: { serializedName: "detailStatus", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Event: coreClient.CompositeMapper = { @@ -570,46 +618,46 @@ export const Event: coreClient.CompositeMapper = { serializedName: "count", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, firstTimestamp: { serializedName: "firstTimestamp", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, lastTimestamp: { serializedName: "lastTimestamp", readOnly: true, type: { - name: "DateTime" - } + name: "DateTime", + }, }, name: { serializedName: "name", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, type: { serializedName: "type", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceRequirements: coreClient.CompositeMapper = { @@ -621,18 +669,18 @@ export const ResourceRequirements: coreClient.CompositeMapper = { serializedName: "requests", type: { name: "Composite", - className: "ResourceRequests" - } + className: "ResourceRequests", + }, }, limits: { serializedName: "limits", type: { name: "Composite", - className: "ResourceLimits" - } - } - } - } + className: "ResourceLimits", + }, + }, + }, + }, }; export const ResourceRequests: coreClient.CompositeMapper = { @@ -644,25 +692,25 @@ export const ResourceRequests: coreClient.CompositeMapper = { serializedName: "memoryInGB", required: true, type: { - name: "Number" - } + name: "Number", + }, }, cpu: { serializedName: "cpu", required: true, type: { - name: "Number" - } + name: "Number", + }, }, gpu: { serializedName: "gpu", type: { name: "Composite", - className: "GpuResource" - } - } - } - } + className: "GpuResource", + }, + }, + }, + }, }; export const GpuResource: coreClient.CompositeMapper = { @@ -674,18 +722,18 @@ export const GpuResource: coreClient.CompositeMapper = { serializedName: "count", required: true, type: { - name: "Number" - } + name: "Number", + }, }, sku: { serializedName: "sku", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ResourceLimits: coreClient.CompositeMapper = { @@ -696,24 +744,24 @@ export const ResourceLimits: coreClient.CompositeMapper = { memoryInGB: { serializedName: "memoryInGB", type: { - name: "Number" - } + name: "Number", + }, }, cpu: { serializedName: "cpu", type: { - name: "Number" - } + name: "Number", + }, }, gpu: { serializedName: "gpu", type: { name: "Composite", - className: "GpuResource" - } - } - } - } + className: "GpuResource", + }, + }, + }, + }, }; export const VolumeMount: coreClient.CompositeMapper = { @@ -725,24 +773,24 @@ export const VolumeMount: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, mountPath: { serializedName: "mountPath", required: true, type: { - name: "String" - } + name: "String", + }, }, readOnly: { serializedName: "readOnly", type: { - name: "Boolean" - } - } - } - } + name: "Boolean", + }, + }, + }, + }, }; export const ContainerProbe: coreClient.CompositeMapper = { @@ -754,48 +802,48 @@ export const ContainerProbe: coreClient.CompositeMapper = { serializedName: "exec", type: { name: "Composite", - className: "ContainerExec" - } + className: "ContainerExec", + }, }, httpGet: { serializedName: "httpGet", type: { name: "Composite", - className: "ContainerHttpGet" - } + className: "ContainerHttpGet", + }, }, initialDelaySeconds: { serializedName: "initialDelaySeconds", type: { - name: "Number" - } + name: "Number", + }, }, periodSeconds: { serializedName: "periodSeconds", type: { - name: "Number" - } + name: "Number", + }, }, failureThreshold: { serializedName: "failureThreshold", type: { - name: "Number" - } + name: "Number", + }, }, successThreshold: { serializedName: "successThreshold", type: { - name: "Number" - } + name: "Number", + }, }, timeoutSeconds: { serializedName: "timeoutSeconds", type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const ContainerExec: coreClient.CompositeMapper = { @@ -809,13 +857,13 @@ export const ContainerExec: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } - } - } - } + name: "String", + }, + }, + }, + }, + }, + }, }; export const ContainerHttpGet: coreClient.CompositeMapper = { @@ -826,21 +874,21 @@ export const ContainerHttpGet: coreClient.CompositeMapper = { path: { serializedName: "path", type: { - name: "String" - } + name: "String", + }, }, port: { serializedName: "port", required: true, type: { - name: "Number" - } + name: "Number", + }, }, scheme: { serializedName: "scheme", type: { - name: "String" - } + name: "String", + }, }, httpHeaders: { serializedName: "httpHeaders", @@ -849,13 +897,13 @@ export const ContainerHttpGet: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "HttpHeader" - } - } - } - } - } - } + className: "HttpHeader", + }, + }, + }, + }, + }, + }, }; export const HttpHeader: coreClient.CompositeMapper = { @@ -866,17 +914,17 @@ export const HttpHeader: coreClient.CompositeMapper = { name: { serializedName: "name", type: { - name: "String" - } + name: "String", + }, }, value: { serializedName: "value", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const SecurityContextDefinition: coreClient.CompositeMapper = { @@ -887,75 +935,76 @@ export const SecurityContextDefinition: coreClient.CompositeMapper = { privileged: { serializedName: "privileged", type: { - name: "Boolean" - } + name: "Boolean", + }, }, allowPrivilegeEscalation: { serializedName: "allowPrivilegeEscalation", type: { - name: "Boolean" - } + name: "Boolean", + }, }, capabilities: { serializedName: "capabilities", type: { name: "Composite", - className: "SecurityContextCapabilitiesDefinition" - } + className: "SecurityContextCapabilitiesDefinition", + }, }, runAsGroup: { serializedName: "runAsGroup", type: { - name: "Number" - } + name: "Number", + }, }, runAsUser: { serializedName: "runAsUser", type: { - name: "Number" - } + name: "Number", + }, }, seccompProfile: { serializedName: "seccompProfile", type: { - name: "String" - } - } - } - } -}; - -export const SecurityContextCapabilitiesDefinition: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "SecurityContextCapabilitiesDefinition", - modelProperties: { - add: { - serializedName: "add", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } + name: "String", + }, }, - drop: { - serializedName: "drop", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } - } - } - } + }, + }, }; +export const SecurityContextCapabilitiesDefinition: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "SecurityContextCapabilitiesDefinition", + modelProperties: { + add: { + serializedName: "add", + type: { + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + drop: { + serializedName: "drop", + type: { + name: "Sequence", + element: { + type: { + name: "String", + }, + }, + }, + }, + }, + }, + }; + export const ImageRegistryCredential: coreClient.CompositeMapper = { type: { name: "Composite", @@ -965,35 +1014,41 @@ export const ImageRegistryCredential: coreClient.CompositeMapper = { serializedName: "server", required: true, type: { - name: "String" - } + name: "String", + }, }, username: { serializedName: "username", type: { - name: "String" - } + name: "String", + }, }, password: { serializedName: "password", type: { - name: "String" - } + name: "String", + }, + }, + passwordReference: { + serializedName: "passwordReference", + type: { + name: "String", + }, }, identity: { serializedName: "identity", type: { - name: "String" - } + name: "String", + }, }, identityUrl: { serializedName: "identityUrl", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const IpAddress: coreClient.CompositeMapper = { @@ -1009,46 +1064,46 @@ export const IpAddress: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Port" - } - } - } + className: "Port", + }, + }, + }, }, type: { serializedName: "type", required: true, type: { - name: "String" - } + name: "String", + }, }, ip: { serializedName: "ip", type: { - name: "String" - } + name: "String", + }, }, dnsNameLabel: { serializedName: "dnsNameLabel", type: { - name: "String" - } + name: "String", + }, }, autoGeneratedDomainNameLabelScope: { defaultValue: "Unsecure", serializedName: "autoGeneratedDomainNameLabelScope", type: { - name: "String" - } + name: "String", + }, }, fqdn: { serializedName: "fqdn", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Port: coreClient.CompositeMapper = { @@ -1059,18 +1114,18 @@ export const Port: coreClient.CompositeMapper = { protocol: { serializedName: "protocol", type: { - name: "String" - } + name: "String", + }, }, port: { serializedName: "port", required: true, type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const Volume: coreClient.CompositeMapper = { @@ -1082,39 +1137,46 @@ export const Volume: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, azureFile: { serializedName: "azureFile", type: { name: "Composite", - className: "AzureFileVolume" - } + className: "AzureFileVolume", + }, }, emptyDir: { serializedName: "emptyDir", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, secret: { serializedName: "secret", type: { name: "Dictionary", - value: { type: { name: "String" } } - } + value: { type: { name: "String" } }, + }, + }, + secretReference: { + serializedName: "secretReference", + type: { + name: "Dictionary", + value: { type: { name: "String" } }, + }, }, gitRepo: { serializedName: "gitRepo", type: { name: "Composite", - className: "GitRepoVolume" - } - } - } - } + className: "GitRepoVolume", + }, + }, + }, + }, }; export const AzureFileVolume: coreClient.CompositeMapper = { @@ -1126,30 +1188,36 @@ export const AzureFileVolume: coreClient.CompositeMapper = { serializedName: "shareName", required: true, type: { - name: "String" - } + name: "String", + }, }, readOnly: { serializedName: "readOnly", type: { - name: "Boolean" - } + name: "Boolean", + }, }, storageAccountName: { serializedName: "storageAccountName", required: true, type: { - name: "String" - } + name: "String", + }, }, storageAccountKey: { serializedName: "storageAccountKey", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + storageAccountKeyReference: { + serializedName: "storageAccountKeyReference", + type: { + name: "String", + }, + }, + }, + }, }; export const GitRepoVolume: coreClient.CompositeMapper = { @@ -1160,55 +1228,56 @@ export const GitRepoVolume: coreClient.CompositeMapper = { directory: { serializedName: "directory", type: { - name: "String" - } + name: "String", + }, }, repository: { serializedName: "repository", required: true, type: { - name: "String" - } + name: "String", + }, }, revision: { serializedName: "revision", type: { - name: "String" - } - } - } - } -}; - -export const ContainerGroupPropertiesInstanceView: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "ContainerGroupPropertiesInstanceView", - modelProperties: { - events: { - serializedName: "events", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Event" - } - } - } + name: "String", + }, }, - state: { - serializedName: "state", - readOnly: true, - type: { - name: "String" - } - } - } - } + }, + }, }; +export const ContainerGroupPropertiesInstanceView: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "ContainerGroupPropertiesInstanceView", + modelProperties: { + events: { + serializedName: "events", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Event", + }, + }, + }, + }, + state: { + serializedName: "state", + readOnly: true, + type: { + name: "String", + }, + }, + }, + }, + }; + export const ContainerGroupDiagnostics: coreClient.CompositeMapper = { type: { name: "Composite", @@ -1218,11 +1287,11 @@ export const ContainerGroupDiagnostics: coreClient.CompositeMapper = { serializedName: "logAnalytics", type: { name: "Composite", - className: "LogAnalytics" - } - } - } - } + className: "LogAnalytics", + }, + }, + }, + }, }; export const LogAnalytics: coreClient.CompositeMapper = { @@ -1234,37 +1303,37 @@ export const LogAnalytics: coreClient.CompositeMapper = { serializedName: "workspaceId", required: true, type: { - name: "String" - } + name: "String", + }, }, workspaceKey: { serializedName: "workspaceKey", required: true, type: { - name: "String" - } + name: "String", + }, }, logType: { serializedName: "logType", type: { - name: "String" - } + name: "String", + }, }, metadata: { serializedName: "metadata", type: { name: "Dictionary", - value: { type: { name: "String" } } - } + value: { type: { name: "String" } }, + }, }, workspaceResourceId: { serializedName: "workspaceResourceId", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ContainerGroupSubnetId: coreClient.CompositeMapper = { @@ -1276,17 +1345,17 @@ export const ContainerGroupSubnetId: coreClient.CompositeMapper = { serializedName: "id", required: true, type: { - name: "String" - } + name: "String", + }, }, name: { serializedName: "name", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const DnsConfiguration: coreClient.CompositeMapper = { @@ -1301,25 +1370,25 @@ export const DnsConfiguration: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, searchDomains: { serializedName: "searchDomains", type: { - name: "String" - } + name: "String", + }, }, options: { serializedName: "options", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const EncryptionProperties: coreClient.CompositeMapper = { @@ -1331,31 +1400,31 @@ export const EncryptionProperties: coreClient.CompositeMapper = { serializedName: "vaultBaseUrl", required: true, type: { - name: "String" - } + name: "String", + }, }, keyName: { serializedName: "keyName", required: true, type: { - name: "String" - } + name: "String", + }, }, keyVersion: { serializedName: "keyVersion", required: true, type: { - name: "String" - } + name: "String", + }, }, identity: { serializedName: "identity", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const InitContainerDefinition: coreClient.CompositeMapper = { @@ -1367,14 +1436,14 @@ export const InitContainerDefinition: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, image: { serializedName: "properties.image", type: { - name: "String" - } + name: "String", + }, }, command: { serializedName: "properties.command", @@ -1382,10 +1451,10 @@ export const InitContainerDefinition: coreClient.CompositeMapper = { name: "Sequence", element: { type: { - name: "String" - } - } - } + name: "String", + }, + }, + }, }, environmentVariables: { serializedName: "properties.environmentVariables", @@ -1394,17 +1463,17 @@ export const InitContainerDefinition: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "EnvironmentVariable" - } - } - } + className: "EnvironmentVariable", + }, + }, + }, }, instanceView: { serializedName: "properties.instanceView", type: { name: "Composite", - className: "InitContainerPropertiesDefinitionInstanceView" - } + className: "InitContainerPropertiesDefinitionInstanceView", + }, }, volumeMounts: { serializedName: "properties.volumeMounts", @@ -1413,65 +1482,66 @@ export const InitContainerDefinition: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "VolumeMount" - } - } - } + className: "VolumeMount", + }, + }, + }, }, securityContext: { serializedName: "properties.securityContext", type: { name: "Composite", - className: "SecurityContextDefinition" - } - } - } - } -}; - -export const InitContainerPropertiesDefinitionInstanceView: coreClient.CompositeMapper = { - type: { - name: "Composite", - className: "InitContainerPropertiesDefinitionInstanceView", - modelProperties: { - restartCount: { - serializedName: "restartCount", - readOnly: true, - type: { - name: "Number" - } + className: "SecurityContextDefinition", + }, }, - currentState: { - serializedName: "currentState", - type: { - name: "Composite", - className: "ContainerState" - } - }, - previousState: { - serializedName: "previousState", - type: { - name: "Composite", - className: "ContainerState" - } - }, - events: { - serializedName: "events", - readOnly: true, - type: { - name: "Sequence", - element: { - type: { - name: "Composite", - className: "Event" - } - } - } - } - } - } + }, + }, }; +export const InitContainerPropertiesDefinitionInstanceView: coreClient.CompositeMapper = + { + type: { + name: "Composite", + className: "InitContainerPropertiesDefinitionInstanceView", + modelProperties: { + restartCount: { + serializedName: "restartCount", + readOnly: true, + type: { + name: "Number", + }, + }, + currentState: { + serializedName: "currentState", + type: { + name: "Composite", + className: "ContainerState", + }, + }, + previousState: { + serializedName: "previousState", + type: { + name: "Composite", + className: "ContainerState", + }, + }, + events: { + serializedName: "events", + readOnly: true, + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Event", + }, + }, + }, + }, + }, + }, + }; + export const DeploymentExtensionSpec: coreClient.CompositeMapper = { type: { name: "Composite", @@ -1481,37 +1551,37 @@ export const DeploymentExtensionSpec: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, extensionType: { serializedName: "properties.extensionType", type: { - name: "String" - } + name: "String", + }, }, version: { serializedName: "properties.version", type: { - name: "String" - } + name: "String", + }, }, settings: { serializedName: "properties.settings", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, protectedSettings: { serializedName: "properties.protectedSettings", type: { name: "Dictionary", - value: { type: { name: "any" } } - } - } - } - } + value: { type: { name: "any" } }, + }, + }, + }, + }, }; export const ConfidentialComputeProperties: coreClient.CompositeMapper = { @@ -1522,11 +1592,11 @@ export const ConfidentialComputeProperties: coreClient.CompositeMapper = { ccePolicy: { serializedName: "ccePolicy", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CloudError: coreClient.CompositeMapper = { @@ -1538,11 +1608,11 @@ export const CloudError: coreClient.CompositeMapper = { serializedName: "error", type: { name: "Composite", - className: "CloudErrorBody" - } - } - } - } + className: "CloudErrorBody", + }, + }, + }, + }, }; export const CloudErrorBody: coreClient.CompositeMapper = { @@ -1553,20 +1623,20 @@ export const CloudErrorBody: coreClient.CompositeMapper = { code: { serializedName: "code", type: { - name: "String" - } + name: "String", + }, }, message: { serializedName: "message", type: { - name: "String" - } + name: "String", + }, }, target: { serializedName: "target", type: { - name: "String" - } + name: "String", + }, }, details: { serializedName: "details", @@ -1575,13 +1645,13 @@ export const CloudErrorBody: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "CloudErrorBody" - } - } - } - } - } - } + className: "CloudErrorBody", + }, + }, + }, + }, + }, + }, }; export const OperationListResult: coreClient.CompositeMapper = { @@ -1596,19 +1666,19 @@ export const OperationListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Operation" - } - } - } + className: "Operation", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Operation: coreClient.CompositeMapper = { @@ -1620,31 +1690,31 @@ export const Operation: coreClient.CompositeMapper = { serializedName: "name", required: true, type: { - name: "String" - } + name: "String", + }, }, display: { serializedName: "display", type: { name: "Composite", - className: "OperationDisplay" - } + className: "OperationDisplay", + }, }, properties: { serializedName: "properties", type: { name: "Dictionary", - value: { type: { name: "any" } } - } + value: { type: { name: "any" } }, + }, }, origin: { serializedName: "origin", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const OperationDisplay: coreClient.CompositeMapper = { @@ -1655,29 +1725,29 @@ export const OperationDisplay: coreClient.CompositeMapper = { provider: { serializedName: "provider", type: { - name: "String" - } + name: "String", + }, }, resource: { serializedName: "resource", type: { - name: "String" - } + name: "String", + }, }, operation: { serializedName: "operation", type: { - name: "String" - } + name: "String", + }, }, description: { serializedName: "description", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const UsageListResult: coreClient.CompositeMapper = { @@ -1693,13 +1763,13 @@ export const UsageListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Usage" - } - } - } - } - } - } + className: "Usage", + }, + }, + }, + }, + }, + }, }; export const Usage: coreClient.CompositeMapper = { @@ -1711,39 +1781,39 @@ export const Usage: coreClient.CompositeMapper = { serializedName: "id", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, unit: { serializedName: "unit", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, currentValue: { serializedName: "currentValue", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, limit: { serializedName: "limit", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, name: { serializedName: "name", type: { name: "Composite", - className: "UsageName" - } - } - } - } + className: "UsageName", + }, + }, + }, + }, }; export const UsageName: coreClient.CompositeMapper = { @@ -1755,18 +1825,18 @@ export const UsageName: coreClient.CompositeMapper = { serializedName: "value", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, localizedValue: { serializedName: "localizedValue", readOnly: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Logs: coreClient.CompositeMapper = { @@ -1777,11 +1847,11 @@ export const Logs: coreClient.CompositeMapper = { content: { serializedName: "content", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ContainerExecRequest: coreClient.CompositeMapper = { @@ -1792,18 +1862,18 @@ export const ContainerExecRequest: coreClient.CompositeMapper = { command: { serializedName: "command", type: { - name: "String" - } + name: "String", + }, }, terminalSize: { serializedName: "terminalSize", type: { name: "Composite", - className: "ContainerExecRequestTerminalSize" - } - } - } - } + className: "ContainerExecRequestTerminalSize", + }, + }, + }, + }, }; export const ContainerExecRequestTerminalSize: coreClient.CompositeMapper = { @@ -1814,17 +1884,17 @@ export const ContainerExecRequestTerminalSize: coreClient.CompositeMapper = { rows: { serializedName: "rows", type: { - name: "Number" - } + name: "Number", + }, }, cols: { serializedName: "cols", type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const ContainerExecResponse: coreClient.CompositeMapper = { @@ -1835,17 +1905,17 @@ export const ContainerExecResponse: coreClient.CompositeMapper = { webSocketUri: { serializedName: "webSocketUri", type: { - name: "String" - } + name: "String", + }, }, password: { serializedName: "password", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const ContainerAttachResponse: coreClient.CompositeMapper = { @@ -1856,17 +1926,17 @@ export const ContainerAttachResponse: coreClient.CompositeMapper = { webSocketUri: { serializedName: "webSocketUri", type: { - name: "String" - } + name: "String", + }, }, password: { serializedName: "password", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CachedImagesListResult: coreClient.CompositeMapper = { @@ -1881,19 +1951,19 @@ export const CachedImagesListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "CachedImages" - } - } - } + className: "CachedImages", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CachedImages: coreClient.CompositeMapper = { @@ -1905,18 +1975,18 @@ export const CachedImages: coreClient.CompositeMapper = { serializedName: "osType", required: true, type: { - name: "String" - } + name: "String", + }, }, image: { serializedName: "image", required: true, type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const CapabilitiesListResult: coreClient.CompositeMapper = { @@ -1931,19 +2001,19 @@ export const CapabilitiesListResult: coreClient.CompositeMapper = { element: { type: { name: "Composite", - className: "Capabilities" - } - } - } + className: "Capabilities", + }, + }, + }, }, nextLink: { serializedName: "nextLink", type: { - name: "String" - } - } - } - } + name: "String", + }, + }, + }, + }, }; export const Capabilities: coreClient.CompositeMapper = { @@ -1955,46 +2025,46 @@ export const Capabilities: coreClient.CompositeMapper = { serializedName: "resourceType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, osType: { serializedName: "osType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, location: { serializedName: "location", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, ipAddressType: { serializedName: "ipAddressType", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, gpu: { serializedName: "gpu", readOnly: true, type: { - name: "String" - } + name: "String", + }, }, capabilities: { serializedName: "capabilities", type: { name: "Composite", - className: "CapabilitiesCapabilities" - } - } - } - } + className: "CapabilitiesCapabilities", + }, + }, + }, + }, }; export const CapabilitiesCapabilities: coreClient.CompositeMapper = { @@ -2006,25 +2076,25 @@ export const CapabilitiesCapabilities: coreClient.CompositeMapper = { serializedName: "maxMemoryInGB", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, maxCpu: { serializedName: "maxCpu", readOnly: true, type: { - name: "Number" - } + name: "Number", + }, }, maxGpuCount: { serializedName: "maxGpuCount", readOnly: true, type: { - name: "Number" - } - } - } - } + name: "Number", + }, + }, + }, + }, }; export const ContainerGroup: coreClient.CompositeMapper = { @@ -2033,7 +2103,7 @@ export const ContainerGroup: coreClient.CompositeMapper = { className: "ContainerGroup", modelProperties: { ...Resource.type.modelProperties, - ...ContainerGroupProperties.type.modelProperties - } - } + ...ContainerGroupProperties.type.modelProperties, + }, + }, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/models/parameters.ts b/sdk/containerinstance/arm-containerinstance/src/models/parameters.ts index e0cf5d2709cf..4763120cc3cd 100644 --- a/sdk/containerinstance/arm-containerinstance/src/models/parameters.ts +++ b/sdk/containerinstance/arm-containerinstance/src/models/parameters.ts @@ -9,12 +9,12 @@ import { OperationParameter, OperationURLParameter, - OperationQueryParameter + OperationQueryParameter, } from "@azure/core-client"; import { ContainerGroup as ContainerGroupMapper, Resource as ResourceMapper, - ContainerExecRequest as ContainerExecRequestMapper + ContainerExecRequest as ContainerExecRequestMapper, } from "../models/mappers"; export const accept: OperationParameter = { @@ -24,9 +24,9 @@ export const accept: OperationParameter = { isConstant: true, serializedName: "Accept", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const $host: OperationURLParameter = { @@ -35,10 +35,10 @@ export const $host: OperationURLParameter = { serializedName: "$host", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const subscriptionId: OperationURLParameter = { @@ -47,21 +47,21 @@ export const subscriptionId: OperationURLParameter = { serializedName: "subscriptionId", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const apiVersion: OperationQueryParameter = { parameterPath: "apiVersion", mapper: { - defaultValue: "2023-05-01", + defaultValue: "2024-10-01-preview", isConstant: true, serializedName: "api-version", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const resourceGroupName: OperationURLParameter = { @@ -70,9 +70,9 @@ export const resourceGroupName: OperationURLParameter = { serializedName: "resourceGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const containerGroupName: OperationURLParameter = { @@ -81,9 +81,9 @@ export const containerGroupName: OperationURLParameter = { serializedName: "containerGroupName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const contentType: OperationParameter = { @@ -93,19 +93,19 @@ export const contentType: OperationParameter = { isConstant: true, serializedName: "Content-Type", type: { - name: "String" - } - } + name: "String", + }, + }, }; export const containerGroup: OperationParameter = { parameterPath: "containerGroup", - mapper: ContainerGroupMapper + mapper: ContainerGroupMapper, }; export const resource: OperationParameter = { parameterPath: "resource", - mapper: ResourceMapper + mapper: ResourceMapper, }; export const nextLink: OperationURLParameter = { @@ -114,10 +114,10 @@ export const nextLink: OperationURLParameter = { serializedName: "nextLink", required: true, type: { - name: "String" - } + name: "String", + }, }, - skipEncoding: true + skipEncoding: true, }; export const location: OperationURLParameter = { @@ -126,9 +126,9 @@ export const location: OperationURLParameter = { serializedName: "location", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const containerName: OperationURLParameter = { @@ -137,9 +137,9 @@ export const containerName: OperationURLParameter = { serializedName: "containerName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const tail: OperationQueryParameter = { @@ -147,9 +147,9 @@ export const tail: OperationQueryParameter = { mapper: { serializedName: "tail", type: { - name: "Number" - } - } + name: "Number", + }, + }, }; export const timestamps: OperationQueryParameter = { @@ -157,14 +157,14 @@ export const timestamps: OperationQueryParameter = { mapper: { serializedName: "timestamps", type: { - name: "Boolean" - } - } + name: "Boolean", + }, + }, }; export const containerExecRequest: OperationParameter = { parameterPath: "containerExecRequest", - mapper: ContainerExecRequestMapper + mapper: ContainerExecRequestMapper, }; export const virtualNetworkName: OperationURLParameter = { @@ -173,9 +173,9 @@ export const virtualNetworkName: OperationURLParameter = { serializedName: "virtualNetworkName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; export const subnetName: OperationURLParameter = { @@ -184,7 +184,7 @@ export const subnetName: OperationURLParameter = { serializedName: "subnetName", required: true, type: { - name: "String" - } - } + name: "String", + }, + }, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operations/containerGroups.ts b/sdk/containerinstance/arm-containerinstance/src/operations/containerGroups.ts index 94cb7ea403cf..0d720eda7468 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operations/containerGroups.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operations/containerGroups.ts @@ -16,7 +16,7 @@ import { ContainerInstanceManagementClient } from "../containerInstanceManagemen import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { @@ -42,7 +42,7 @@ import { ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams, ContainerGroupsGetOutboundNetworkDependenciesEndpointsResponse, ContainerGroupsListNextResponse, - ContainerGroupsListByResourceGroupNextResponse + ContainerGroupsListByResourceGroupNextResponse, } from "../models"; /// @@ -65,7 +65,7 @@ export class ContainerGroupsImpl implements ContainerGroups { * @param options The options parameters. */ public list( - options?: ContainerGroupsListOptionalParams + options?: ContainerGroupsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -80,13 +80,13 @@ export class ContainerGroupsImpl implements ContainerGroups { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: ContainerGroupsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ContainerGroupsListResponse; let continuationToken = settings?.continuationToken; @@ -107,7 +107,7 @@ export class ContainerGroupsImpl implements ContainerGroups { } private async *listPagingAll( - options?: ContainerGroupsListOptionalParams + options?: ContainerGroupsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -123,7 +123,7 @@ export class ContainerGroupsImpl implements ContainerGroups { */ public listByResourceGroup( resourceGroupName: string, - options?: ContainerGroupsListByResourceGroupOptionalParams + options?: ContainerGroupsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listByResourceGroupPagingAll(resourceGroupName, options); return { @@ -140,16 +140,16 @@ export class ContainerGroupsImpl implements ContainerGroups { return this.listByResourceGroupPagingPage( resourceGroupName, options, - settings + settings, ); - } + }, }; } private async *listByResourceGroupPagingPage( resourceGroupName: string, options?: ContainerGroupsListByResourceGroupOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: ContainerGroupsListByResourceGroupResponse; let continuationToken = settings?.continuationToken; @@ -164,7 +164,7 @@ export class ContainerGroupsImpl implements ContainerGroups { result = await this._listByResourceGroupNext( resourceGroupName, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -175,11 +175,11 @@ export class ContainerGroupsImpl implements ContainerGroups { private async *listByResourceGroupPagingAll( resourceGroupName: string, - options?: ContainerGroupsListByResourceGroupOptionalParams + options?: ContainerGroupsListByResourceGroupOptionalParams, ): AsyncIterableIterator { for await (const page of this.listByResourceGroupPagingPage( resourceGroupName, - options + options, )) { yield* page; } @@ -192,7 +192,7 @@ export class ContainerGroupsImpl implements ContainerGroups { * @param options The options parameters. */ private _list( - options?: ContainerGroupsListOptionalParams + options?: ContainerGroupsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -206,11 +206,11 @@ export class ContainerGroupsImpl implements ContainerGroups { */ private _listByResourceGroup( resourceGroupName: string, - options?: ContainerGroupsListByResourceGroupOptionalParams + options?: ContainerGroupsListByResourceGroupOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, options }, - listByResourceGroupOperationSpec + listByResourceGroupOperationSpec, ); } @@ -225,11 +225,11 @@ export class ContainerGroupsImpl implements ContainerGroups { get( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsGetOptionalParams + options?: ContainerGroupsGetOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, options }, - getOperationSpec + getOperationSpec, ); } @@ -244,7 +244,7 @@ export class ContainerGroupsImpl implements ContainerGroups { resourceGroupName: string, containerGroupName: string, containerGroup: ContainerGroup, - options?: ContainerGroupsCreateOrUpdateOptionalParams + options?: ContainerGroupsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -253,21 +253,20 @@ export class ContainerGroupsImpl implements ContainerGroups { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -276,8 +275,8 @@ export class ContainerGroupsImpl implements ContainerGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -285,22 +284,22 @@ export class ContainerGroupsImpl implements ContainerGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, containerGroupName, containerGroup, options }, - spec: createOrUpdateOperationSpec + spec: createOrUpdateOperationSpec, }); const poller = await createHttpPoller< ContainerGroupsCreateOrUpdateResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -317,13 +316,13 @@ export class ContainerGroupsImpl implements ContainerGroups { resourceGroupName: string, containerGroupName: string, containerGroup: ContainerGroup, - options?: ContainerGroupsCreateOrUpdateOptionalParams + options?: ContainerGroupsCreateOrUpdateOptionalParams, ): Promise { const poller = await this.beginCreateOrUpdate( resourceGroupName, containerGroupName, containerGroup, - options + options, ); return poller.pollUntilDone(); } @@ -339,11 +338,11 @@ export class ContainerGroupsImpl implements ContainerGroups { resourceGroupName: string, containerGroupName: string, resource: Resource, - options?: ContainerGroupsUpdateOptionalParams + options?: ContainerGroupsUpdateOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, resource, options }, - updateOperationSpec + updateOperationSpec, ); } @@ -357,7 +356,7 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginDelete( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsDeleteOptionalParams + options?: ContainerGroupsDeleteOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -366,21 +365,20 @@ export class ContainerGroupsImpl implements ContainerGroups { > { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -389,8 +387,8 @@ export class ContainerGroupsImpl implements ContainerGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -398,22 +396,22 @@ export class ContainerGroupsImpl implements ContainerGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, containerGroupName, options }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller< ContainerGroupsDeleteResponse, OperationState >(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -429,12 +427,12 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginDeleteAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsDeleteOptionalParams + options?: ContainerGroupsDeleteOptionalParams, ): Promise { const poller = await this.beginDelete( resourceGroupName, containerGroupName, - options + options, ); return poller.pollUntilDone(); } @@ -449,25 +447,24 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginRestart( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsRestartOptionalParams + options?: ContainerGroupsRestartOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -476,8 +473,8 @@ export class ContainerGroupsImpl implements ContainerGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -485,19 +482,19 @@ export class ContainerGroupsImpl implements ContainerGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, containerGroupName, options }, - spec: restartOperationSpec + spec: restartOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -513,12 +510,12 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginRestartAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsRestartOptionalParams + options?: ContainerGroupsRestartOptionalParams, ): Promise { const poller = await this.beginRestart( resourceGroupName, containerGroupName, - options + options, ); return poller.pollUntilDone(); } @@ -533,11 +530,11 @@ export class ContainerGroupsImpl implements ContainerGroups { stop( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStopOptionalParams + options?: ContainerGroupsStopOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, options }, - stopOperationSpec + stopOperationSpec, ); } @@ -551,25 +548,24 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginStart( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStartOptionalParams + options?: ContainerGroupsStartOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -578,8 +574,8 @@ export class ContainerGroupsImpl implements ContainerGroups { ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -587,19 +583,19 @@ export class ContainerGroupsImpl implements ContainerGroups { rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, containerGroupName, options }, - spec: startOperationSpec + spec: startOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -615,12 +611,12 @@ export class ContainerGroupsImpl implements ContainerGroups { async beginStartAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStartOptionalParams + options?: ContainerGroupsStartOptionalParams, ): Promise { const poller = await this.beginStart( resourceGroupName, containerGroupName, - options + options, ); return poller.pollUntilDone(); } @@ -635,11 +631,11 @@ export class ContainerGroupsImpl implements ContainerGroups { getOutboundNetworkDependenciesEndpoints( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams + options?: ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, options }, - getOutboundNetworkDependenciesEndpointsOperationSpec + getOutboundNetworkDependenciesEndpointsOperationSpec, ); } @@ -650,11 +646,11 @@ export class ContainerGroupsImpl implements ContainerGroups { */ private _listNext( nextLink: string, - options?: ContainerGroupsListNextOptionalParams + options?: ContainerGroupsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } @@ -667,11 +663,11 @@ export class ContainerGroupsImpl implements ContainerGroups { private _listByResourceGroupNext( resourceGroupName: string, nextLink: string, - options?: ContainerGroupsListByResourceGroupNextOptionalParams + options?: ContainerGroupsListByResourceGroupNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, nextLink, options }, - listByResourceGroupNextOperationSpec + listByResourceGroupNextOperationSpec, ); } } @@ -679,85 +675,81 @@ export class ContainerGroupsImpl implements ContainerGroups { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/containerGroups", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/containerGroups", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ContainerGroupListResult + bodyMapper: Mappers.ContainerGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host, Parameters.subscriptionId], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ContainerGroupListResult + bodyMapper: Mappers.ContainerGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.resourceGroupName + Parameters.resourceGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const getOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const createOrUpdateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", httpMethod: "PUT", responses: { 200: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 201: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 202: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 204: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.containerGroup, queryParameters: [Parameters.apiVersion], @@ -765,23 +757,22 @@ const createOrUpdateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const updateOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", httpMethod: "PATCH", responses: { 200: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.resource, queryParameters: [Parameters.apiVersion], @@ -789,46 +780,44 @@ const updateOperationSpec: coreClient.OperationSpec = { Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}", httpMethod: "DELETE", responses: { 200: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 201: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 202: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, 204: { - bodyMapper: Mappers.ContainerGroup + bodyMapper: Mappers.ContainerGroup, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const restartOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/restart", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/restart", httpMethod: "POST", responses: { 200: {}, @@ -836,42 +825,40 @@ const restartOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const stopOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/stop", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/stop", httpMethod: "POST", responses: { 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const startOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/start", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/start", httpMethod: "POST", responses: { 200: {}, @@ -879,79 +866,79 @@ const startOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } - }, - queryParameters: [Parameters.apiVersion], - urlParameters: [ - Parameters.$host, - Parameters.subscriptionId, - Parameters.resourceGroupName, - Parameters.containerGroupName - ], - headerParameters: [Parameters.accept], - serializer -}; -const getOutboundNetworkDependenciesEndpointsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/outboundNetworkDependenciesEndpoints", - httpMethod: "GET", - responses: { - 200: { - bodyMapper: { - type: { name: "Sequence", element: { type: { name: "String" } } } - } + bodyMapper: Mappers.CloudError, }, - default: { - bodyMapper: Mappers.CloudError - } }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.containerGroupName + Parameters.containerGroupName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; +const getOutboundNetworkDependenciesEndpointsOperationSpec: coreClient.OperationSpec = + { + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/outboundNetworkDependenciesEndpoints", + httpMethod: "GET", + responses: { + 200: { + bodyMapper: { + type: { name: "Sequence", element: { type: { name: "String" } } }, + }, + }, + default: { + bodyMapper: Mappers.CloudError, + }, + }, + queryParameters: [Parameters.apiVersion], + urlParameters: [ + Parameters.$host, + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.containerGroupName, + ], + headerParameters: [Parameters.accept], + serializer, + }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ContainerGroupListResult + bodyMapper: Mappers.ContainerGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.nextLink + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.ContainerGroupListResult + bodyMapper: Mappers.ContainerGroupListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, - Parameters.nextLink + Parameters.nextLink, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operations/containers.ts b/sdk/containerinstance/arm-containerinstance/src/operations/containers.ts index 38aad41bea55..ac85ab1968bd 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operations/containers.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operations/containers.ts @@ -18,7 +18,7 @@ import { ContainersExecuteCommandOptionalParams, ContainersExecuteCommandResponse, ContainersAttachOptionalParams, - ContainersAttachResponse + ContainersAttachResponse, } from "../models"; /** Class containing Containers operations. */ @@ -44,11 +44,11 @@ export class ContainersImpl implements Containers { resourceGroupName: string, containerGroupName: string, containerName: string, - options?: ContainersListLogsOptionalParams + options?: ContainersListLogsOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, containerName, options }, - listLogsOperationSpec + listLogsOperationSpec, ); } @@ -66,7 +66,7 @@ export class ContainersImpl implements Containers { containerGroupName: string, containerName: string, containerExecRequest: ContainerExecRequest, - options?: ContainersExecuteCommandOptionalParams + options?: ContainersExecuteCommandOptionalParams, ): Promise { return this.client.sendOperationRequest( { @@ -74,9 +74,9 @@ export class ContainersImpl implements Containers { containerGroupName, containerName, containerExecRequest, - options + options, }, - executeCommandOperationSpec + executeCommandOperationSpec, ); } @@ -92,11 +92,11 @@ export class ContainersImpl implements Containers { resourceGroupName: string, containerGroupName: string, containerName: string, - options?: ContainersAttachOptionalParams + options?: ContainersAttachOptionalParams, ): Promise { return this.client.sendOperationRequest( { resourceGroupName, containerGroupName, containerName, options }, - attachOperationSpec + attachOperationSpec, ); } } @@ -104,43 +104,41 @@ export class ContainersImpl implements Containers { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listLogsOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/logs", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/logs", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.Logs + bodyMapper: Mappers.Logs, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [ Parameters.apiVersion, Parameters.tail, - Parameters.timestamps + Parameters.timestamps, ], urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.containerGroupName, - Parameters.containerName + Parameters.containerName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const executeCommandOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/exec", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/exec", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.ContainerExecResponse + bodyMapper: Mappers.ContainerExecResponse, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, requestBody: Parameters.containerExecRequest, queryParameters: [Parameters.apiVersion], @@ -149,23 +147,22 @@ const executeCommandOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.containerGroupName, - Parameters.containerName + Parameters.containerName, ], headerParameters: [Parameters.accept, Parameters.contentType], mediaType: "json", - serializer + serializer, }; const attachOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/attach", + path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerInstance/containerGroups/{containerGroupName}/containers/{containerName}/attach", httpMethod: "POST", responses: { 200: { - bodyMapper: Mappers.ContainerAttachResponse + bodyMapper: Mappers.ContainerAttachResponse, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -173,8 +170,8 @@ const attachOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.containerGroupName, - Parameters.containerName + Parameters.containerName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operations/location.ts b/sdk/containerinstance/arm-containerinstance/src/operations/location.ts index 302be880d41c..c6aefcc62cad 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operations/location.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operations/location.ts @@ -26,7 +26,7 @@ import { LocationListCapabilitiesOptionalParams, LocationListCapabilitiesResponse, LocationListCachedImagesNextResponse, - LocationListCapabilitiesNextResponse + LocationListCapabilitiesNextResponse, } from "../models"; /// @@ -49,7 +49,7 @@ export class LocationImpl implements Location { */ public listUsage( location: string, - options?: LocationListUsageOptionalParams + options?: LocationListUsageOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listUsagePagingAll(location, options); return { @@ -64,14 +64,14 @@ export class LocationImpl implements Location { throw new Error("maxPageSize is not supported by this operation."); } return this.listUsagePagingPage(location, options, settings); - } + }, }; } private async *listUsagePagingPage( location: string, options?: LocationListUsageOptionalParams, - _settings?: PageSettings + _settings?: PageSettings, ): AsyncIterableIterator { let result: LocationListUsageResponse; result = await this._listUsage(location, options); @@ -80,7 +80,7 @@ export class LocationImpl implements Location { private async *listUsagePagingAll( location: string, - options?: LocationListUsageOptionalParams + options?: LocationListUsageOptionalParams, ): AsyncIterableIterator { for await (const page of this.listUsagePagingPage(location, options)) { yield* page; @@ -94,7 +94,7 @@ export class LocationImpl implements Location { */ public listCachedImages( location: string, - options?: LocationListCachedImagesOptionalParams + options?: LocationListCachedImagesOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listCachedImagesPagingAll(location, options); return { @@ -109,14 +109,14 @@ export class LocationImpl implements Location { throw new Error("maxPageSize is not supported by this operation."); } return this.listCachedImagesPagingPage(location, options, settings); - } + }, }; } private async *listCachedImagesPagingPage( location: string, options?: LocationListCachedImagesOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: LocationListCachedImagesResponse; let continuationToken = settings?.continuationToken; @@ -131,7 +131,7 @@ export class LocationImpl implements Location { result = await this._listCachedImagesNext( location, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -142,11 +142,11 @@ export class LocationImpl implements Location { private async *listCachedImagesPagingAll( location: string, - options?: LocationListCachedImagesOptionalParams + options?: LocationListCachedImagesOptionalParams, ): AsyncIterableIterator { for await (const page of this.listCachedImagesPagingPage( location, - options + options, )) { yield* page; } @@ -159,7 +159,7 @@ export class LocationImpl implements Location { */ public listCapabilities( location: string, - options?: LocationListCapabilitiesOptionalParams + options?: LocationListCapabilitiesOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listCapabilitiesPagingAll(location, options); return { @@ -174,14 +174,14 @@ export class LocationImpl implements Location { throw new Error("maxPageSize is not supported by this operation."); } return this.listCapabilitiesPagingPage(location, options, settings); - } + }, }; } private async *listCapabilitiesPagingPage( location: string, options?: LocationListCapabilitiesOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: LocationListCapabilitiesResponse; let continuationToken = settings?.continuationToken; @@ -196,7 +196,7 @@ export class LocationImpl implements Location { result = await this._listCapabilitiesNext( location, continuationToken, - options + options, ); continuationToken = result.nextLink; let page = result.value || []; @@ -207,11 +207,11 @@ export class LocationImpl implements Location { private async *listCapabilitiesPagingAll( location: string, - options?: LocationListCapabilitiesOptionalParams + options?: LocationListCapabilitiesOptionalParams, ): AsyncIterableIterator { for await (const page of this.listCapabilitiesPagingPage( location, - options + options, )) { yield* page; } @@ -224,11 +224,11 @@ export class LocationImpl implements Location { */ private _listUsage( location: string, - options?: LocationListUsageOptionalParams + options?: LocationListUsageOptionalParams, ): Promise { return this.client.sendOperationRequest( { location, options }, - listUsageOperationSpec + listUsageOperationSpec, ); } @@ -239,11 +239,11 @@ export class LocationImpl implements Location { */ private _listCachedImages( location: string, - options?: LocationListCachedImagesOptionalParams + options?: LocationListCachedImagesOptionalParams, ): Promise { return this.client.sendOperationRequest( { location, options }, - listCachedImagesOperationSpec + listCachedImagesOperationSpec, ); } @@ -254,11 +254,11 @@ export class LocationImpl implements Location { */ private _listCapabilities( location: string, - options?: LocationListCapabilitiesOptionalParams + options?: LocationListCapabilitiesOptionalParams, ): Promise { return this.client.sendOperationRequest( { location, options }, - listCapabilitiesOperationSpec + listCapabilitiesOperationSpec, ); } @@ -271,11 +271,11 @@ export class LocationImpl implements Location { private _listCachedImagesNext( location: string, nextLink: string, - options?: LocationListCachedImagesNextOptionalParams + options?: LocationListCachedImagesNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { location, nextLink, options }, - listCachedImagesNextOperationSpec + listCachedImagesNextOperationSpec, ); } @@ -288,11 +288,11 @@ export class LocationImpl implements Location { private _listCapabilitiesNext( location: string, nextLink: string, - options?: LocationListCapabilitiesNextOptionalParams + options?: LocationListCapabilitiesNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { location, nextLink, options }, - listCapabilitiesNextOperationSpec + listCapabilitiesNextOperationSpec, ); } } @@ -300,105 +300,102 @@ export class LocationImpl implements Location { const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const listUsageOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/usages", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/usages", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.UsageListResult + bodyMapper: Mappers.UsageListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.location + Parameters.location, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listCachedImagesOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/cachedImages", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/cachedImages", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.CachedImagesListResult + bodyMapper: Mappers.CachedImagesListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.location + Parameters.location, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listCapabilitiesOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/capabilities", + path: "/subscriptions/{subscriptionId}/providers/Microsoft.ContainerInstance/locations/{location}/capabilities", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.CapabilitiesListResult + bodyMapper: Mappers.CapabilitiesListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ Parameters.$host, Parameters.subscriptionId, - Parameters.location + Parameters.location, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listCachedImagesNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.CachedImagesListResult + bodyMapper: Mappers.CachedImagesListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.nextLink, - Parameters.location + Parameters.location, ], headerParameters: [Parameters.accept], - serializer + serializer, }; const listCapabilitiesNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.CapabilitiesListResult + bodyMapper: Mappers.CapabilitiesListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [ Parameters.$host, Parameters.subscriptionId, Parameters.nextLink, - Parameters.location + Parameters.location, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operations/operations.ts b/sdk/containerinstance/arm-containerinstance/src/operations/operations.ts index 1d79540446f0..c1b64ba7d3d3 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operations/operations.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operations/operations.ts @@ -18,7 +18,7 @@ import { OperationsListNextOptionalParams, OperationsListOptionalParams, OperationsListResponse, - OperationsListNextResponse + OperationsListNextResponse, } from "../models"; /// @@ -39,7 +39,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ public list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator { const iter = this.listPagingAll(options); return { @@ -54,13 +54,13 @@ export class OperationsImpl implements Operations { throw new Error("maxPageSize is not supported by this operation."); } return this.listPagingPage(options, settings); - } + }, }; } private async *listPagingPage( options?: OperationsListOptionalParams, - settings?: PageSettings + settings?: PageSettings, ): AsyncIterableIterator { let result: OperationsListResponse; let continuationToken = settings?.continuationToken; @@ -81,7 +81,7 @@ export class OperationsImpl implements Operations { } private async *listPagingAll( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): AsyncIterableIterator { for await (const page of this.listPagingPage(options)) { yield* page; @@ -93,7 +93,7 @@ export class OperationsImpl implements Operations { * @param options The options parameters. */ private _list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): Promise { return this.client.sendOperationRequest({ options }, listOperationSpec); } @@ -105,11 +105,11 @@ export class OperationsImpl implements Operations { */ private _listNext( nextLink: string, - options?: OperationsListNextOptionalParams + options?: OperationsListNextOptionalParams, ): Promise { return this.client.sendOperationRequest( { nextLink, options }, - listNextOperationSpec + listNextOperationSpec, ); } } @@ -121,29 +121,29 @@ const listOperationSpec: coreClient.OperationSpec = { httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [Parameters.$host], headerParameters: [Parameters.accept], - serializer + serializer, }; const listNextOperationSpec: coreClient.OperationSpec = { path: "{nextLink}", httpMethod: "GET", responses: { 200: { - bodyMapper: Mappers.OperationListResult + bodyMapper: Mappers.OperationListResult, }, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, urlParameters: [Parameters.$host, Parameters.nextLink], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operations/subnetServiceAssociationLink.ts b/sdk/containerinstance/arm-containerinstance/src/operations/subnetServiceAssociationLink.ts index 542674000148..c523dfd42d0d 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operations/subnetServiceAssociationLink.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operations/subnetServiceAssociationLink.ts @@ -14,14 +14,15 @@ import { ContainerInstanceManagementClient } from "../containerInstanceManagemen import { SimplePollerLike, OperationState, - createHttpPoller + createHttpPoller, } from "@azure/core-lro"; import { createLroSpec } from "../lroImpl"; import { SubnetServiceAssociationLinkDeleteOptionalParams } from "../models"; /** Class containing SubnetServiceAssociationLink operations. */ export class SubnetServiceAssociationLinkImpl - implements SubnetServiceAssociationLink { + implements SubnetServiceAssociationLink +{ private readonly client: ContainerInstanceManagementClient; /** @@ -44,25 +45,24 @@ export class SubnetServiceAssociationLinkImpl resourceGroupName: string, virtualNetworkName: string, subnetName: string, - options?: SubnetServiceAssociationLinkDeleteOptionalParams + options?: SubnetServiceAssociationLinkDeleteOptionalParams, ): Promise, void>> { const directSendOperation = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ): Promise => { return this.client.sendOperationRequest(args, spec); }; const sendOperationFn = async ( args: coreClient.OperationArguments, - spec: coreClient.OperationSpec + spec: coreClient.OperationSpec, ) => { - let currentRawResponse: - | coreClient.FullOperationResponse - | undefined = undefined; + let currentRawResponse: coreClient.FullOperationResponse | undefined = + undefined; const providedCallback = args.options?.onResponse; const callback: coreClient.RawResponseCallback = ( rawResponse: coreClient.FullOperationResponse, - flatResponse: unknown + flatResponse: unknown, ) => { currentRawResponse = rawResponse; providedCallback?.(rawResponse, flatResponse); @@ -71,8 +71,8 @@ export class SubnetServiceAssociationLinkImpl ...args, options: { ...args.options, - onResponse: callback - } + onResponse: callback, + }, }; const flatResponse = await directSendOperation(updatedArgs, spec); return { @@ -80,19 +80,19 @@ export class SubnetServiceAssociationLinkImpl rawResponse: { statusCode: currentRawResponse!.status, body: currentRawResponse!.parsedBody, - headers: currentRawResponse!.headers.toJSON() - } + headers: currentRawResponse!.headers.toJSON(), + }, }; }; const lro = createLroSpec({ sendOperationFn, args: { resourceGroupName, virtualNetworkName, subnetName, options }, - spec: deleteOperationSpec + spec: deleteOperationSpec, }); const poller = await createHttpPoller>(lro, { restoreFrom: options?.resumeFrom, - intervalInMs: options?.updateIntervalInMs + intervalInMs: options?.updateIntervalInMs, }); await poller.poll(); return poller; @@ -110,13 +110,13 @@ export class SubnetServiceAssociationLinkImpl resourceGroupName: string, virtualNetworkName: string, subnetName: string, - options?: SubnetServiceAssociationLinkDeleteOptionalParams + options?: SubnetServiceAssociationLinkDeleteOptionalParams, ): Promise { const poller = await this.beginDelete( resourceGroupName, virtualNetworkName, subnetName, - options + options, ); return poller.pollUntilDone(); } @@ -125,8 +125,7 @@ export class SubnetServiceAssociationLinkImpl const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const deleteOperationSpec: coreClient.OperationSpec = { - path: - "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{virtualNetworkName}/subnets/{subnetName}/providers/Microsoft.ContainerInstance/serviceAssociationLinks/default", + path: "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{virtualNetworkName}/subnets/{subnetName}/providers/Microsoft.ContainerInstance/serviceAssociationLinks/default", httpMethod: "DELETE", responses: { 200: {}, @@ -134,8 +133,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { 202: {}, 204: {}, default: { - bodyMapper: Mappers.CloudError - } + bodyMapper: Mappers.CloudError, + }, }, queryParameters: [Parameters.apiVersion], urlParameters: [ @@ -143,8 +142,8 @@ const deleteOperationSpec: coreClient.OperationSpec = { Parameters.subscriptionId, Parameters.resourceGroupName, Parameters.virtualNetworkName, - Parameters.subnetName + Parameters.subnetName, ], headerParameters: [Parameters.accept], - serializer + serializer, }; diff --git a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containerGroups.ts b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containerGroups.ts index 177bc1c29b77..5cf33ec47625 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containerGroups.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containerGroups.ts @@ -25,7 +25,7 @@ import { ContainerGroupsStopOptionalParams, ContainerGroupsStartOptionalParams, ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams, - ContainerGroupsGetOutboundNetworkDependenciesEndpointsResponse + ContainerGroupsGetOutboundNetworkDependenciesEndpointsResponse, } from "../models"; /// @@ -38,7 +38,7 @@ export interface ContainerGroups { * @param options The options parameters. */ list( - options?: ContainerGroupsListOptionalParams + options?: ContainerGroupsListOptionalParams, ): PagedAsyncIterableIterator; /** * Get a list of container groups in a specified subscription and resource group. This operation @@ -49,7 +49,7 @@ export interface ContainerGroups { */ listByResourceGroup( resourceGroupName: string, - options?: ContainerGroupsListByResourceGroupOptionalParams + options?: ContainerGroupsListByResourceGroupOptionalParams, ): PagedAsyncIterableIterator; /** * Gets the properties of the specified container group in the specified subscription and resource @@ -62,7 +62,7 @@ export interface ContainerGroups { get( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsGetOptionalParams + options?: ContainerGroupsGetOptionalParams, ): Promise; /** * Create or update container groups with specified configurations. @@ -75,7 +75,7 @@ export interface ContainerGroups { resourceGroupName: string, containerGroupName: string, containerGroup: ContainerGroup, - options?: ContainerGroupsCreateOrUpdateOptionalParams + options?: ContainerGroupsCreateOrUpdateOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -93,7 +93,7 @@ export interface ContainerGroups { resourceGroupName: string, containerGroupName: string, containerGroup: ContainerGroup, - options?: ContainerGroupsCreateOrUpdateOptionalParams + options?: ContainerGroupsCreateOrUpdateOptionalParams, ): Promise; /** * Updates container group tags with specified values. @@ -106,7 +106,7 @@ export interface ContainerGroups { resourceGroupName: string, containerGroupName: string, resource: Resource, - options?: ContainerGroupsUpdateOptionalParams + options?: ContainerGroupsUpdateOptionalParams, ): Promise; /** * Delete the specified container group in the specified subscription and resource group. The operation @@ -118,7 +118,7 @@ export interface ContainerGroups { beginDelete( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsDeleteOptionalParams + options?: ContainerGroupsDeleteOptionalParams, ): Promise< SimplePollerLike< OperationState, @@ -135,7 +135,7 @@ export interface ContainerGroups { beginDeleteAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsDeleteOptionalParams + options?: ContainerGroupsDeleteOptionalParams, ): Promise; /** * Restarts all containers in a container group in place. If container image has updates, new image @@ -147,7 +147,7 @@ export interface ContainerGroups { beginRestart( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsRestartOptionalParams + options?: ContainerGroupsRestartOptionalParams, ): Promise, void>>; /** * Restarts all containers in a container group in place. If container image has updates, new image @@ -159,7 +159,7 @@ export interface ContainerGroups { beginRestartAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsRestartOptionalParams + options?: ContainerGroupsRestartOptionalParams, ): Promise; /** * Stops all containers in a container group. Compute resources will be deallocated and billing will @@ -171,7 +171,7 @@ export interface ContainerGroups { stop( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStopOptionalParams + options?: ContainerGroupsStopOptionalParams, ): Promise; /** * Starts all containers in a container group. Compute resources will be allocated and billing will @@ -183,7 +183,7 @@ export interface ContainerGroups { beginStart( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStartOptionalParams + options?: ContainerGroupsStartOptionalParams, ): Promise, void>>; /** * Starts all containers in a container group. Compute resources will be allocated and billing will @@ -195,7 +195,7 @@ export interface ContainerGroups { beginStartAndWait( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsStartOptionalParams + options?: ContainerGroupsStartOptionalParams, ): Promise; /** * Gets all the network dependencies for this container group to allow complete control of network @@ -207,6 +207,6 @@ export interface ContainerGroups { getOutboundNetworkDependenciesEndpoints( resourceGroupName: string, containerGroupName: string, - options?: ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams + options?: ContainerGroupsGetOutboundNetworkDependenciesEndpointsOptionalParams, ): Promise; } diff --git a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containers.ts b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containers.ts index 2cbcfb2f5ffd..8f33aac8159e 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containers.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/containers.ts @@ -13,7 +13,7 @@ import { ContainersExecuteCommandOptionalParams, ContainersExecuteCommandResponse, ContainersAttachOptionalParams, - ContainersAttachResponse + ContainersAttachResponse, } from "../models"; /** Interface representing a Containers. */ @@ -29,7 +29,7 @@ export interface Containers { resourceGroupName: string, containerGroupName: string, containerName: string, - options?: ContainersListLogsOptionalParams + options?: ContainersListLogsOptionalParams, ): Promise; /** * Executes a command for a specific container instance in a specified resource group and container @@ -45,7 +45,7 @@ export interface Containers { containerGroupName: string, containerName: string, containerExecRequest: ContainerExecRequest, - options?: ContainersExecuteCommandOptionalParams + options?: ContainersExecuteCommandOptionalParams, ): Promise; /** * Attach to the output stream of a specific container instance in a specified resource group and @@ -59,6 +59,6 @@ export interface Containers { resourceGroupName: string, containerGroupName: string, containerName: string, - options?: ContainersAttachOptionalParams + options?: ContainersAttachOptionalParams, ): Promise; } diff --git a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/location.ts b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/location.ts index 4362abd9bbf2..b8bc20ed1513 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/location.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/location.ts @@ -13,7 +13,7 @@ import { CachedImages, LocationListCachedImagesOptionalParams, Capabilities, - LocationListCapabilitiesOptionalParams + LocationListCapabilitiesOptionalParams, } from "../models"; /// @@ -26,7 +26,7 @@ export interface Location { */ listUsage( location: string, - options?: LocationListUsageOptionalParams + options?: LocationListUsageOptionalParams, ): PagedAsyncIterableIterator; /** * Get the list of cached images on specific OS type for a subscription in a region. @@ -35,7 +35,7 @@ export interface Location { */ listCachedImages( location: string, - options?: LocationListCachedImagesOptionalParams + options?: LocationListCachedImagesOptionalParams, ): PagedAsyncIterableIterator; /** * Get the list of CPU/memory/GPU capabilities of a region. @@ -44,6 +44,6 @@ export interface Location { */ listCapabilities( location: string, - options?: LocationListCapabilitiesOptionalParams + options?: LocationListCapabilitiesOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/operations.ts b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/operations.ts index 4b15b5de461e..fd5065a90111 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/operations.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/operations.ts @@ -17,6 +17,6 @@ export interface Operations { * @param options The options parameters. */ list( - options?: OperationsListOptionalParams + options?: OperationsListOptionalParams, ): PagedAsyncIterableIterator; } diff --git a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/subnetServiceAssociationLink.ts b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/subnetServiceAssociationLink.ts index a7dbeffaf1ac..b0c241dd229c 100644 --- a/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/subnetServiceAssociationLink.ts +++ b/sdk/containerinstance/arm-containerinstance/src/operationsInterfaces/subnetServiceAssociationLink.ts @@ -23,7 +23,7 @@ export interface SubnetServiceAssociationLink { resourceGroupName: string, virtualNetworkName: string, subnetName: string, - options?: SubnetServiceAssociationLinkDeleteOptionalParams + options?: SubnetServiceAssociationLinkDeleteOptionalParams, ): Promise, void>>; /** * Delete container group virtual network association links. The operation does not delete other @@ -37,6 +37,6 @@ export interface SubnetServiceAssociationLink { resourceGroupName: string, virtualNetworkName: string, subnetName: string, - options?: SubnetServiceAssociationLinkDeleteOptionalParams + options?: SubnetServiceAssociationLinkDeleteOptionalParams, ): Promise; } diff --git a/sdk/containerinstance/arm-containerinstance/src/pagingHelper.ts b/sdk/containerinstance/arm-containerinstance/src/pagingHelper.ts index 269a2b9814b5..205cccc26592 100644 --- a/sdk/containerinstance/arm-containerinstance/src/pagingHelper.ts +++ b/sdk/containerinstance/arm-containerinstance/src/pagingHelper.ts @@ -28,7 +28,7 @@ export function getContinuationToken(page: unknown): string | undefined { export function setContinuationToken( page: unknown, - continuationToken: string | undefined + continuationToken: string | undefined, ): void { if (typeof page !== "object" || page === null || !continuationToken) { return; diff --git a/sdk/containerinstance/arm-containerinstance/test/sampleTest.ts b/sdk/containerinstance/arm-containerinstance/test/sampleTest.ts new file mode 100644 index 000000000000..d64be981b694 --- /dev/null +++ b/sdk/containerinstance/arm-containerinstance/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/containerinstance/arm-containerinstance/tsconfig.json b/sdk/containerinstance/arm-containerinstance/tsconfig.json index c28d6295827d..3e6ae96443f3 100644 --- a/sdk/containerinstance/arm-containerinstance/tsconfig.json +++ b/sdk/containerinstance/arm-containerinstance/tsconfig.json @@ -15,17 +15,11 @@ ], "declaration": true, "outDir": "./dist-esm", - "importHelpers": true, - "paths": { - "@azure/arm-containerinstance": [ - "./src/index" - ] - } + "importHelpers": true }, "include": [ "./src/**/*.ts", - "./test/**/*.ts", - "samples-dev/**/*.ts" + "./test/**/*.ts" ], "exclude": [ "node_modules"