ZiWei Chen 2024-11-19 19:14:05 +08:00 коммит произвёл GitHub
Родитель e6de8eef88
Коммит b9104016e8
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
170 изменённых файлов: 12013 добавлений и 1 удалений

3
.github/CODEOWNERS поставляемый
Просмотреть файл

@ -404,6 +404,9 @@ sdk/ai/ai-inference-rest @glharper @dargilco @jhakulin
# PRLabel: %Mgmt
/sdk/communication/arm-communication/ @qiaozha @MaryGao
# PRLabel: %Mgmt
/sdk/connectedcache/arm-connectedcache/ @qiaozha @MaryGao
# PRLabel: %Mgmt
/sdk/compute/arm-compute/ @qiaozha @MaryGao

Просмотреть файл

@ -197,6 +197,9 @@ dependencies:
'@rush-temp/arm-confluent':
specifier: file:./projects/arm-confluent.tgz
version: file:projects/arm-confluent.tgz
'@rush-temp/arm-connectedcache':
specifier: file:./projects/arm-connectedcache.tgz
version: file:projects/arm-connectedcache.tgz
'@rush-temp/arm-connectedvmware':
specifier: file:./projects/arm-connectedvmware.tgz
version: file:projects/arm-connectedvmware.tgz
@ -13882,6 +13885,43 @@ packages:
- supports-color
dev: false
file:projects/arm-connectedcache.tgz:
resolution: {integrity: sha512-z09VpU8HdMfm7XwTPPUYSVW3NaaMfTQwjVUggbtWe+xm7gPo5L3zB13SjvVaduyXorZg5roXzeT2At0W6Vkkqg==, tarball: file:projects/arm-connectedcache.tgz}
name: '@rush-temp/arm-connectedcache'
version: 0.0.0
dependencies:
'@microsoft/api-extractor': 7.47.11(@types/node@18.19.64)
'@types/node': 18.19.64
'@vitest/browser': 2.1.5(@types/node@18.19.64)(playwright@1.48.2)(typescript@5.6.3)(vitest@2.1.5)
'@vitest/coverage-istanbul': 2.1.5(vitest@2.1.5)
dotenv: 16.4.5
eslint: 8.57.1
playwright: 1.48.2
tshy: 2.0.1
tslib: 2.8.1
typescript: 5.6.3
vitest: 2.1.5(@types/node@18.19.64)(@vitest/browser@2.1.5)
transitivePeerDependencies:
- '@edge-runtime/vm'
- '@vitest/ui'
- bufferutil
- happy-dom
- jsdom
- less
- lightningcss
- msw
- safaridriver
- sass
- sass-embedded
- stylus
- sugarss
- supports-color
- terser
- utf-8-validate
- vite
- webdriverio
dev: false
file:projects/arm-connectedvmware.tgz:
resolution: {integrity: sha512-vhQ7ZhjOJ0BmjhBsyAvkQLyF9VgXGOcW83y+4X2y03VpkYuTF4nh/lREFr87lhx6j9IGAZHVMoLNIzwMiqpMTg==, tarball: file:projects/arm-connectedvmware.tgz}
name: '@rush-temp/arm-connectedvmware'
@ -21769,7 +21809,7 @@ packages:
dev: false
file:projects/maps-route.tgz:
resolution: {integrity: sha512-0ctRSAumdIjIYk2gsJWzoER0exI6GI4XYhIcuVJH1xNf19LCLOw0erfKvdgYnMscP447hOavv+t1DHahw6yUsw==, tarball: file:projects/maps-route.tgz}
resolution: {integrity: sha512-7CIlx59lH1iXpkFOrf1zQ6r986jREdZS9F+cKejJPIrbqqj0e9uO5Po1q9aUwQgEkQFlh8wQ55GrK36jhQG5jQ==, tarball: file:projects/maps-route.tgz}
name: '@rush-temp/maps-route'
version: 0.0.0
dependencies:

Просмотреть файл

@ -13,3 +13,4 @@ https://docs.microsoft.com/javascript/api/@azure/arm-trustedsigning?view=azure-n
https://docs.microsoft.com/javascript/api/@azure/arm-containerorchestratorruntime?view=azure-node-preview
https://docs.microsoft.com/javascript/api/@azure/arm-iotoperations?view=azure-node-preview
https://docs.microsoft.com/javascript/api/@azure/arm-databoundaries?view=azure-node-preview
https://docs.microsoft.com/javascript/api/@azure/arm-connectedcache?view=azure-node-preview

Просмотреть файл

@ -2306,6 +2306,11 @@
"packageName": "@azure/arm-containerorchestratorruntime",
"projectFolder": "sdk/kubernetesruntime/arm-containerorchestratorruntime",
"versionPolicyName": "management"
},
{
"packageName": "@azure/arm-connectedcache",
"projectFolder": "sdk/connectedcache/arm-connectedcache",
"versionPolicyName": "management"
}
]
}

Просмотреть файл

@ -0,0 +1,7 @@
# Release History
## 1.0.0-beta.1 (2024-11-19)
### Features Added
Initial release of the Azure ConnectedCache package

Просмотреть файл

@ -0,0 +1,21 @@
The MIT License (MIT)
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
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Просмотреть файл

@ -0,0 +1,102 @@
# Azure ConnectedCache client library for JavaScript
This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Azure ConnectedCache client.
Microsoft Connected Cache Rest Api version 2023-05-01-preview
Key links:
- [Package (NPM)](https://www.npmjs.com/package/@azure/arm-connectedcache)
- [API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-connectedcache?view=azure-node-preview)
## Getting started
### Currently supported environments
- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule)
- Latest versions of Safari, Chrome, Edge and Firefox.
See our [support policy](https://github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more details.
### Prerequisites
- An [Azure subscription][azure_sub].
### Install the `@azure/arm-connectedcache` package
Install the Azure ConnectedCache client library for JavaScript with `npm`:
```bash
npm install @azure/arm-connectedcache
```
### Create and authenticate a `ConnectedCacheClient`
To create a client object to access the Azure ConnectedCache API, you will need the `endpoint` of your Azure ConnectedCache resource and a `credential`. The Azure ConnectedCache client can use Azure Active Directory credentials to authenticate.
You can find the endpoint for your Azure ConnectedCache resource in the [Azure Portal][azure_portal].
You can authenticate with Azure Active Directory using a credential from the [@azure/identity][azure_identity] library or [an existing AAD Token](https://github.com/Azure/azure-sdk-for-js/blob/master/sdk/identity/identity/samples/AzureIdentityExamples.md#authenticating-with-a-pre-fetched-access-token).
To use the [DefaultAzureCredential][defaultazurecredential] provider shown below, or other credential providers provided with the Azure SDK, please install the `@azure/identity` package:
```bash
npm install @azure/identity
```
You will also need to **register a new AAD application and grant access to Azure ConnectedCache** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions).
Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`.
For more information about how to create an Azure AD Application check out [this guide](https://docs.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal).
```javascript
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
// For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details.
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new ConnectedCacheClient(new DefaultAzureCredential(), subscriptionId);
// For client-side applications running in the browser, use this code instead:
// const credential = new InteractiveBrowserCredential({
// tenantId: "<YOUR_TENANT_ID>",
// clientId: "<YOUR_CLIENT_ID>"
// });
// const client = new ConnectedCacheClient(credential, subscriptionId);
```
### JavaScript Bundle
To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling).
## Key concepts
### ConnectedCacheClient
`ConnectedCacheClient` is the primary interface for developers using the Azure ConnectedCache client library. Explore the methods on this client object to understand the different features of the Azure ConnectedCache service that you can access.
## Troubleshooting
### Logging
Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`:
```javascript
const { setLogLevel } = require("@azure/logger");
setLogLevel("info");
```
For more detailed instructions on how to enable logs, you can look at the [@azure/logger package docs](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/logger).
## Contributing
If you'd like to contribute to this library, please read the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/main/CONTRIBUTING.md) to learn more about how to build and test the code.
## Related projects
- [Microsoft Azure SDK for JavaScript](https://github.com/Azure/azure-sdk-for-js)
[azure_sub]: https://azure.microsoft.com/free/
[azure_portal]: https://portal.azure.com
[azure_identity]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity
[defaultazurecredential]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/identity/identity#defaultazurecredential

Просмотреть файл

@ -0,0 +1,18 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
"mainEntryPointFilePath": "./dist/esm/index.d.ts",
"docModel": { "enabled": true },
"apiReport": { "enabled": true, "reportFolder": "./review" },
"dtsRollup": {
"enabled": true,
"untrimmedFilePath": "",
"publicTrimmedFilePath": "./types/arm-connectedcache.d.ts"
},
"messages": {
"tsdocMessageReporting": { "default": { "logLevel": "none" } },
"extractorMessageReporting": {
"ae-missing-release-tag": { "logLevel": "none" },
"ae-unresolved-link": { "logLevel": "none" }
}
}
}

Просмотреть файл

@ -0,0 +1,6 @@
{
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "js",
"TagPrefix": "js/connectedcache/arm-connectedcache",
"Tag": "js/connectedcache/arm-connectedcache_c716744a2d"
}

Просмотреть файл

@ -0,0 +1,17 @@
import azsdkEslint from "@azure/eslint-plugin-azure-sdk";
export default [
...azsdkEslint.configs.recommended,
{
rules: {
"@azure/azure-sdk/ts-modules-only-named": "warn",
"@azure/azure-sdk/ts-apiextractor-json-types": "warn",
"@azure/azure-sdk/ts-package-json-types": "warn",
"@azure/azure-sdk/ts-package-json-engine-is-present": "warn",
"@azure/azure-sdk/ts-package-json-module": "off",
"@azure/azure-sdk/ts-package-json-files-required": "off",
"@azure/azure-sdk/ts-package-json-main-is-cjs": "off",
"tsdoc/syntax": "warn",
},
},
];

Просмотреть файл

@ -0,0 +1,160 @@
{
"name": "@azure/arm-connectedcache",
"version": "1.0.0-beta.1",
"description": "A generated SDK for ConnectedCacheClient.",
"engines": {
"node": ">=18.0.0"
},
"sideEffects": false,
"autoPublish": false,
"tshy": {
"exports": {
"./package.json": "./package.json",
".": "./src/index.ts",
"./models": "./src/models/index.ts"
},
"dialects": [
"esm",
"commonjs"
],
"esmDialects": [
"browser",
"react-native"
],
"selfLink": false
},
"type": "module",
"keywords": [
"node",
"azure",
"cloud",
"typescript",
"browser",
"isomorphic"
],
"author": "Microsoft Corporation",
"license": "MIT",
"files": [
"dist",
"README.md",
"LICENSE",
"review/*",
"CHANGELOG.md"
],
"sdk-type": "mgmt",
"repository": "github:Azure/azure-sdk-for-js",
"bugs": {
"url": "https://github.com/Azure/azure-sdk-for-js/issues"
},
"prettier": "@azure/eslint-plugin-azure-sdk/prettier.json",
"//metadata": {
"constantPaths": [
{
"path": "src/api/connectedCacheContext.ts",
"prefix": "userAgentInfo"
}
]
},
"dependencies": {
"@azure/core-util": "^1.9.2",
"@azure-rest/core-client": "^2.3.1",
"@azure/core-auth": "^1.6.0",
"@azure/core-rest-pipeline": "^1.5.0",
"@azure/logger": "^1.0.0",
"tslib": "^2.6.2",
"@azure/core-lro": "^3.1.0",
"@azure/abort-controller": "^2.1.2"
},
"devDependencies": {
"dotenv": "^16.0.0",
"@microsoft/api-extractor": "^7.40.3",
"@types/node": "^18.0.0",
"eslint": "^8.55.0",
"typescript": "~5.6.2",
"tshy": "^2.0.0",
"@azure/identity": "^4.2.1",
"@vitest/browser": "^2.0.5",
"@vitest/coverage-istanbul": "^2.0.5",
"playwright": "^1.41.2",
"vitest": "^2.0.5",
"@azure-tools/test-credential": "^2.0.0",
"@azure-tools/test-recorder": "^4.0.0",
"@azure/dev-tool": "^1.0.0",
"@azure/eslint-plugin-azure-sdk": "^3.0.0"
},
"scripts": {
"clean": "dev-tool run vendored rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log",
"extract-api": "dev-tool run vendored rimraf review && dev-tool run vendored mkdirp ./review && dev-tool run extract-api",
"pack": "npm pack 2>&1",
"lint": "echo skipped",
"lint:fix": "echo skipped",
"unit-test": "npm run unit-test:node && npm run unit-test:browser",
"unit-test:browser": "npm run build:test && dev-tool run test:vitest --browser",
"unit-test:node": "dev-tool run test:vitest",
"integration-test": "npm run integration-test:node && npm run integration-test:browser",
"integration-test:browser": "echo skipped",
"integration-test:node": "echo skipped",
"build:samples": "dev-tool run typecheck --paths samples-dev/*.ts && dev-tool samples publish -f",
"check-format": "dev-tool run vendored prettier --list-different --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.{ts,cts,mts}\" \"test/**/*.{ts,cts,mts}\" \"*.{js,cjs,mjs,json}\" \"samples-dev/*.ts\"",
"execute:samples": "dev-tool samples run samples-dev",
"format": "dev-tool run vendored prettier --write --config ../../../.prettierrc.json --ignore-path ../../../.prettierignore \"src/**/*.{ts,cts,mts}\" \"test/**/*.{ts,cts,mts}\" \"*.{js,cjs,mjs,json}\" \"samples-dev/*.ts\"",
"generate:client": "echo skipped",
"test:browser": "npm run clean && npm run build:test && npm run unit-test:browser && npm run integration-test:browser",
"minify": "dev-tool run vendored uglifyjs -c -m --comments --source-map \"content='./dist/index.js.map'\" -o ./dist/index.min.js ./dist/index.js",
"build:test": "npm run clean && dev-tool run build-package && dev-tool run build-test",
"build": "npm run clean && dev-tool run build-package && dev-tool run vendored mkdirp ./review && dev-tool run extract-api",
"test:node": "npm run clean && dev-tool run build-package && npm run unit-test:node && npm run integration-test:node",
"test": "npm run clean && dev-tool run build-package && npm run unit-test:node && dev-tool run bundle && npm run unit-test:browser && npm run integration-test",
"update-snippets": "echo skipped"
},
"//sampleConfiguration": {
"productName": "@azure/arm-connectedcache",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-connectedcache?view=azure-node-preview"
},
"exports": {
"./package.json": "./package.json",
".": {
"browser": {
"types": "./dist/browser/index.d.ts",
"default": "./dist/browser/index.js"
},
"react-native": {
"types": "./dist/react-native/index.d.ts",
"default": "./dist/react-native/index.js"
},
"import": {
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
"require": {
"types": "./dist/commonjs/index.d.ts",
"default": "./dist/commonjs/index.js"
}
},
"./models": {
"browser": {
"types": "./dist/browser/models/index.d.ts",
"default": "./dist/browser/models/index.js"
},
"react-native": {
"types": "./dist/react-native/models/index.d.ts",
"default": "./dist/react-native/models/index.js"
},
"import": {
"types": "./dist/esm/models/index.d.ts",
"default": "./dist/esm/models/index.js"
},
"require": {
"types": "./dist/commonjs/models/index.d.ts",
"default": "./dist/commonjs/models/index.js"
}
}
},
"main": "./dist/commonjs/index.js",
"types": "./dist/commonjs/index.d.ts",
"module": "./dist/esm/index.js"
}

Просмотреть файл

@ -0,0 +1,441 @@
## API Report File for "@azure/arm-connectedcache"
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts
// @public
export type ActionType = string;
// @public
export interface AdditionalCacheNodeProperties {
readonly aggregatedStatusCode?: number;
readonly aggregatedStatusDetails?: string;
readonly aggregatedStatusText?: string;
readonly autoUpdateAppliedVersion?: string;
readonly autoUpdateLastAppliedDateTime?: Date;
readonly autoUpdateLastAppliedDetails?: string;
readonly autoUpdateLastAppliedState?: string;
readonly autoUpdateLastTriggeredDateTime?: Date;
readonly autoUpdateNextAvailableDateTime?: Date;
readonly autoUpdateNextAvailableVersion?: string;
autoUpdateVersion?: string;
bgpConfiguration?: BgpConfiguration;
cacheNodePropertiesDetailsIssuesList?: string[];
readonly cacheNodeState?: number;
readonly cacheNodeStateDetailedText?: string;
readonly cacheNodeStateShortText?: string;
driveConfiguration?: CacheNodeDriveConfiguration[];
readonly isProvisioned?: boolean;
isProxyRequired?: ProxyRequired;
optionalProperty1?: string;
optionalProperty2?: string;
optionalProperty3?: string;
optionalProperty4?: string;
optionalProperty5?: string;
osType?: OsType;
readonly productVersion?: string;
proxyUrl?: string;
proxyUrlConfiguration?: ProxyUrlConfiguration;
updateCycleType?: CycleType;
updateInfoDetails?: string;
updateRequestedDateTime?: Date;
}
// @public
export interface AdditionalCustomerProperties {
customerAsn?: string;
readonly customerAsnEstimatedEgressPeekGbps?: number;
customerEmail?: string;
customerEntitlementExpiration?: Date;
customerEntitlementSkuGuid?: string;
customerEntitlementSkuId?: string;
customerEntitlementSkuName?: string;
readonly customerOrgName?: string;
readonly customerPropertiesOverviewAverageEgressMbps?: number;
readonly customerPropertiesOverviewAverageMissMbps?: number;
readonly customerPropertiesOverviewCacheEfficiency?: number;
readonly customerPropertiesOverviewCacheNodesHealthyCount?: number;
readonly customerPropertiesOverviewCacheNodesUnhealthyCount?: number;
readonly customerPropertiesOverviewEgressMbpsMax?: number;
readonly customerPropertiesOverviewEgressMbpsMaxDateTime?: Date;
readonly customerPropertiesOverviewMissMbpsMax?: number;
readonly customerPropertiesOverviewMissMbpsMaxDateTime?: Date;
customerTransitAsn?: string;
customerTransitState?: CustomerTransitState;
optionalProperty1?: string;
optionalProperty2?: string;
optionalProperty3?: string;
optionalProperty4?: string;
optionalProperty5?: string;
readonly peeringDbLastUpdateDate?: Date;
readonly peeringDbLastUpdateTime?: Date;
readonly signupPhaseStatusCode?: number;
readonly signupPhaseStatusText?: string;
readonly signupStatus?: boolean;
readonly signupStatusCode?: number;
readonly signupStatusText?: string;
}
// @public
export type AutoUpdateRingType = string;
// @public
export interface BgpCidrsConfiguration {
readonly bgpCidrs?: string[];
}
// @public
export interface BgpConfiguration {
asnToIpAddressMapping?: string;
}
// @public
export type BgpReviewStateEnum = string;
// @public
export interface CacheNodeDriveConfiguration {
cacheNumber?: number;
nginxMapping?: string;
physicalPath?: string;
sizeInGb?: number;
}
// @public
export interface CacheNodeEntity {
readonly addressSpace?: number;
autoUpdateRequestedDay?: number;
autoUpdateRequestedTime?: string;
autoUpdateRequestedWeek?: number;
autoUpdateRingType?: AutoUpdateRingType;
readonly bgpAddressSpace?: number;
readonly bgpCidrBlocksCount?: number;
readonly bgpCidrCsvLastUpdateTime?: Date;
readonly bgpFileBytesTruncated?: number;
readonly bgpLastReportedTime?: Date;
readonly bgpNumberOfRecords?: number;
readonly bgpNumberOfTimesUpdated?: number;
readonly bgpReviewFeedback?: string;
readonly bgpReviewState?: BgpReviewStateEnum;
readonly bgpReviewStateText?: string;
cacheNodeId?: string;
cacheNodeName?: string;
readonly category?: string;
cidrCsv?: string[];
readonly cidrCsvLastUpdateTime?: Date;
cidrSelectionType?: number;
readonly clientTenantId?: string;
readonly configurationState?: ConfigurationState;
readonly configurationStateText?: string;
readonly containerConfigurations?: string;
readonly containerResyncTrigger?: number;
readonly createAsyncOperationId?: string;
customerAsn?: number;
readonly customerId?: string;
customerIndex?: string;
customerName?: string;
readonly deleteAsyncOperationId?: string;
fullyQualifiedDomainName?: string;
fullyQualifiedResourceId?: string;
readonly imageUri?: string;
ipAddress?: string;
isEnabled?: boolean;
isEnterpriseManaged?: boolean;
readonly isFrozen?: boolean;
readonly lastSyncWithAzureTimestamp?: Date;
readonly lastUpdatedTimestamp?: Date;
maxAllowableEgressInMbps?: number;
readonly maxAllowableProbability?: number;
readonly releaseVersion?: number;
readonly reviewFeedback?: string;
readonly reviewState?: number;
readonly reviewStateText?: string;
shouldMigrate?: boolean;
readonly synchWithAzureAttemptsCount?: number;
readonly workerConnections?: number;
readonly workerConnectionsLastUpdatedDateTime?: Date;
readonly xCid?: string;
}
// @public
export interface CacheNodeInstallProperties {
cacheNodeId?: string;
customerId?: string;
readonly primaryAccountKey?: string;
readonly registrationKey?: string;
readonly secondaryAccountKey?: string;
}
// @public
export interface CacheNodeOldResponse {
error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
statusCode?: string;
statusDetails?: string;
statusText?: string;
}
// @public
export interface CacheNodePreviewResource extends TrackedResource {
properties?: CacheNodeOldResponse;
}
// @public
export interface CacheNodeProperty {
additionalCacheNodeProperties?: AdditionalCacheNodeProperties;
cacheNode?: CacheNodeEntity;
error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
statusCode?: string;
statusDetails?: string;
statusText?: string;
}
// @public
export type ConfigurationState = string;
// @public
export interface ConnectedCachePatchResource {
tags?: Record<string, string>;
}
// @public
export type CreatedByType = string;
// @public
export interface CustomerEntity {
clientTenantId?: string;
contactEmail?: string;
contactName?: string;
contactPhone?: string;
readonly createAsyncOperationId?: string;
readonly customerId?: string;
customerName?: string;
readonly deleteAsyncOperationId?: string;
fullyQualifiedResourceId?: string;
isEnterpriseManaged?: boolean;
isEntitled?: boolean;
readonly lastSyncWithAzureTimestamp?: Date;
releaseVersion?: number;
resendSignupCode?: boolean;
shouldMigrate?: boolean;
readonly synchWithAzureAttemptsCount?: number;
verifySignupCode?: boolean;
verifySignupPhrase?: string;
}
// @public
export interface CustomerProperty {
additionalCustomerProperties?: AdditionalCustomerProperties;
customer?: CustomerEntity;
readonly error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
readonly statusCode?: string;
readonly statusDetails?: string;
readonly statusText?: string;
}
// @public
export type CustomerTransitState = string;
// @public
export type CycleType = string;
// @public
export interface EnterpriseMccCacheNodeResource extends TrackedResource {
properties?: CacheNodeProperty;
}
// @public
export interface EnterpriseMccCustomerResource extends TrackedResource {
properties?: CustomerProperty;
}
// @public
export interface EnterprisePreviewResource extends TrackedResource {
properties?: CacheNodeOldResponse;
}
// @public
export interface ErrorAdditionalInfo {
readonly info?: Record<string, any>;
readonly type?: string;
}
// @public
export interface ErrorDetail {
readonly additionalInfo?: ErrorAdditionalInfo[];
readonly code?: string;
readonly details?: ErrorDetail[];
readonly message?: string;
readonly target?: string;
}
// @public
export interface IspCacheNodeResource extends TrackedResource {
properties?: CacheNodeProperty;
}
// @public
export interface IspCustomerResource extends TrackedResource {
properties?: CustomerProperty;
}
// @public
export enum KnownActionType {
Internal = "Internal"
}
// @public
export enum KnownAutoUpdateRingType {
Fast = "Fast",
Preview = "Preview",
Slow = "Slow"
}
// @public
export enum KnownBgpReviewStateEnum {
Approved = "Approved",
AttentionRequired = "AttentionRequired",
InReview = "InReview",
NotConfigured = "NotConfigured"
}
// @public
export enum KnownConfigurationState {
Configured = "Configured",
NotConfigured_Ip = "NotConfigured_Ip"
}
// @public
export enum KnownCreatedByType {
Application = "Application",
Key = "Key",
ManagedIdentity = "ManagedIdentity",
User = "User"
}
// @public
export enum KnownCustomerTransitState {
CombinedTransit = "CombinedTransit",
NoTransit = "NoTransit",
TransitOnly = "TransitOnly"
}
// @public
export enum KnownCycleType {
Fast = "Fast",
Preview = "Preview",
Slow = "Slow"
}
// @public
export enum KnownOrigin {
System = "system",
User = "user",
UserSystem = "user,system"
}
// @public
export enum KnownOsType {
Eflow = "Eflow",
Linux = "Linux",
Windows = "Windows"
}
// @public
export enum KnownProvisioningState {
Accepted = "Accepted",
Canceled = "Canceled",
Deleting = "Deleting",
Failed = "Failed",
Succeeded = "Succeeded",
Unknown = "Unknown",
Upgrading = "Upgrading"
}
// @public
export enum KnownProxyRequired {
None = "None",
Required = "Required"
}
// @public
export enum KnownVersions {
v2023_05_01_preview = "2023-05-01-preview"
}
// @public
export interface MccCacheNodeBgpCidrDetails extends TrackedResource {
properties?: BgpCidrsConfiguration;
}
// @public
export interface MccCacheNodeInstallDetails extends TrackedResource {
properties?: CacheNodeInstallProperties;
}
// @public
export interface Operation {
actionType?: ActionType;
readonly display?: OperationDisplay;
readonly isDataAction?: boolean;
readonly name?: string;
readonly origin?: Origin;
}
// @public
export interface OperationDisplay {
readonly description?: string;
readonly operation?: string;
readonly provider?: string;
readonly resource?: string;
}
// @public
export type Origin = string;
// @public
export type OsType = string;
// @public
export type ProvisioningState = string;
// @public
export type ProxyRequired = string;
// @public
export interface ProxyUrlConfiguration {
proxyUrl?: string;
}
// @public
export interface Resource {
readonly id?: string;
readonly name?: string;
readonly systemData?: SystemData;
readonly type?: string;
}
// @public
export interface SystemData {
createdAt?: Date;
createdBy?: string;
createdByType?: CreatedByType;
lastModifiedAt?: Date;
lastModifiedBy?: string;
lastModifiedByType?: CreatedByType;
}
// @public
export interface TrackedResource extends Resource {
location: string;
tags?: Record<string, string>;
}
// (No @packageDocumentation comment for this package)
```

Просмотреть файл

@ -0,0 +1,723 @@
## API Report File for "@azure/arm-connectedcache"
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts
import { AbortSignalLike } from '@azure/abort-controller';
import { ClientOptions } from '@azure-rest/core-client';
import { OperationOptions } from '@azure-rest/core-client';
import { OperationState } from '@azure/core-lro';
import { PathUncheckedResponse } from '@azure-rest/core-client';
import { Pipeline } from '@azure/core-rest-pipeline';
import { PollerLike } from '@azure/core-lro';
import { TokenCredential } from '@azure/core-auth';
// @public
export type ActionType = string;
// @public
export interface AdditionalCacheNodeProperties {
readonly aggregatedStatusCode?: number;
readonly aggregatedStatusDetails?: string;
readonly aggregatedStatusText?: string;
readonly autoUpdateAppliedVersion?: string;
readonly autoUpdateLastAppliedDateTime?: Date;
readonly autoUpdateLastAppliedDetails?: string;
readonly autoUpdateLastAppliedState?: string;
readonly autoUpdateLastTriggeredDateTime?: Date;
readonly autoUpdateNextAvailableDateTime?: Date;
readonly autoUpdateNextAvailableVersion?: string;
autoUpdateVersion?: string;
bgpConfiguration?: BgpConfiguration;
cacheNodePropertiesDetailsIssuesList?: string[];
readonly cacheNodeState?: number;
readonly cacheNodeStateDetailedText?: string;
readonly cacheNodeStateShortText?: string;
driveConfiguration?: CacheNodeDriveConfiguration[];
readonly isProvisioned?: boolean;
isProxyRequired?: ProxyRequired;
optionalProperty1?: string;
optionalProperty2?: string;
optionalProperty3?: string;
optionalProperty4?: string;
optionalProperty5?: string;
osType?: OsType;
readonly productVersion?: string;
proxyUrl?: string;
proxyUrlConfiguration?: ProxyUrlConfiguration;
updateCycleType?: CycleType;
updateInfoDetails?: string;
updateRequestedDateTime?: Date;
}
// @public
export interface AdditionalCustomerProperties {
customerAsn?: string;
readonly customerAsnEstimatedEgressPeekGbps?: number;
customerEmail?: string;
customerEntitlementExpiration?: Date;
customerEntitlementSkuGuid?: string;
customerEntitlementSkuId?: string;
customerEntitlementSkuName?: string;
readonly customerOrgName?: string;
readonly customerPropertiesOverviewAverageEgressMbps?: number;
readonly customerPropertiesOverviewAverageMissMbps?: number;
readonly customerPropertiesOverviewCacheEfficiency?: number;
readonly customerPropertiesOverviewCacheNodesHealthyCount?: number;
readonly customerPropertiesOverviewCacheNodesUnhealthyCount?: number;
readonly customerPropertiesOverviewEgressMbpsMax?: number;
readonly customerPropertiesOverviewEgressMbpsMaxDateTime?: Date;
readonly customerPropertiesOverviewMissMbpsMax?: number;
readonly customerPropertiesOverviewMissMbpsMaxDateTime?: Date;
customerTransitAsn?: string;
customerTransitState?: CustomerTransitState;
optionalProperty1?: string;
optionalProperty2?: string;
optionalProperty3?: string;
optionalProperty4?: string;
optionalProperty5?: string;
readonly peeringDbLastUpdateDate?: Date;
readonly peeringDbLastUpdateTime?: Date;
readonly signupPhaseStatusCode?: number;
readonly signupPhaseStatusText?: string;
readonly signupStatus?: boolean;
readonly signupStatusCode?: number;
readonly signupStatusText?: string;
}
// @public
export type AutoUpdateRingType = string;
// @public
export interface BgpCidrsConfiguration {
readonly bgpCidrs?: string[];
}
// @public
export interface BgpConfiguration {
asnToIpAddressMapping?: string;
}
// @public
export type BgpReviewStateEnum = string;
// @public
export interface CacheNodeDriveConfiguration {
cacheNumber?: number;
nginxMapping?: string;
physicalPath?: string;
sizeInGb?: number;
}
// @public
export interface CacheNodeEntity {
readonly addressSpace?: number;
autoUpdateRequestedDay?: number;
autoUpdateRequestedTime?: string;
autoUpdateRequestedWeek?: number;
autoUpdateRingType?: AutoUpdateRingType;
readonly bgpAddressSpace?: number;
readonly bgpCidrBlocksCount?: number;
readonly bgpCidrCsvLastUpdateTime?: Date;
readonly bgpFileBytesTruncated?: number;
readonly bgpLastReportedTime?: Date;
readonly bgpNumberOfRecords?: number;
readonly bgpNumberOfTimesUpdated?: number;
readonly bgpReviewFeedback?: string;
readonly bgpReviewState?: BgpReviewStateEnum;
readonly bgpReviewStateText?: string;
cacheNodeId?: string;
cacheNodeName?: string;
readonly category?: string;
cidrCsv?: string[];
readonly cidrCsvLastUpdateTime?: Date;
cidrSelectionType?: number;
readonly clientTenantId?: string;
readonly configurationState?: ConfigurationState;
readonly configurationStateText?: string;
readonly containerConfigurations?: string;
readonly containerResyncTrigger?: number;
readonly createAsyncOperationId?: string;
customerAsn?: number;
readonly customerId?: string;
customerIndex?: string;
customerName?: string;
readonly deleteAsyncOperationId?: string;
fullyQualifiedDomainName?: string;
fullyQualifiedResourceId?: string;
readonly imageUri?: string;
ipAddress?: string;
isEnabled?: boolean;
isEnterpriseManaged?: boolean;
readonly isFrozen?: boolean;
readonly lastSyncWithAzureTimestamp?: Date;
readonly lastUpdatedTimestamp?: Date;
maxAllowableEgressInMbps?: number;
readonly maxAllowableProbability?: number;
readonly releaseVersion?: number;
readonly reviewFeedback?: string;
readonly reviewState?: number;
readonly reviewStateText?: string;
shouldMigrate?: boolean;
readonly synchWithAzureAttemptsCount?: number;
readonly workerConnections?: number;
readonly workerConnectionsLastUpdatedDateTime?: Date;
readonly xCid?: string;
}
// @public
export interface CacheNodeInstallProperties {
cacheNodeId?: string;
customerId?: string;
readonly primaryAccountKey?: string;
readonly registrationKey?: string;
readonly secondaryAccountKey?: string;
}
// @public
export interface CacheNodeOldResponse {
error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
statusCode?: string;
statusDetails?: string;
statusText?: string;
}
// @public
export interface CacheNodePreviewResource extends TrackedResource {
properties?: CacheNodeOldResponse;
}
// @public
export interface CacheNodeProperty {
additionalCacheNodeProperties?: AdditionalCacheNodeProperties;
cacheNode?: CacheNodeEntity;
error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
statusCode?: string;
statusDetails?: string;
statusText?: string;
}
// @public
export interface CacheNodesOperationsCreateorUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface CacheNodesOperationsDeleteOptionalParams extends OperationOptions {
}
// @public
export interface CacheNodesOperationsGetOptionalParams extends OperationOptions {
}
// @public
export interface CacheNodesOperationsListByResourceGroupOptionalParams extends OperationOptions {
}
// @public
export interface CacheNodesOperationsListBySubscriptionOptionalParams extends OperationOptions {
}
// @public
export interface CacheNodesOperationsOperations {
createorUpdate: (resourceGroupName: string, customerResourceName: string, resource: CacheNodePreviewResource, options?: CacheNodesOperationsCreateorUpdateOptionalParams) => PollerLike<OperationState<CacheNodePreviewResource>, CacheNodePreviewResource>;
delete: (resourceGroupName: string, customerResourceName: string, options?: CacheNodesOperationsDeleteOptionalParams) => Promise<void>;
get: (resourceGroupName: string, customerResourceName: string, options?: CacheNodesOperationsGetOptionalParams) => Promise<CacheNodePreviewResource>;
listByResourceGroup: (resourceGroupName: string, options?: CacheNodesOperationsListByResourceGroupOptionalParams) => PagedAsyncIterableIterator<CacheNodePreviewResource>;
listBySubscription: (options?: CacheNodesOperationsListBySubscriptionOptionalParams) => PagedAsyncIterableIterator<CacheNodePreviewResource>;
update: (resourceGroupName: string, customerResourceName: string, properties: ConnectedCachePatchResource, options?: CacheNodesOperationsUpdateOptionalParams) => Promise<CacheNodePreviewResource>;
}
// @public
export interface CacheNodesOperationsUpdateOptionalParams extends OperationOptions {
}
// @public
export type ConfigurationState = string;
// @public (undocumented)
export class ConnectedCacheClient {
constructor(credential: TokenCredential, subscriptionId: string, options?: ConnectedCacheClientOptionalParams);
readonly cacheNodesOperations: CacheNodesOperationsOperations;
readonly enterpriseCustomerOperations: EnterpriseCustomerOperationsOperations;
readonly enterpriseMccCacheNodesOperations: EnterpriseMccCacheNodesOperationsOperations;
readonly enterpriseMccCustomers: EnterpriseMccCustomersOperations;
readonly ispCacheNodesOperations: IspCacheNodesOperationsOperations;
readonly ispCustomers: IspCustomersOperations;
readonly operations: OperationsOperations;
readonly pipeline: Pipeline;
}
// @public
export interface ConnectedCacheClientOptionalParams extends ClientOptions {
apiVersion?: string;
}
// @public
export interface ConnectedCachePatchResource {
tags?: Record<string, string>;
}
// @public
export type ContinuablePage<TElement, TPage = TElement[]> = TPage & {
continuationToken?: string;
};
// @public
export type CreatedByType = string;
// @public
export interface CustomerEntity {
clientTenantId?: string;
contactEmail?: string;
contactName?: string;
contactPhone?: string;
readonly createAsyncOperationId?: string;
readonly customerId?: string;
customerName?: string;
readonly deleteAsyncOperationId?: string;
fullyQualifiedResourceId?: string;
isEnterpriseManaged?: boolean;
isEntitled?: boolean;
readonly lastSyncWithAzureTimestamp?: Date;
releaseVersion?: number;
resendSignupCode?: boolean;
shouldMigrate?: boolean;
readonly synchWithAzureAttemptsCount?: number;
verifySignupCode?: boolean;
verifySignupPhrase?: string;
}
// @public
export interface CustomerProperty {
additionalCustomerProperties?: AdditionalCustomerProperties;
customer?: CustomerEntity;
readonly error?: ErrorDetail;
readonly provisioningState?: ProvisioningState;
readonly status?: string;
readonly statusCode?: string;
readonly statusDetails?: string;
readonly statusText?: string;
}
// @public
export type CustomerTransitState = string;
// @public
export type CycleType = string;
// @public
export interface EnterpriseCustomerOperationsCreateOrUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface EnterpriseCustomerOperationsDeleteOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseCustomerOperationsGetOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseCustomerOperationsListByResourceGroupOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseCustomerOperationsListBySubscriptionOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseCustomerOperationsOperations {
createOrUpdate: (resourceGroupName: string, customerResourceName: string, resource: EnterprisePreviewResource, options?: EnterpriseCustomerOperationsCreateOrUpdateOptionalParams) => PollerLike<OperationState<EnterprisePreviewResource>, EnterprisePreviewResource>;
delete: (resourceGroupName: string, customerResourceName: string, options?: EnterpriseCustomerOperationsDeleteOptionalParams) => Promise<void>;
get: (resourceGroupName: string, customerResourceName: string, options?: EnterpriseCustomerOperationsGetOptionalParams) => Promise<EnterprisePreviewResource>;
listByResourceGroup: (resourceGroupName: string, options?: EnterpriseCustomerOperationsListByResourceGroupOptionalParams) => PagedAsyncIterableIterator<EnterprisePreviewResource>;
listBySubscription: (options?: EnterpriseCustomerOperationsListBySubscriptionOptionalParams) => PagedAsyncIterableIterator<EnterprisePreviewResource>;
update: (resourceGroupName: string, customerResourceName: string, properties: ConnectedCachePatchResource, options?: EnterpriseCustomerOperationsUpdateOptionalParams) => Promise<EnterprisePreviewResource>;
}
// @public
export interface EnterpriseCustomerOperationsUpdateOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCacheNodeResource extends TrackedResource {
properties?: CacheNodeProperty;
}
// @public
export interface EnterpriseMccCacheNodesOperationsCreateOrUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface EnterpriseMccCacheNodesOperationsDeleteOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface EnterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCacheNodesOperationsGetOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCacheNodesOperationsOperations {
createOrUpdate: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, resource: EnterpriseMccCacheNodeResource, options?: EnterpriseMccCacheNodesOperationsCreateOrUpdateOptionalParams) => PollerLike<OperationState<EnterpriseMccCacheNodeResource>, EnterpriseMccCacheNodeResource>;
delete: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: EnterpriseMccCacheNodesOperationsDeleteOptionalParams) => PollerLike<OperationState<void>, void>;
get: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: EnterpriseMccCacheNodesOperationsGetOptionalParams) => Promise<EnterpriseMccCacheNodeResource>;
getCacheNodeInstallDetails: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: EnterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsOptionalParams) => Promise<MccCacheNodeInstallDetails>;
listByEnterpriseMccCustomerResource: (resourceGroupName: string, customerResourceName: string, options?: EnterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceOptionalParams) => PagedAsyncIterableIterator<EnterpriseMccCacheNodeResource>;
update: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, properties: ConnectedCachePatchResource, options?: EnterpriseMccCacheNodesOperationsUpdateOptionalParams) => Promise<EnterpriseMccCacheNodeResource>;
}
// @public
export interface EnterpriseMccCacheNodesOperationsUpdateOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCustomerResource extends TrackedResource {
properties?: CustomerProperty;
}
// @public
export interface EnterpriseMccCustomersCreateOrUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface EnterpriseMccCustomersDeleteOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface EnterpriseMccCustomersGetOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCustomersListByResourceGroupOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCustomersListBySubscriptionOptionalParams extends OperationOptions {
}
// @public
export interface EnterpriseMccCustomersOperations {
createOrUpdate: (resourceGroupName: string, customerResourceName: string, resource: EnterpriseMccCustomerResource, options?: EnterpriseMccCustomersCreateOrUpdateOptionalParams) => PollerLike<OperationState<EnterpriseMccCustomerResource>, EnterpriseMccCustomerResource>;
delete: (resourceGroupName: string, customerResourceName: string, options?: EnterpriseMccCustomersDeleteOptionalParams) => PollerLike<OperationState<void>, void>;
get: (resourceGroupName: string, customerResourceName: string, options?: EnterpriseMccCustomersGetOptionalParams) => Promise<EnterpriseMccCustomerResource>;
listByResourceGroup: (resourceGroupName: string, options?: EnterpriseMccCustomersListByResourceGroupOptionalParams) => PagedAsyncIterableIterator<EnterpriseMccCustomerResource>;
listBySubscription: (options?: EnterpriseMccCustomersListBySubscriptionOptionalParams) => PagedAsyncIterableIterator<EnterpriseMccCustomerResource>;
update: (resourceGroupName: string, customerResourceName: string, properties: ConnectedCachePatchResource, options?: EnterpriseMccCustomersUpdateOptionalParams) => Promise<EnterpriseMccCustomerResource>;
}
// @public
export interface EnterpriseMccCustomersUpdateOptionalParams extends OperationOptions {
}
// @public
export interface EnterprisePreviewResource extends TrackedResource {
properties?: CacheNodeOldResponse;
}
// @public
export interface ErrorAdditionalInfo {
readonly info?: Record<string, any>;
readonly type?: string;
}
// @public
export interface ErrorDetail {
readonly additionalInfo?: ErrorAdditionalInfo[];
readonly code?: string;
readonly details?: ErrorDetail[];
readonly message?: string;
readonly target?: string;
}
// @public
export interface IspCacheNodeResource extends TrackedResource {
properties?: CacheNodeProperty;
}
// @public
export interface IspCacheNodesOperationsCreateOrUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface IspCacheNodesOperationsDeleteOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface IspCacheNodesOperationsGetBgpCidrsOptionalParams extends OperationOptions {
}
// @public
export interface IspCacheNodesOperationsGetCacheNodeInstallDetailsOptionalParams extends OperationOptions {
}
// @public
export interface IspCacheNodesOperationsGetOptionalParams extends OperationOptions {
}
// @public
export interface IspCacheNodesOperationsListByIspCustomerResourceOptionalParams extends OperationOptions {
}
// @public
export interface IspCacheNodesOperationsOperations {
createOrUpdate: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, resource: IspCacheNodeResource, options?: IspCacheNodesOperationsCreateOrUpdateOptionalParams) => PollerLike<OperationState<IspCacheNodeResource>, IspCacheNodeResource>;
delete: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: IspCacheNodesOperationsDeleteOptionalParams) => PollerLike<OperationState<void>, void>;
get: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: IspCacheNodesOperationsGetOptionalParams) => Promise<IspCacheNodeResource>;
getBgpCidrs: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: IspCacheNodesOperationsGetBgpCidrsOptionalParams) => Promise<MccCacheNodeBgpCidrDetails>;
getCacheNodeInstallDetails: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, options?: IspCacheNodesOperationsGetCacheNodeInstallDetailsOptionalParams) => Promise<MccCacheNodeInstallDetails>;
listByIspCustomerResource: (resourceGroupName: string, customerResourceName: string, options?: IspCacheNodesOperationsListByIspCustomerResourceOptionalParams) => PagedAsyncIterableIterator<IspCacheNodeResource>;
update: (resourceGroupName: string, customerResourceName: string, cacheNodeResourceName: string, properties: ConnectedCachePatchResource, options?: IspCacheNodesOperationsUpdateOptionalParams) => Promise<IspCacheNodeResource>;
}
// @public
export interface IspCacheNodesOperationsUpdateOptionalParams extends OperationOptions {
}
// @public
export interface IspCustomerResource extends TrackedResource {
properties?: CustomerProperty;
}
// @public
export interface IspCustomersCreateOrUpdateOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface IspCustomersDeleteOptionalParams extends OperationOptions {
updateIntervalInMs?: number;
}
// @public
export interface IspCustomersGetOptionalParams extends OperationOptions {
}
// @public
export interface IspCustomersListByResourceGroupOptionalParams extends OperationOptions {
}
// @public
export interface IspCustomersListBySubscriptionOptionalParams extends OperationOptions {
}
// @public
export interface IspCustomersOperations {
createOrUpdate: (resourceGroupName: string, customerResourceName: string, resource: IspCustomerResource, options?: IspCustomersCreateOrUpdateOptionalParams) => PollerLike<OperationState<IspCustomerResource>, IspCustomerResource>;
delete: (resourceGroupName: string, customerResourceName: string, options?: IspCustomersDeleteOptionalParams) => PollerLike<OperationState<void>, void>;
get: (resourceGroupName: string, customerResourceName: string, options?: IspCustomersGetOptionalParams) => Promise<IspCustomerResource>;
listByResourceGroup: (resourceGroupName: string, options?: IspCustomersListByResourceGroupOptionalParams) => PagedAsyncIterableIterator<IspCustomerResource>;
listBySubscription: (options?: IspCustomersListBySubscriptionOptionalParams) => PagedAsyncIterableIterator<IspCustomerResource>;
update: (resourceGroupName: string, customerResourceName: string, properties: ConnectedCachePatchResource, options?: IspCustomersUpdateOptionalParams) => Promise<IspCustomerResource>;
}
// @public
export interface IspCustomersUpdateOptionalParams extends OperationOptions {
}
// @public
export enum KnownActionType {
Internal = "Internal"
}
// @public
export enum KnownAutoUpdateRingType {
Fast = "Fast",
Preview = "Preview",
Slow = "Slow"
}
// @public
export enum KnownBgpReviewStateEnum {
Approved = "Approved",
AttentionRequired = "AttentionRequired",
InReview = "InReview",
NotConfigured = "NotConfigured"
}
// @public
export enum KnownConfigurationState {
Configured = "Configured",
NotConfigured_Ip = "NotConfigured_Ip"
}
// @public
export enum KnownCreatedByType {
Application = "Application",
Key = "Key",
ManagedIdentity = "ManagedIdentity",
User = "User"
}
// @public
export enum KnownCustomerTransitState {
CombinedTransit = "CombinedTransit",
NoTransit = "NoTransit",
TransitOnly = "TransitOnly"
}
// @public
export enum KnownCycleType {
Fast = "Fast",
Preview = "Preview",
Slow = "Slow"
}
// @public
export enum KnownOrigin {
System = "system",
User = "user",
UserSystem = "user,system"
}
// @public
export enum KnownOsType {
Eflow = "Eflow",
Linux = "Linux",
Windows = "Windows"
}
// @public
export enum KnownProvisioningState {
Accepted = "Accepted",
Canceled = "Canceled",
Deleting = "Deleting",
Failed = "Failed",
Succeeded = "Succeeded",
Unknown = "Unknown",
Upgrading = "Upgrading"
}
// @public
export enum KnownProxyRequired {
None = "None",
Required = "Required"
}
// @public
export enum KnownVersions {
v2023_05_01_preview = "2023-05-01-preview"
}
// @public
export interface MccCacheNodeBgpCidrDetails extends TrackedResource {
properties?: BgpCidrsConfiguration;
}
// @public
export interface MccCacheNodeInstallDetails extends TrackedResource {
properties?: CacheNodeInstallProperties;
}
// @public
export interface Operation {
actionType?: ActionType;
readonly display?: OperationDisplay;
readonly isDataAction?: boolean;
readonly name?: string;
readonly origin?: Origin;
}
// @public
export interface OperationDisplay {
readonly description?: string;
readonly operation?: string;
readonly provider?: string;
readonly resource?: string;
}
// @public
export interface OperationsListOptionalParams extends OperationOptions {
}
// @public
export interface OperationsOperations {
list: (options?: OperationsListOptionalParams) => PagedAsyncIterableIterator<Operation>;
}
// @public
export type Origin = string;
// @public
export type OsType = string;
// @public
export interface PagedAsyncIterableIterator<TElement, TPage = TElement[], TPageSettings extends PageSettings = PageSettings> {
[Symbol.asyncIterator](): PagedAsyncIterableIterator<TElement, TPage, TPageSettings>;
byPage: (settings?: TPageSettings) => AsyncIterableIterator<ContinuablePage<TElement, TPage>>;
next(): Promise<IteratorResult<TElement>>;
}
// @public
export interface PageSettings {
continuationToken?: string;
}
// @public
export type ProvisioningState = string;
// @public
export type ProxyRequired = string;
// @public
export interface ProxyUrlConfiguration {
proxyUrl?: string;
}
// @public
export interface Resource {
readonly id?: string;
readonly name?: string;
readonly systemData?: SystemData;
readonly type?: string;
}
// @public
export function restorePoller<TResponse extends PathUncheckedResponse, TResult>(client: ConnectedCacheClient, serializedState: string, sourceOperation: (...args: any[]) => PollerLike<OperationState<TResult>, TResult>, options?: RestorePollerOptions<TResult>): PollerLike<OperationState<TResult>, TResult>;
// @public (undocumented)
export interface RestorePollerOptions<TResult, TResponse extends PathUncheckedResponse = PathUncheckedResponse> extends OperationOptions {
abortSignal?: AbortSignalLike;
processResponseBody?: (result: TResponse) => Promise<TResult>;
updateIntervalInMs?: number;
}
// @public
export interface SystemData {
createdAt?: Date;
createdBy?: string;
createdByType?: CreatedByType;
lastModifiedAt?: Date;
lastModifiedBy?: string;
lastModifiedByType?: CreatedByType;
}
// @public
export interface TrackedResource extends Resource {
location: string;
tags?: Record<string, string>;
}
// (No @packageDocumentation comment for this package)
```

Просмотреть файл

@ -0,0 +1 @@
# Feel free to add your own environment variables.

Просмотреть файл

@ -0,0 +1,38 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to creates a cacheNodes with the specified create parameters
*
* @summary creates a cacheNodes with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_CreateorUpdate_MaximumSet_Gen.json
*/
async function cacheNodesOperationsCreateorUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.createorUpdate(
"rgConnectedCache",
"lwrsyhvfpcfrwrim",
{
location: "westus",
properties: {
statusCode: "movtzupooyhdqk",
statusText: "bjnsrpzaofjntleoesjwammgbi",
statusDetails: "quuziibkwtgf",
error: {},
},
tags: { key8256: "oreqiywrjkmate" },
},
);
console.log(result);
}
async function main() {
cacheNodesOperationsCreateorUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to deletes an existing cache Node
*
* @summary deletes an existing cache Node
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function cacheNodesOperationsDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.cacheNodesOperations.delete(
"rgConnectedCache",
"otvtvhmovthjwzjzbsqkbnmpcmmeianpqxmmaspvdczmrenquxigrtuarmlcmvsnaclhcbw",
);
}
async function main() {
cacheNodesOperationsDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of a cacheNodes
*
* @summary retrieves the properties of a cacheNodes
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function cacheNodesOperationsGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.get(
"rgConnectedCache",
"nqoxkgorhuzbhjwcegymzqbeydzjupemekt",
);
console.log(result);
}
async function main() {
cacheNodesOperationsGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCache
*
* @summary retrieves the properties of all ConnectedCache
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListByResourceGroup_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.cacheNodesOperations.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCaches
*
* @summary retrieves the properties of all ConnectedCaches
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListBySubscription_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyResourceListBySubscriptionGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.cacheNodesOperations.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
cacheNodesPrivatePreviewLegacyResourceListBySubscriptionGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to updates an existing Cache Node
*
* @summary updates an existing Cache Node
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyUpdateOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.update("rgConnectedCache", "wlrwpdbcv", {
tags: { key5032: "esiuyjbpcwkpqriqiqztxuocv" },
});
console.log(result);
}
async function main() {
cacheNodesPrivatePreviewLegacyUpdateOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,34 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to creates a cacheNodes with the specified create parameters
*
* @summary creates a cacheNodes with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.createOrUpdate("rgConnectedCache", "l", {
properties: {
statusCode: "oldkroffqtkryqffpsi",
statusText: "bs",
statusDetails: "lhwvcz",
error: {},
},
tags: { key4215: "zjbszvlzf" },
location: "zdzhhkjyogrqxwihkifnmeyhwpujbr",
});
console.log(result);
}
async function main() {
enterpriseCustomerOperationsCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to deletes an existing customer Enterprise resource
*
* @summary deletes an existing customer Enterprise resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Delete_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseCustomerOperations.delete(
"rgConnectedCache",
"jeubxmhiaihcusgnahblvvckbdcetacvqgwbohlrqucodtlwuyefpejskvamgrdnwgucziodcfpjhqy",
);
}
async function main() {
enterpriseCustomerOperationsDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,25 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of a Enterprise customer
*
* @summary retrieves the properties of a Enterprise customer
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Get_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.get("rgConnectedCache", "MCCTPTest2");
console.log(result);
}
async function main() {
enterpriseCustomerOperationsGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,31 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCache enterpriseCustomers
*
* @summary retrieves the properties of all ConnectedCache enterpriseCustomers
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListByResourceGroup_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsListByResourceGroup() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseCustomerOperations.listByResourceGroup(
"rgConnectedCache",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseCustomerOperationsListByResourceGroup();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCaches
*
* @summary retrieves the properties of all ConnectedCaches
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListBySubscription_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsListBySubscription() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseCustomerOperations.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseCustomerOperationsListBySubscription();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to updates an existing enterpriseCustomers
*
* @summary updates an existing enterpriseCustomers
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Update_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.update(
"rgConnectedCache",
"MCCTPTest2",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
enterpriseCustomerOperationsUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,73 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api creates an ispCacheNode with the specified create parameters
*
* @summary this api creates an ispCacheNode with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function createsAnEnterpriseMccCacheNodeResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.createOrUpdate(
"rgConnectedCache",
"nhdkvstdrrtsxxuz",
"fgduqdovidpemlnmhelomffuafdrbgaasqznvrdkbvspfzsnrhncdtqquhijhdpwyzwleukqldpceyxqhqlftqrr",
{
location: "westus",
properties: {
cacheNode: {
fullyQualifiedResourceId: "yeinlleavzbehelhsucb",
customerName: "zsklcocjfjhkcpmzyefzkwamdzc",
ipAddress: "gbfkdhloyphnpnhemwrcrxlk",
customerIndex: "vafvezmelfgmjsrccjukrhppljvipg",
cacheNodeId: "fmrjefyddfn",
cacheNodeName: "qppvqxliajjfoalzjbgmxggr",
customerAsn: 25,
isEnabled: true,
maxAllowableEgressInMbps: 27,
isEnterpriseManaged: true,
cidrCsv: ["nlqlvrthafvvljuupcbcw"],
shouldMigrate: true,
cidrSelectionType: 11,
},
statusCode: "1",
statusText: "Success",
statusDetails: "lgljxmyyoakw",
additionalCacheNodeProperties: {
cacheNodePropertiesDetailsIssuesList: ["ennbzfpuszgalzpawmwicaofqcwcj"],
driveConfiguration: [
{
physicalPath: "pcbkezoofhamkycot",
sizeInGb: 14,
cacheNumber: 11,
nginxMapping: "cirlpkpuxg",
},
],
bgpConfiguration: { asnToIpAddressMapping: "fjbggfvumrn" },
proxyUrlConfiguration: { proxyUrl: "hplstyg" },
proxyUrl: "ihkzxlzvpcywtzrogupqozkdud",
optionalProperty1: "ph",
optionalProperty2: "soqqgpgcbhb",
optionalProperty3: "fpnycrbagptsujiotnjfuhlm",
optionalProperty4: "gesqugrxvhxlxxyvatgrautxwlmxsf",
optionalProperty5: "zknjgzpaqtvdqjydd",
},
error: {},
},
tags: { key259: "qbkixjuyjkoj" },
},
);
console.log(result);
}
async function main() {
createsAnEnterpriseMccCacheNodeResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api deletes an existing ispCacheNode resource
*
* @summary this api deletes an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsDeleteOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseMccCacheNodesOperations.delete(
"rgConnectedCache",
"hsincngmssuzeyispnufqwinpopadvhsbsemisguxgovwdjwviqexocelijvuyr",
"vwtrhdoxvkrunpliwcao",
);
}
async function main() {
enterpriseMccCacheNodesOperationsDeleteOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets secrets of the ispCacheNode resource install details
*
* @summary this api gets secrets of the ispCacheNode resource install details
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json
*/
async function getsRequiredPropertiesForEnterpriseMccCacheNodeResourceInstallKeyDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.getCacheNodeInstallDetails(
"rgConnectedCache",
"fzwxcjmdpxxzayecabqqlh",
"ccexmqqttritxvtctivraso",
);
console.log(result);
}
async function main() {
getsRequiredPropertiesForEnterpriseMccCacheNodeResourceInstallKeyDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function getsEnterpriseMccCacheNodeResourceInformationOfAnEnterpriseMccCustomerParentResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.get(
"rgConnectedCache",
"cygqjgtcetihsajgyqwwrbclssqsvhgltrboemcqqtpoxdbhykqxblaihmrumyhbsx",
"fqxfadsultwjfzdwlqkvneakfsbyhratytmssmiukpbnus",
);
console.log(result);
}
async function main() {
getsEnterpriseMccCacheNodeResourceInformationOfAnEnterpriseMccCustomerParentResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,32 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api retrieves information about all ispCacheNode resources under the given subscription and resource group
*
* @summary this api retrieves information about all ispCacheNode resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_ListByEnterpriseMccCustomerResource_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResource() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCacheNodesOperations.listByEnterpriseMccCustomerResource(
"rgConnectedCache",
"syjjjzk",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResource();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api updates an existing ispCacheNode resource
*
* @summary this api updates an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsUpdateGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.update(
"rgConnectedCache",
"qanjqtvrxzjkljdysdjvdiqcxkttskpdzykzuefhbhz",
"kllmlvazrcxmfjfozulzqnsgvspgwmhogcafvauchunlgfr",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
enterpriseMccCacheNodesOperationsUpdateGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,64 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api creates an enterprise mcc customer with the specified create parameters
*
* @summary this api creates an enterprise mcc customer with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_CreateOrUpdate_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.createOrUpdate(
"rgConnectedCache",
"MccRPTest1",
{
properties: {
customer: {
fullyQualifiedResourceId: "uqsbtgae",
customerName: "mkpzynfqihnjfdbaqbqwyhd",
contactEmail: "xquos",
contactPhone: "vue",
contactName: "wxyqjoyoscmvimgwhpitxky",
isEntitled: true,
releaseVersion: 20,
clientTenantId: "fproidkpgvpdnac",
isEnterpriseManaged: true,
shouldMigrate: true,
resendSignupCode: true,
verifySignupCode: true,
verifySignupPhrase: "tprjvttkgmrqlsyicnidhm",
},
additionalCustomerProperties: {
customerEmail: "zdjgibsidydyzm",
customerTransitAsn: "habgklnxqzmozqpazoyejwiphezpi",
customerAsn: "hgrelgnrtdkleisnepfolu",
customerEntitlementSkuId: "b",
customerEntitlementSkuGuid: "rvzmdpxyflgqetvpwupnfaxsweiiz",
customerEntitlementSkuName: "waaqfijr",
customerEntitlementExpiration: new Date("2024-01-30T00:54:04.773Z"),
optionalProperty1: "qhmwxza",
optionalProperty2: "l",
optionalProperty3: "mblwwvbie",
optionalProperty4: "vzuek",
optionalProperty5: "fzjodscdfcdr",
},
error: {},
},
tags: { key3379: "dpyqeaqhcnutzezom" },
location: "westus",
},
);
console.log(result);
}
async function main() {
enterpriseMccCustomersCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,24 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api deletes an existing enterprise mcc customer resource
*
* @summary this api deletes an existing enterprise mcc customer resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Delete_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseMccCustomers.delete("rgConnectedCache", "zktb");
}
async function main() {
enterpriseMccCustomersDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to gets the enterprise mcc customer resource information using this get call
*
* @summary gets the enterprise mcc customer resource information using this get call
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Get_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.get(
"rgConnectedCache",
"pvilvqkofbjbykupeewgvzlmjao",
);
console.log(result);
}
async function main() {
enterpriseMccCustomersGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets the information about all enterprise mcc customer resources under the given subscription and resource group
*
* @summary this api gets the information about all enterprise mcc customer resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListByResourceGroup_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersListByResourceGroup() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCustomers.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCustomersListByResourceGroup();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets information about all enterpriseMccCustomer resources under the given subscription
*
* @summary this api gets information about all enterpriseMccCustomer resources under the given subscription
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListBySubscription_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersListBySubscription() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCustomers.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCustomersListBySubscription();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api updates an existing enterprise mcc customer resource
*
* @summary this api updates an existing enterprise mcc customer resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Update_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.update("rgConnectedCache", "MccRPTest1", {
tags: { key1878: "warz" },
});
console.log(result);
}
async function main() {
enterpriseMccCustomersUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,73 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api creates an ispCacheNode with the specified create parameters
*
* @summary this api creates an ispCacheNode with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.createOrUpdate(
"rgConnectedCache",
"zpqzbmanlljgmkrthtydrtneavhlnlqkdmviq",
"cabakm",
{
location: "westus",
properties: {
cacheNode: {
fullyQualifiedResourceId: "hskxkpbiqbrbjiwdzrxndru",
customerName: "xwyqk",
ipAddress: "voctagljcwqgcpnionqdcbjk",
customerIndex: "qtoiglqaswivmkjhzogburcxtszmek",
cacheNodeId: "xjzffjftwcgsehanoxsl",
cacheNodeName: "mfjxb",
customerAsn: 4,
isEnabled: true,
maxAllowableEgressInMbps: 29,
isEnterpriseManaged: true,
cidrCsv: ["nlqlvrthafvvljuupcbcw"],
shouldMigrate: true,
cidrSelectionType: 4,
},
additionalCacheNodeProperties: {
driveConfiguration: [
{
physicalPath: "/mcc",
sizeInGb: 500,
cacheNumber: 1,
nginxMapping: "lijygenjq",
},
],
bgpConfiguration: { asnToIpAddressMapping: "pafcimhoog" },
cacheNodePropertiesDetailsIssuesList: ["ex"],
proxyUrlConfiguration: { proxyUrl: "hplstyg" },
proxyUrl: "qhux",
optionalProperty1: "hvpmt",
optionalProperty2: "talanelmsgxvksrzoeeontqkjzbpv",
optionalProperty3: "bxkoxq",
optionalProperty4: "pqlkcekupusoc",
optionalProperty5: "nyvvmrjigqdufzjdvazdca",
},
statusCode: "1",
statusText: "Success",
statusDetails: "djruqvptzxak",
error: {},
},
tags: { key4171: "qtjlszkawsdujzpgohsbw" },
},
);
console.log(result);
}
async function main() {
ispCacheNodesOperationsCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api deletes an existing ispCacheNode resource
*
* @summary this api deletes an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function ispCacheNodesDeleteOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.ispCacheNodesOperations.delete(
"rgConnectedCache",
"lvpcosvbfxtpzscakewx",
"wsiruvexelltpbouqxvsogqpxdizcwqwfowybncvjunlakjwcpgmqbdbgzjrsmxlkczxnsxfonhnqqa",
);
}
async function main() {
ispCacheNodesDeleteOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetBgpCidrs_MaximumSet_Gen.json
*/
async function ispCacheNodesResourceBgpCidrsDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.getBgpCidrs(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
);
console.log(result);
}
async function main() {
ispCacheNodesResourceBgpCidrsDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets secrets of the ispCacheNode resource install details
*
* @summary this api gets secrets of the ispCacheNode resource install details
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json
*/
async function ispCacheNodeResourceGetInstallDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.getCacheNodeInstallDetails(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
);
console.log(result);
}
async function main() {
ispCacheNodeResourceGetInstallDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function ispCacheNodesGetResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.get(
"rgConnectedCache",
"sgtqjsitdrskmgyrrkntszwrrjjkretscpjgaezraucvcwececlelcsorfunrnvxyxcsrg",
"lbsziwmudcjnwnwy",
);
console.log(result);
}
async function main() {
ispCacheNodesGetResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,32 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api retrieves information about all ispCacheNode resources under the given subscription and resource group
*
* @summary this api retrieves information about all ispCacheNode resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_ListByIspCustomerResource_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsListByIspCustomerResource() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCacheNodesOperations.listByIspCustomerResource(
"rgConnectedCache",
"MccRPTest1",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCacheNodesOperationsListByIspCustomerResource();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api updates an existing ispCacheNode resource
*
* @summary this api updates an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.update(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
ispCacheNodesOperationsUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,60 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api creates an ispCustomer with the specified create parameters
*
* @summary this api creates an ispCustomer with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/IspCustomers_CreateOrUpdate_MaximumSet_Gen.json
*/
async function ispCustomerCreateOrUpdateGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.createOrUpdate("rgConnectedCache", "MccRPTest2", {
location: "westus",
properties: {
customer: {
fullyQualifiedResourceId: "uqsbtgae",
customerName: "mkpzynfqihnjfdbaqbqwyhd",
contactEmail: "xquos",
contactPhone: "vue",
contactName: "wxyqjoyoscmvimgwhpitxky",
isEntitled: true,
releaseVersion: 20,
clientTenantId: "fproidkpgvpdnac",
isEnterpriseManaged: true,
shouldMigrate: true,
resendSignupCode: true,
verifySignupCode: true,
verifySignupPhrase: "tprjvttkgmrqlsyicnidhm",
},
additionalCustomerProperties: {
customerEmail: "zdjgibsidydyzm",
customerTransitAsn: "habgklnxqzmozqpazoyejwiphezpi",
customerAsn: "hgrelgnrtdkleisnepfolu",
customerEntitlementSkuId: "b",
customerEntitlementSkuGuid: "rvzmdpxyflgqetvpwupnfaxsweiiz",
customerEntitlementSkuName: "waaqfijr",
customerEntitlementExpiration: new Date("2024-01-30T00:54:04.773Z"),
optionalProperty1: "qhmwxza",
optionalProperty2: "l",
optionalProperty3: "mblwwvbie",
optionalProperty4: "vzuek",
optionalProperty5: "fzjodscdfcdr",
},
error: {},
},
tags: { key1878: "warz" },
});
console.log(result);
}
async function main() {
ispCustomerCreateOrUpdateGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api deletes an existing ispCustomer resource
*
* @summary this api deletes an existing ispCustomer resource
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Delete_MaximumSet_Gen.json
*/
async function ispCustomersDeleteGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.ispCustomers.delete(
"rgConnectedCache",
"hdontfoythjsaeyjhrakckgimgchxwzttbcnvntpvdsgeumxpgnjurptd",
);
}
async function main() {
ispCustomersDeleteGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,25 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to gets the ispCustomer resource information using this get call
*
* @summary gets the ispCustomer resource information using this get call
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Get_MaximumSet_Gen.json
*/
async function ispCustomersGetGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.get("rgConnectedCache", "cmcjfueweicolcjkwmsuvcj");
console.log(result);
}
async function main() {
ispCustomersGetGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets the information about all ispCustomer resources under the given subscription and resource group
*
* @summary this api gets the information about all ispCustomer resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/IspCustomers_ListByResourceGroup_MaximumSet_Gen.json
*/
async function ispCustomersResourceListByResourceGroupGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCustomers.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCustomersResourceListByResourceGroupGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api gets information about all ispCustomer resources under the given subscription
*
* @summary this api gets information about all ispCustomer resources under the given subscription
* x-ms-original-file: 2023-05-01-preview/IspCustomers_ListBySubscription_MaximumSet_Gen.json
*/
async function ispCustomerListBySubscriptionGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCustomers.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCustomerListBySubscriptionGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to this api updates an existing ispCustomer resource
*
* @summary this api updates an existing ispCustomer resource
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Update_MaximumSet_Gen.json
*/
async function ispCustomerUpdateDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.update("rgConnectedCache", "MccRPTest2", {
tags: { key1653: "nzjczrhclhkndesgy" },
});
console.log(result);
}
async function main() {
ispCustomerUpdateDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to list the operations for the provider
*
* @summary list the operations for the provider
* x-ms-original-file: 2023-05-01-preview/Operations_List_MaximumSet_Gen.json
*/
async function listTheOperationsForTheProviderGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-00000000000";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.operations.list()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
listTheOperationsForTheProviderGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,124 @@
# @azure/arm-connectedcache client library samples for JavaScript (Beta)
These sample programs show how to use the JavaScript client libraries for @azure/arm-connectedcache in some common scenarios.
| **File Name** | **Description** |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| [cacheNodesOperationsCreateorUpdateSample.js][cachenodesoperationscreateorupdatesample] | creates a cacheNodes with the specified create parameters x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_CreateorUpdate_MaximumSet_Gen.json |
| [cacheNodesOperationsDeleteSample.js][cachenodesoperationsdeletesample] | deletes an existing cache Node x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Delete_MaximumSet_Gen.json |
| [cacheNodesOperationsGetSample.js][cachenodesoperationsgetsample] | retrieves the properties of a cacheNodes x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Get_MaximumSet_Gen.json |
| [cacheNodesOperationsListByResourceGroupSample.js][cachenodesoperationslistbyresourcegroupsample] | retrieves the properties of all ConnectedCache x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListByResourceGroup_MaximumSet_Gen.json |
| [cacheNodesOperationsListBySubscriptionSample.js][cachenodesoperationslistbysubscriptionsample] | retrieves the properties of all ConnectedCaches x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListBySubscription_MaximumSet_Gen.json |
| [cacheNodesOperationsUpdateSample.js][cachenodesoperationsupdatesample] | updates an existing Cache Node x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Update_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsCreateOrUpdateSample.js][enterprisecustomeroperationscreateorupdatesample] | creates a cacheNodes with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsDeleteSample.js][enterprisecustomeroperationsdeletesample] | deletes an existing customer Enterprise resource x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Delete_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsGetSample.js][enterprisecustomeroperationsgetsample] | retrieves the properties of a Enterprise customer x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Get_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsListByResourceGroupSample.js][enterprisecustomeroperationslistbyresourcegroupsample] | retrieves the properties of all ConnectedCache enterpriseCustomers x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListByResourceGroup_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsListBySubscriptionSample.js][enterprisecustomeroperationslistbysubscriptionsample] | retrieves the properties of all ConnectedCaches x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListBySubscription_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsUpdateSample.js][enterprisecustomeroperationsupdatesample] | updates an existing enterpriseCustomers x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Update_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsCreateOrUpdateSample.js][enterprisemcccachenodesoperationscreateorupdatesample] | this api creates an ispCacheNode with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsDeleteSample.js][enterprisemcccachenodesoperationsdeletesample] | this api deletes an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Delete_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsSample.js][enterprisemcccachenodesoperationsgetcachenodeinstalldetailssample] | this api gets secrets of the ispCacheNode resource install details x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsGetSample.js][enterprisemcccachenodesoperationsgetsample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Get_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceSample.js][enterprisemcccachenodesoperationslistbyenterprisemcccustomerresourcesample] | this api retrieves information about all ispCacheNode resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_ListByEnterpriseMccCustomerResource_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsUpdateSample.js][enterprisemcccachenodesoperationsupdatesample] | this api updates an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Update_MaximumSet_Gen.json |
| [enterpriseMccCustomersCreateOrUpdateSample.js][enterprisemcccustomerscreateorupdatesample] | this api creates an enterprise mcc customer with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseMccCustomersDeleteSample.js][enterprisemcccustomersdeletesample] | this api deletes an existing enterprise mcc customer resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Delete_MaximumSet_Gen.json |
| [enterpriseMccCustomersGetSample.js][enterprisemcccustomersgetsample] | gets the enterprise mcc customer resource information using this get call x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Get_MaximumSet_Gen.json |
| [enterpriseMccCustomersListByResourceGroupSample.js][enterprisemcccustomerslistbyresourcegroupsample] | this api gets the information about all enterprise mcc customer resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListByResourceGroup_MaximumSet_Gen.json |
| [enterpriseMccCustomersListBySubscriptionSample.js][enterprisemcccustomerslistbysubscriptionsample] | this api gets information about all enterpriseMccCustomer resources under the given subscription x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListBySubscription_MaximumSet_Gen.json |
| [enterpriseMccCustomersUpdateSample.js][enterprisemcccustomersupdatesample] | this api updates an existing enterprise mcc customer resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Update_MaximumSet_Gen.json |
| [ispCacheNodesOperationsCreateOrUpdateSample.js][ispcachenodesoperationscreateorupdatesample] | this api creates an ispCacheNode with the specified create parameters x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [ispCacheNodesOperationsDeleteSample.js][ispcachenodesoperationsdeletesample] | this api deletes an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Delete_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetBgpCidrsSample.js][ispcachenodesoperationsgetbgpcidrssample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetBgpCidrs_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetCacheNodeInstallDetailsSample.js][ispcachenodesoperationsgetcachenodeinstalldetailssample] | this api gets secrets of the ispCacheNode resource install details x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetSample.js][ispcachenodesoperationsgetsample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Get_MaximumSet_Gen.json |
| [ispCacheNodesOperationsListByIspCustomerResourceSample.js][ispcachenodesoperationslistbyispcustomerresourcesample] | this api retrieves information about all ispCacheNode resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_ListByIspCustomerResource_MaximumSet_Gen.json |
| [ispCacheNodesOperationsUpdateSample.js][ispcachenodesoperationsupdatesample] | this api updates an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Update_MaximumSet_Gen.json |
| [ispCustomersCreateOrUpdateSample.js][ispcustomerscreateorupdatesample] | this api creates an ispCustomer with the specified create parameters x-ms-original-file: 2023-05-01-preview/IspCustomers_CreateOrUpdate_MaximumSet_Gen.json |
| [ispCustomersDeleteSample.js][ispcustomersdeletesample] | this api deletes an existing ispCustomer resource x-ms-original-file: 2023-05-01-preview/IspCustomers_Delete_MaximumSet_Gen.json |
| [ispCustomersGetSample.js][ispcustomersgetsample] | gets the ispCustomer resource information using this get call x-ms-original-file: 2023-05-01-preview/IspCustomers_Get_MaximumSet_Gen.json |
| [ispCustomersListByResourceGroupSample.js][ispcustomerslistbyresourcegroupsample] | this api gets the information about all ispCustomer resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/IspCustomers_ListByResourceGroup_MaximumSet_Gen.json |
| [ispCustomersListBySubscriptionSample.js][ispcustomerslistbysubscriptionsample] | this api gets information about all ispCustomer resources under the given subscription x-ms-original-file: 2023-05-01-preview/IspCustomers_ListBySubscription_MaximumSet_Gen.json |
| [ispCustomersUpdateSample.js][ispcustomersupdatesample] | this api updates an existing ispCustomer resource x-ms-original-file: 2023-05-01-preview/IspCustomers_Update_MaximumSet_Gen.json |
| [operationsListSample.js][operationslistsample] | list the operations for the provider x-ms-original-file: 2023-05-01-preview/Operations_List_MaximumSet_Gen.json |
## Prerequisites
The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule).
You need [an Azure subscription][freesub] to run these sample programs.
Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function.
Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package].
## Setup
To run the samples using the published version of the package:
1. Install the dependencies using `npm`:
```bash
npm install
```
2. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically.
3. Run whichever samples you like (note that some samples may require additional setup, see the table above):
```bash
node cacheNodesOperationsCreateorUpdateSample.js
```
Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform):
```bash
npx dev-tool run vendored cross-env node cacheNodesOperationsCreateorUpdateSample.js
```
## Next Steps
Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients.
[cachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsCreateorUpdateSample.js
[cachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsDeleteSample.js
[cachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsGetSample.js
[cachenodesoperationslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsListByResourceGroupSample.js
[cachenodesoperationslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsListBySubscriptionSample.js
[cachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/cacheNodesOperationsUpdateSample.js
[enterprisecustomeroperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsCreateOrUpdateSample.js
[enterprisecustomeroperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsDeleteSample.js
[enterprisecustomeroperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsGetSample.js
[enterprisecustomeroperationslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsListByResourceGroupSample.js
[enterprisecustomeroperationslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsListBySubscriptionSample.js
[enterprisecustomeroperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseCustomerOperationsUpdateSample.js
[enterprisemcccachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsCreateOrUpdateSample.js
[enterprisemcccachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsDeleteSample.js
[enterprisemcccachenodesoperationsgetcachenodeinstalldetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsSample.js
[enterprisemcccachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsGetSample.js
[enterprisemcccachenodesoperationslistbyenterprisemcccustomerresourcesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceSample.js
[enterprisemcccachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCacheNodesOperationsUpdateSample.js
[enterprisemcccustomerscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersCreateOrUpdateSample.js
[enterprisemcccustomersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersDeleteSample.js
[enterprisemcccustomersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersGetSample.js
[enterprisemcccustomerslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersListByResourceGroupSample.js
[enterprisemcccustomerslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersListBySubscriptionSample.js
[enterprisemcccustomersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/enterpriseMccCustomersUpdateSample.js
[ispcachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsCreateOrUpdateSample.js
[ispcachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsDeleteSample.js
[ispcachenodesoperationsgetbgpcidrssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsGetBgpCidrsSample.js
[ispcachenodesoperationsgetcachenodeinstalldetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsGetCacheNodeInstallDetailsSample.js
[ispcachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsGetSample.js
[ispcachenodesoperationslistbyispcustomerresourcesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsListByIspCustomerResourceSample.js
[ispcachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCacheNodesOperationsUpdateSample.js
[ispcustomerscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersCreateOrUpdateSample.js
[ispcustomersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersDeleteSample.js
[ispcustomersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersGetSample.js
[ispcustomerslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersListByResourceGroupSample.js
[ispcustomerslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersListBySubscriptionSample.js
[ispcustomersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/ispCustomersUpdateSample.js
[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/javascript/operationsListSample.js
[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-connectedcache?view=azure-node-preview
[freesub]: https://azure.microsoft.com/free/
[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/connectedcache/arm-connectedcache/README.md

Просмотреть файл

@ -0,0 +1,38 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to creates a cacheNodes with the specified create parameters
*
* @summary creates a cacheNodes with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_CreateorUpdate_MaximumSet_Gen.json
*/
async function cacheNodesOperationsCreateorUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.createorUpdate(
"rgConnectedCache",
"lwrsyhvfpcfrwrim",
{
location: "westus",
properties: {
statusCode: "movtzupooyhdqk",
statusText: "bjnsrpzaofjntleoesjwammgbi",
statusDetails: "quuziibkwtgf",
error: {},
},
tags: { key8256: "oreqiywrjkmate" },
},
);
console.log(result);
}
async function main() {
cacheNodesOperationsCreateorUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to deletes an existing cache Node
*
* @summary deletes an existing cache Node
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function cacheNodesOperationsDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.cacheNodesOperations.delete(
"rgConnectedCache",
"otvtvhmovthjwzjzbsqkbnmpcmmeianpqxmmaspvdczmrenquxigrtuarmlcmvsnaclhcbw",
);
}
async function main() {
cacheNodesOperationsDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of a cacheNodes
*
* @summary retrieves the properties of a cacheNodes
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function cacheNodesOperationsGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.get(
"rgConnectedCache",
"nqoxkgorhuzbhjwcegymzqbeydzjupemekt",
);
console.log(result);
}
async function main() {
cacheNodesOperationsGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCache
*
* @summary retrieves the properties of all ConnectedCache
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListByResourceGroup_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.cacheNodesOperations.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCaches
*
* @summary retrieves the properties of all ConnectedCaches
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListBySubscription_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyResourceListBySubscriptionGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.cacheNodesOperations.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
cacheNodesPrivatePreviewLegacyResourceListBySubscriptionGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to updates an existing Cache Node
*
* @summary updates an existing Cache Node
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyUpdateOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.update("rgConnectedCache", "wlrwpdbcv", {
tags: { key5032: "esiuyjbpcwkpqriqiqztxuocv" },
});
console.log(result);
}
async function main() {
cacheNodesPrivatePreviewLegacyUpdateOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,34 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to creates a cacheNodes with the specified create parameters
*
* @summary creates a cacheNodes with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.createOrUpdate("rgConnectedCache", "l", {
properties: {
statusCode: "oldkroffqtkryqffpsi",
statusText: "bs",
statusDetails: "lhwvcz",
error: {},
},
tags: { key4215: "zjbszvlzf" },
location: "zdzhhkjyogrqxwihkifnmeyhwpujbr",
});
console.log(result);
}
async function main() {
enterpriseCustomerOperationsCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to deletes an existing customer Enterprise resource
*
* @summary deletes an existing customer Enterprise resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Delete_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseCustomerOperations.delete(
"rgConnectedCache",
"jeubxmhiaihcusgnahblvvckbdcetacvqgwbohlrqucodtlwuyefpejskvamgrdnwgucziodcfpjhqy",
);
}
async function main() {
enterpriseCustomerOperationsDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,25 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of a Enterprise customer
*
* @summary retrieves the properties of a Enterprise customer
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Get_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.get("rgConnectedCache", "MCCTPTest2");
console.log(result);
}
async function main() {
enterpriseCustomerOperationsGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,31 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCache enterpriseCustomers
*
* @summary retrieves the properties of all ConnectedCache enterpriseCustomers
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListByResourceGroup_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsListByResourceGroup() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseCustomerOperations.listByResourceGroup(
"rgConnectedCache",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseCustomerOperationsListByResourceGroup();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCaches
*
* @summary retrieves the properties of all ConnectedCaches
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListBySubscription_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsListBySubscription() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseCustomerOperations.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseCustomerOperationsListBySubscription();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to updates an existing enterpriseCustomers
*
* @summary updates an existing enterpriseCustomers
* x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Update_MaximumSet_Gen.json
*/
async function enterpriseCustomerOperationsUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseCustomerOperations.update(
"rgConnectedCache",
"MCCTPTest2",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
enterpriseCustomerOperationsUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,73 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api creates an ispCacheNode with the specified create parameters
*
* @summary this api creates an ispCacheNode with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function createsAnEnterpriseMccCacheNodeResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.createOrUpdate(
"rgConnectedCache",
"nhdkvstdrrtsxxuz",
"fgduqdovidpemlnmhelomffuafdrbgaasqznvrdkbvspfzsnrhncdtqquhijhdpwyzwleukqldpceyxqhqlftqrr",
{
location: "westus",
properties: {
cacheNode: {
fullyQualifiedResourceId: "yeinlleavzbehelhsucb",
customerName: "zsklcocjfjhkcpmzyefzkwamdzc",
ipAddress: "gbfkdhloyphnpnhemwrcrxlk",
customerIndex: "vafvezmelfgmjsrccjukrhppljvipg",
cacheNodeId: "fmrjefyddfn",
cacheNodeName: "qppvqxliajjfoalzjbgmxggr",
customerAsn: 25,
isEnabled: true,
maxAllowableEgressInMbps: 27,
isEnterpriseManaged: true,
cidrCsv: ["nlqlvrthafvvljuupcbcw"],
shouldMigrate: true,
cidrSelectionType: 11,
},
statusCode: "1",
statusText: "Success",
statusDetails: "lgljxmyyoakw",
additionalCacheNodeProperties: {
cacheNodePropertiesDetailsIssuesList: ["ennbzfpuszgalzpawmwicaofqcwcj"],
driveConfiguration: [
{
physicalPath: "pcbkezoofhamkycot",
sizeInGb: 14,
cacheNumber: 11,
nginxMapping: "cirlpkpuxg",
},
],
bgpConfiguration: { asnToIpAddressMapping: "fjbggfvumrn" },
proxyUrlConfiguration: { proxyUrl: "hplstyg" },
proxyUrl: "ihkzxlzvpcywtzrogupqozkdud",
optionalProperty1: "ph",
optionalProperty2: "soqqgpgcbhb",
optionalProperty3: "fpnycrbagptsujiotnjfuhlm",
optionalProperty4: "gesqugrxvhxlxxyvatgrautxwlmxsf",
optionalProperty5: "zknjgzpaqtvdqjydd",
},
error: {},
},
tags: { key259: "qbkixjuyjkoj" },
},
);
console.log(result);
}
async function main() {
createsAnEnterpriseMccCacheNodeResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api deletes an existing ispCacheNode resource
*
* @summary this api deletes an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsDeleteOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseMccCacheNodesOperations.delete(
"rgConnectedCache",
"hsincngmssuzeyispnufqwinpopadvhsbsemisguxgovwdjwviqexocelijvuyr",
"vwtrhdoxvkrunpliwcao",
);
}
async function main() {
enterpriseMccCacheNodesOperationsDeleteOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets secrets of the ispCacheNode resource install details
*
* @summary this api gets secrets of the ispCacheNode resource install details
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json
*/
async function getsRequiredPropertiesForEnterpriseMccCacheNodeResourceInstallKeyDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.getCacheNodeInstallDetails(
"rgConnectedCache",
"fzwxcjmdpxxzayecabqqlh",
"ccexmqqttritxvtctivraso",
);
console.log(result);
}
async function main() {
getsRequiredPropertiesForEnterpriseMccCacheNodeResourceInstallKeyDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function getsEnterpriseMccCacheNodeResourceInformationOfAnEnterpriseMccCustomerParentResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.get(
"rgConnectedCache",
"cygqjgtcetihsajgyqwwrbclssqsvhgltrboemcqqtpoxdbhykqxblaihmrumyhbsx",
"fqxfadsultwjfzdwlqkvneakfsbyhratytmssmiukpbnus",
);
console.log(result);
}
async function main() {
getsEnterpriseMccCacheNodeResourceInformationOfAnEnterpriseMccCustomerParentResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,32 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api retrieves information about all ispCacheNode resources under the given subscription and resource group
*
* @summary this api retrieves information about all ispCacheNode resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_ListByEnterpriseMccCustomerResource_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResource() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCacheNodesOperations.listByEnterpriseMccCustomerResource(
"rgConnectedCache",
"syjjjzk",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResource();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api updates an existing ispCacheNode resource
*
* @summary this api updates an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function enterpriseMccCacheNodesOperationsUpdateGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCacheNodesOperations.update(
"rgConnectedCache",
"qanjqtvrxzjkljdysdjvdiqcxkttskpdzykzuefhbhz",
"kllmlvazrcxmfjfozulzqnsgvspgwmhogcafvauchunlgfr",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
enterpriseMccCacheNodesOperationsUpdateGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,64 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api creates an enterprise mcc customer with the specified create parameters
*
* @summary this api creates an enterprise mcc customer with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_CreateOrUpdate_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.createOrUpdate(
"rgConnectedCache",
"MccRPTest1",
{
properties: {
customer: {
fullyQualifiedResourceId: "uqsbtgae",
customerName: "mkpzynfqihnjfdbaqbqwyhd",
contactEmail: "xquos",
contactPhone: "vue",
contactName: "wxyqjoyoscmvimgwhpitxky",
isEntitled: true,
releaseVersion: 20,
clientTenantId: "fproidkpgvpdnac",
isEnterpriseManaged: true,
shouldMigrate: true,
resendSignupCode: true,
verifySignupCode: true,
verifySignupPhrase: "tprjvttkgmrqlsyicnidhm",
},
additionalCustomerProperties: {
customerEmail: "zdjgibsidydyzm",
customerTransitAsn: "habgklnxqzmozqpazoyejwiphezpi",
customerAsn: "hgrelgnrtdkleisnepfolu",
customerEntitlementSkuId: "b",
customerEntitlementSkuGuid: "rvzmdpxyflgqetvpwupnfaxsweiiz",
customerEntitlementSkuName: "waaqfijr",
customerEntitlementExpiration: new Date("2024-01-30T00:54:04.773Z"),
optionalProperty1: "qhmwxza",
optionalProperty2: "l",
optionalProperty3: "mblwwvbie",
optionalProperty4: "vzuek",
optionalProperty5: "fzjodscdfcdr",
},
error: {},
},
tags: { key3379: "dpyqeaqhcnutzezom" },
location: "westus",
},
);
console.log(result);
}
async function main() {
enterpriseMccCustomersCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,24 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api deletes an existing enterprise mcc customer resource
*
* @summary this api deletes an existing enterprise mcc customer resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Delete_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.enterpriseMccCustomers.delete("rgConnectedCache", "zktb");
}
async function main() {
enterpriseMccCustomersDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to gets the enterprise mcc customer resource information using this get call
*
* @summary gets the enterprise mcc customer resource information using this get call
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Get_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.get(
"rgConnectedCache",
"pvilvqkofbjbykupeewgvzlmjao",
);
console.log(result);
}
async function main() {
enterpriseMccCustomersGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets the information about all enterprise mcc customer resources under the given subscription and resource group
*
* @summary this api gets the information about all enterprise mcc customer resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListByResourceGroup_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersListByResourceGroup() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCustomers.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCustomersListByResourceGroup();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets information about all enterpriseMccCustomer resources under the given subscription
*
* @summary this api gets information about all enterpriseMccCustomer resources under the given subscription
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListBySubscription_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersListBySubscription() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.enterpriseMccCustomers.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
enterpriseMccCustomersListBySubscription();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api updates an existing enterprise mcc customer resource
*
* @summary this api updates an existing enterprise mcc customer resource
* x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Update_MaximumSet_Gen.json
*/
async function enterpriseMccCustomersUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.enterpriseMccCustomers.update("rgConnectedCache", "MccRPTest1", {
tags: { key1878: "warz" },
});
console.log(result);
}
async function main() {
enterpriseMccCustomersUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,73 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api creates an ispCacheNode with the specified create parameters
*
* @summary this api creates an ispCacheNode with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsCreateOrUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.createOrUpdate(
"rgConnectedCache",
"zpqzbmanlljgmkrthtydrtneavhlnlqkdmviq",
"cabakm",
{
location: "westus",
properties: {
cacheNode: {
fullyQualifiedResourceId: "hskxkpbiqbrbjiwdzrxndru",
customerName: "xwyqk",
ipAddress: "voctagljcwqgcpnionqdcbjk",
customerIndex: "qtoiglqaswivmkjhzogburcxtszmek",
cacheNodeId: "xjzffjftwcgsehanoxsl",
cacheNodeName: "mfjxb",
customerAsn: 4,
isEnabled: true,
maxAllowableEgressInMbps: 29,
isEnterpriseManaged: true,
cidrCsv: ["nlqlvrthafvvljuupcbcw"],
shouldMigrate: true,
cidrSelectionType: 4,
},
additionalCacheNodeProperties: {
driveConfiguration: [
{
physicalPath: "/mcc",
sizeInGb: 500,
cacheNumber: 1,
nginxMapping: "lijygenjq",
},
],
bgpConfiguration: { asnToIpAddressMapping: "pafcimhoog" },
cacheNodePropertiesDetailsIssuesList: ["ex"],
proxyUrlConfiguration: { proxyUrl: "hplstyg" },
proxyUrl: "qhux",
optionalProperty1: "hvpmt",
optionalProperty2: "talanelmsgxvksrzoeeontqkjzbpv",
optionalProperty3: "bxkoxq",
optionalProperty4: "pqlkcekupusoc",
optionalProperty5: "nyvvmrjigqdufzjdvazdca",
},
statusCode: "1",
statusText: "Success",
statusDetails: "djruqvptzxak",
error: {},
},
tags: { key4171: "qtjlszkawsdujzpgohsbw" },
},
);
console.log(result);
}
async function main() {
ispCacheNodesOperationsCreateOrUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api deletes an existing ispCacheNode resource
*
* @summary this api deletes an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function ispCacheNodesDeleteOperationGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.ispCacheNodesOperations.delete(
"rgConnectedCache",
"lvpcosvbfxtpzscakewx",
"wsiruvexelltpbouqxvsogqpxdizcwqwfowybncvjunlakjwcpgmqbdbgzjrsmxlkczxnsxfonhnqqa",
);
}
async function main() {
ispCacheNodesDeleteOperationGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetBgpCidrs_MaximumSet_Gen.json
*/
async function ispCacheNodesResourceBgpCidrsDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.getBgpCidrs(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
);
console.log(result);
}
async function main() {
ispCacheNodesResourceBgpCidrsDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets secrets of the ispCacheNode resource install details
*
* @summary this api gets secrets of the ispCacheNode resource install details
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json
*/
async function ispCacheNodeResourceGetInstallDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.getCacheNodeInstallDetails(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
);
console.log(result);
}
async function main() {
ispCacheNodeResourceGetInstallDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets ispCacheNode resource information
*
* @summary this api gets ispCacheNode resource information
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function ispCacheNodesGetResourceGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.get(
"rgConnectedCache",
"sgtqjsitdrskmgyrrkntszwrrjjkretscpjgaezraucvcwececlelcsorfunrnvxyxcsrg",
"lbsziwmudcjnwnwy",
);
console.log(result);
}
async function main() {
ispCacheNodesGetResourceGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,32 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api retrieves information about all ispCacheNode resources under the given subscription and resource group
*
* @summary this api retrieves information about all ispCacheNode resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_ListByIspCustomerResource_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsListByIspCustomerResource() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCacheNodesOperations.listByIspCustomerResource(
"rgConnectedCache",
"MccRPTest1",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCacheNodesOperationsListByIspCustomerResource();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,30 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api updates an existing ispCacheNode resource
*
* @summary this api updates an existing ispCacheNode resource
* x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Update_MaximumSet_Gen.json
*/
async function ispCacheNodesOperationsUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCacheNodesOperations.update(
"rgConnectedCache",
"MccRPTest1",
"MCCCachenode1",
{ tags: { key1653: "nzjczrhclhkndesgy" } },
);
console.log(result);
}
async function main() {
ispCacheNodesOperationsUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,60 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api creates an ispCustomer with the specified create parameters
*
* @summary this api creates an ispCustomer with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/IspCustomers_CreateOrUpdate_MaximumSet_Gen.json
*/
async function ispCustomerCreateOrUpdateGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.createOrUpdate("rgConnectedCache", "MccRPTest2", {
location: "westus",
properties: {
customer: {
fullyQualifiedResourceId: "uqsbtgae",
customerName: "mkpzynfqihnjfdbaqbqwyhd",
contactEmail: "xquos",
contactPhone: "vue",
contactName: "wxyqjoyoscmvimgwhpitxky",
isEntitled: true,
releaseVersion: 20,
clientTenantId: "fproidkpgvpdnac",
isEnterpriseManaged: true,
shouldMigrate: true,
resendSignupCode: true,
verifySignupCode: true,
verifySignupPhrase: "tprjvttkgmrqlsyicnidhm",
},
additionalCustomerProperties: {
customerEmail: "zdjgibsidydyzm",
customerTransitAsn: "habgklnxqzmozqpazoyejwiphezpi",
customerAsn: "hgrelgnrtdkleisnepfolu",
customerEntitlementSkuId: "b",
customerEntitlementSkuGuid: "rvzmdpxyflgqetvpwupnfaxsweiiz",
customerEntitlementSkuName: "waaqfijr",
customerEntitlementExpiration: new Date("2024-01-30T00:54:04.773Z"),
optionalProperty1: "qhmwxza",
optionalProperty2: "l",
optionalProperty3: "mblwwvbie",
optionalProperty4: "vzuek",
optionalProperty5: "fzjodscdfcdr",
},
error: {},
},
tags: { key1878: "warz" },
});
console.log(result);
}
async function main() {
ispCustomerCreateOrUpdateGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api deletes an existing ispCustomer resource
*
* @summary this api deletes an existing ispCustomer resource
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Delete_MaximumSet_Gen.json
*/
async function ispCustomersDeleteGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.ispCustomers.delete(
"rgConnectedCache",
"hdontfoythjsaeyjhrakckgimgchxwzttbcnvntpvdsgeumxpgnjurptd",
);
}
async function main() {
ispCustomersDeleteGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,25 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to gets the ispCustomer resource information using this get call
*
* @summary gets the ispCustomer resource information using this get call
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Get_MaximumSet_Gen.json
*/
async function ispCustomersGetGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.get("rgConnectedCache", "cmcjfueweicolcjkwmsuvcj");
console.log(result);
}
async function main() {
ispCustomersGetGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets the information about all ispCustomer resources under the given subscription and resource group
*
* @summary this api gets the information about all ispCustomer resources under the given subscription and resource group
* x-ms-original-file: 2023-05-01-preview/IspCustomers_ListByResourceGroup_MaximumSet_Gen.json
*/
async function ispCustomersResourceListByResourceGroupGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCustomers.listByResourceGroup("rgConnectedCache")) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCustomersResourceListByResourceGroupGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api gets information about all ispCustomer resources under the given subscription
*
* @summary this api gets information about all ispCustomer resources under the given subscription
* x-ms-original-file: 2023-05-01-preview/IspCustomers_ListBySubscription_MaximumSet_Gen.json
*/
async function ispCustomerListBySubscriptionGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ispCustomers.listBySubscription()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
ispCustomerListBySubscriptionGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to this api updates an existing ispCustomer resource
*
* @summary this api updates an existing ispCustomer resource
* x-ms-original-file: 2023-05-01-preview/IspCustomers_Update_MaximumSet_Gen.json
*/
async function ispCustomerUpdateDetailsGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.ispCustomers.update("rgConnectedCache", "MccRPTest2", {
tags: { key1653: "nzjczrhclhkndesgy" },
});
console.log(result);
}
async function main() {
ispCustomerUpdateDetailsGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,29 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { ConnectedCacheClient } = require("@azure/arm-connectedcache");
const { DefaultAzureCredential } = require("@azure/identity");
/**
* This sample demonstrates how to list the operations for the provider
*
* @summary list the operations for the provider
* x-ms-original-file: 2023-05-01-preview/Operations_List_MaximumSet_Gen.json
*/
async function listTheOperationsForTheProviderGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "00000000-0000-0000-0000-00000000000";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.operations.list()) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
listTheOperationsForTheProviderGeneratedByMaximumSetRule();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,33 @@
{
"name": "@azure-samples/arm-connectedcache-js-beta",
"private": true,
"version": "1.0.0",
"description": "@azure/arm-connectedcache client library samples for JavaScript (Beta)",
"engines": {
"node": ">=18.0.0"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Azure/azure-sdk-for-js.git",
"directory": "sdk/connectedcache/arm-connectedcache"
},
"keywords": [
"node",
"azure",
"cloud",
"typescript",
"browser",
"isomorphic"
],
"author": "Microsoft Corporation",
"license": "MIT",
"bugs": {
"url": "https://github.com/Azure/azure-sdk-for-js/issues"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/connectedcache/arm-connectedcache",
"dependencies": {
"@azure/arm-connectedcache": "next",
"dotenv": "latest",
"@azure/identity": "^4.2.1"
}
}

Просмотреть файл

@ -0,0 +1 @@
# Feel free to add your own environment variables.

Просмотреть файл

@ -0,0 +1,137 @@
# @azure/arm-connectedcache client library samples for TypeScript (Beta)
These sample programs show how to use the TypeScript client libraries for @azure/arm-connectedcache in some common scenarios.
| **File Name** | **Description** |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| [cacheNodesOperationsCreateorUpdateSample.ts][cachenodesoperationscreateorupdatesample] | creates a cacheNodes with the specified create parameters x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_CreateorUpdate_MaximumSet_Gen.json |
| [cacheNodesOperationsDeleteSample.ts][cachenodesoperationsdeletesample] | deletes an existing cache Node x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Delete_MaximumSet_Gen.json |
| [cacheNodesOperationsGetSample.ts][cachenodesoperationsgetsample] | retrieves the properties of a cacheNodes x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Get_MaximumSet_Gen.json |
| [cacheNodesOperationsListByResourceGroupSample.ts][cachenodesoperationslistbyresourcegroupsample] | retrieves the properties of all ConnectedCache x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListByResourceGroup_MaximumSet_Gen.json |
| [cacheNodesOperationsListBySubscriptionSample.ts][cachenodesoperationslistbysubscriptionsample] | retrieves the properties of all ConnectedCaches x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListBySubscription_MaximumSet_Gen.json |
| [cacheNodesOperationsUpdateSample.ts][cachenodesoperationsupdatesample] | updates an existing Cache Node x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Update_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsCreateOrUpdateSample.ts][enterprisecustomeroperationscreateorupdatesample] | creates a cacheNodes with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsDeleteSample.ts][enterprisecustomeroperationsdeletesample] | deletes an existing customer Enterprise resource x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Delete_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsGetSample.ts][enterprisecustomeroperationsgetsample] | retrieves the properties of a Enterprise customer x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Get_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsListByResourceGroupSample.ts][enterprisecustomeroperationslistbyresourcegroupsample] | retrieves the properties of all ConnectedCache enterpriseCustomers x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListByResourceGroup_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsListBySubscriptionSample.ts][enterprisecustomeroperationslistbysubscriptionsample] | retrieves the properties of all ConnectedCaches x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_ListBySubscription_MaximumSet_Gen.json |
| [enterpriseCustomerOperationsUpdateSample.ts][enterprisecustomeroperationsupdatesample] | updates an existing enterpriseCustomers x-ms-original-file: 2023-05-01-preview/EnterpriseCustomerOperations_Update_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsCreateOrUpdateSample.ts][enterprisemcccachenodesoperationscreateorupdatesample] | this api creates an ispCacheNode with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsDeleteSample.ts][enterprisemcccachenodesoperationsdeletesample] | this api deletes an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Delete_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsSample.ts][enterprisemcccachenodesoperationsgetcachenodeinstalldetailssample] | this api gets secrets of the ispCacheNode resource install details x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsGetSample.ts][enterprisemcccachenodesoperationsgetsample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Get_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceSample.ts][enterprisemcccachenodesoperationslistbyenterprisemcccustomerresourcesample] | this api retrieves information about all ispCacheNode resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_ListByEnterpriseMccCustomerResource_MaximumSet_Gen.json |
| [enterpriseMccCacheNodesOperationsUpdateSample.ts][enterprisemcccachenodesoperationsupdatesample] | this api updates an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCacheNodesOperations_Update_MaximumSet_Gen.json |
| [enterpriseMccCustomersCreateOrUpdateSample.ts][enterprisemcccustomerscreateorupdatesample] | this api creates an enterprise mcc customer with the specified create parameters x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_CreateOrUpdate_MaximumSet_Gen.json |
| [enterpriseMccCustomersDeleteSample.ts][enterprisemcccustomersdeletesample] | this api deletes an existing enterprise mcc customer resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Delete_MaximumSet_Gen.json |
| [enterpriseMccCustomersGetSample.ts][enterprisemcccustomersgetsample] | gets the enterprise mcc customer resource information using this get call x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Get_MaximumSet_Gen.json |
| [enterpriseMccCustomersListByResourceGroupSample.ts][enterprisemcccustomerslistbyresourcegroupsample] | this api gets the information about all enterprise mcc customer resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListByResourceGroup_MaximumSet_Gen.json |
| [enterpriseMccCustomersListBySubscriptionSample.ts][enterprisemcccustomerslistbysubscriptionsample] | this api gets information about all enterpriseMccCustomer resources under the given subscription x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_ListBySubscription_MaximumSet_Gen.json |
| [enterpriseMccCustomersUpdateSample.ts][enterprisemcccustomersupdatesample] | this api updates an existing enterprise mcc customer resource x-ms-original-file: 2023-05-01-preview/EnterpriseMccCustomers_Update_MaximumSet_Gen.json |
| [ispCacheNodesOperationsCreateOrUpdateSample.ts][ispcachenodesoperationscreateorupdatesample] | this api creates an ispCacheNode with the specified create parameters x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_CreateOrUpdate_MaximumSet_Gen.json |
| [ispCacheNodesOperationsDeleteSample.ts][ispcachenodesoperationsdeletesample] | this api deletes an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Delete_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetBgpCidrsSample.ts][ispcachenodesoperationsgetbgpcidrssample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetBgpCidrs_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetCacheNodeInstallDetailsSample.ts][ispcachenodesoperationsgetcachenodeinstalldetailssample] | this api gets secrets of the ispCacheNode resource install details x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_GetCacheNodeInstallDetails_MaximumSet_Gen.json |
| [ispCacheNodesOperationsGetSample.ts][ispcachenodesoperationsgetsample] | this api gets ispCacheNode resource information x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Get_MaximumSet_Gen.json |
| [ispCacheNodesOperationsListByIspCustomerResourceSample.ts][ispcachenodesoperationslistbyispcustomerresourcesample] | this api retrieves information about all ispCacheNode resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_ListByIspCustomerResource_MaximumSet_Gen.json |
| [ispCacheNodesOperationsUpdateSample.ts][ispcachenodesoperationsupdatesample] | this api updates an existing ispCacheNode resource x-ms-original-file: 2023-05-01-preview/IspCacheNodesOperations_Update_MaximumSet_Gen.json |
| [ispCustomersCreateOrUpdateSample.ts][ispcustomerscreateorupdatesample] | this api creates an ispCustomer with the specified create parameters x-ms-original-file: 2023-05-01-preview/IspCustomers_CreateOrUpdate_MaximumSet_Gen.json |
| [ispCustomersDeleteSample.ts][ispcustomersdeletesample] | this api deletes an existing ispCustomer resource x-ms-original-file: 2023-05-01-preview/IspCustomers_Delete_MaximumSet_Gen.json |
| [ispCustomersGetSample.ts][ispcustomersgetsample] | gets the ispCustomer resource information using this get call x-ms-original-file: 2023-05-01-preview/IspCustomers_Get_MaximumSet_Gen.json |
| [ispCustomersListByResourceGroupSample.ts][ispcustomerslistbyresourcegroupsample] | this api gets the information about all ispCustomer resources under the given subscription and resource group x-ms-original-file: 2023-05-01-preview/IspCustomers_ListByResourceGroup_MaximumSet_Gen.json |
| [ispCustomersListBySubscriptionSample.ts][ispcustomerslistbysubscriptionsample] | this api gets information about all ispCustomer resources under the given subscription x-ms-original-file: 2023-05-01-preview/IspCustomers_ListBySubscription_MaximumSet_Gen.json |
| [ispCustomersUpdateSample.ts][ispcustomersupdatesample] | this api updates an existing ispCustomer resource x-ms-original-file: 2023-05-01-preview/IspCustomers_Update_MaximumSet_Gen.json |
| [operationsListSample.ts][operationslistsample] | list the operations for the provider x-ms-original-file: 2023-05-01-preview/Operations_List_MaximumSet_Gen.json |
## Prerequisites
The sample programs are compatible with [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule).
Before running the samples in Node, they must be compiled to JavaScript using the TypeScript compiler. For more information on TypeScript, see the [TypeScript documentation][typescript]. Install the TypeScript compiler using:
```bash
npm install -g typescript
```
You need [an Azure subscription][freesub] to run these sample programs.
Samples retrieve credentials to access the service endpoint from environment variables. Alternatively, edit the source code to include the appropriate credentials. See each individual sample for details on which environment variables/credentials it requires to function.
Adapting the samples to run in the browser may require some additional consideration. For details, please see the [package README][package].
## Setup
To run the samples using the published version of the package:
1. Install the dependencies using `npm`:
```bash
npm install
```
2. Compile the samples:
```bash
npm run build
```
3. Edit the file `sample.env`, adding the correct credentials to access the Azure service and run the samples. Then rename the file from `sample.env` to just `.env`. The sample programs will read this file automatically.
4. Run whichever samples you like (note that some samples may require additional setup, see the table above):
```bash
node dist/cacheNodesOperationsCreateorUpdateSample.js
```
Alternatively, run a single sample with the correct environment variables set (setting up the `.env` file is not required if you do this), for example (cross-platform):
```bash
npx dev-tool run vendored cross-env node dist/cacheNodesOperationsCreateorUpdateSample.js
```
## Next Steps
Take a look at our [API Documentation][apiref] for more information about the APIs that are available in the clients.
[cachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsCreateorUpdateSample.ts
[cachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsDeleteSample.ts
[cachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsGetSample.ts
[cachenodesoperationslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsListByResourceGroupSample.ts
[cachenodesoperationslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsListBySubscriptionSample.ts
[cachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/cacheNodesOperationsUpdateSample.ts
[enterprisecustomeroperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsCreateOrUpdateSample.ts
[enterprisecustomeroperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsDeleteSample.ts
[enterprisecustomeroperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsGetSample.ts
[enterprisecustomeroperationslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsListByResourceGroupSample.ts
[enterprisecustomeroperationslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsListBySubscriptionSample.ts
[enterprisecustomeroperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseCustomerOperationsUpdateSample.ts
[enterprisemcccachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsCreateOrUpdateSample.ts
[enterprisemcccachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsDeleteSample.ts
[enterprisemcccachenodesoperationsgetcachenodeinstalldetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsGetCacheNodeInstallDetailsSample.ts
[enterprisemcccachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsGetSample.ts
[enterprisemcccachenodesoperationslistbyenterprisemcccustomerresourcesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsListByEnterpriseMccCustomerResourceSample.ts
[enterprisemcccachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCacheNodesOperationsUpdateSample.ts
[enterprisemcccustomerscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersCreateOrUpdateSample.ts
[enterprisemcccustomersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersDeleteSample.ts
[enterprisemcccustomersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersGetSample.ts
[enterprisemcccustomerslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersListByResourceGroupSample.ts
[enterprisemcccustomerslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersListBySubscriptionSample.ts
[enterprisemcccustomersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/enterpriseMccCustomersUpdateSample.ts
[ispcachenodesoperationscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsCreateOrUpdateSample.ts
[ispcachenodesoperationsdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsDeleteSample.ts
[ispcachenodesoperationsgetbgpcidrssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsGetBgpCidrsSample.ts
[ispcachenodesoperationsgetcachenodeinstalldetailssample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsGetCacheNodeInstallDetailsSample.ts
[ispcachenodesoperationsgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsGetSample.ts
[ispcachenodesoperationslistbyispcustomerresourcesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsListByIspCustomerResourceSample.ts
[ispcachenodesoperationsupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCacheNodesOperationsUpdateSample.ts
[ispcustomerscreateorupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersCreateOrUpdateSample.ts
[ispcustomersdeletesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersDeleteSample.ts
[ispcustomersgetsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersGetSample.ts
[ispcustomerslistbyresourcegroupsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersListByResourceGroupSample.ts
[ispcustomerslistbysubscriptionsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersListBySubscriptionSample.ts
[ispcustomersupdatesample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/ispCustomersUpdateSample.ts
[operationslistsample]: https://github.com/Azure/azure-sdk-for-js/blob/main/sdk/connectedcache/arm-connectedcache/samples/v1-beta/typescript/src/operationsListSample.ts
[apiref]: https://docs.microsoft.com/javascript/api/@azure/arm-connectedcache?view=azure-node-preview
[freesub]: https://azure.microsoft.com/free/
[package]: https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/connectedcache/arm-connectedcache/README.md
[typescript]: https://www.typescriptlang.org/docs/home.html

Просмотреть файл

@ -0,0 +1,42 @@
{
"name": "@azure-samples/arm-connectedcache-ts-beta",
"private": true,
"version": "1.0.0",
"description": "@azure/arm-connectedcache client library samples for TypeScript (Beta)",
"engines": {
"node": ">=18.0.0"
},
"scripts": {
"build": "tsc",
"prebuild": "rimraf dist/"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Azure/azure-sdk-for-js.git",
"directory": "sdk/connectedcache/arm-connectedcache"
},
"keywords": [
"node",
"azure",
"cloud",
"typescript",
"browser",
"isomorphic"
],
"author": "Microsoft Corporation",
"license": "MIT",
"bugs": {
"url": "https://github.com/Azure/azure-sdk-for-js/issues"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/connectedcache/arm-connectedcache",
"dependencies": {
"@azure/arm-connectedcache": "next",
"dotenv": "latest",
"@azure/identity": "^4.2.1"
},
"devDependencies": {
"@types/node": "^18.0.0",
"typescript": "~5.6.2",
"rimraf": "latest"
}
}

Просмотреть файл

@ -0,0 +1 @@
# Feel free to add your own environment variables.

Просмотреть файл

@ -0,0 +1,38 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to creates a cacheNodes with the specified create parameters
*
* @summary creates a cacheNodes with the specified create parameters
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_CreateorUpdate_MaximumSet_Gen.json
*/
async function cacheNodesOperationsCreateorUpdate() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.createorUpdate(
"rgConnectedCache",
"lwrsyhvfpcfrwrim",
{
location: "westus",
properties: {
statusCode: "movtzupooyhdqk",
statusText: "bjnsrpzaofjntleoesjwammgbi",
statusDetails: "quuziibkwtgf",
error: {},
},
tags: { key8256: "oreqiywrjkmate" },
},
);
console.log(result);
}
async function main() {
cacheNodesOperationsCreateorUpdate();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,27 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to deletes an existing cache Node
*
* @summary deletes an existing cache Node
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Delete_MaximumSet_Gen.json
*/
async function cacheNodesOperationsDelete() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
await client.cacheNodesOperations.delete(
"rgConnectedCache",
"otvtvhmovthjwzjzbsqkbnmpcmmeianpqxmmaspvdczmrenquxigrtuarmlcmvsnaclhcbw",
);
}
async function main() {
cacheNodesOperationsDelete();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,28 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of a cacheNodes
*
* @summary retrieves the properties of a cacheNodes
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_Get_MaximumSet_Gen.json
*/
async function cacheNodesOperationsGet() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const result = await client.cacheNodesOperations.get(
"rgConnectedCache",
"nqoxkgorhuzbhjwcegymzqbeydzjupemekt",
);
console.log(result);
}
async function main() {
cacheNodesOperationsGet();
}
main().catch(console.error);

Просмотреть файл

@ -0,0 +1,31 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ConnectedCacheClient } from "@azure/arm-connectedcache";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to retrieves the properties of all ConnectedCache
*
* @summary retrieves the properties of all ConnectedCache
* x-ms-original-file: 2023-05-01-preview/CacheNodesOperations_ListByResourceGroup_MaximumSet_Gen.json
*/
async function cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule() {
const credential = new DefaultAzureCredential();
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const client = new ConnectedCacheClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.cacheNodesOperations.listByResourceGroup(
"rgConnectedCache",
)) {
resArray.push(item);
}
console.log(resArray);
}
async function main() {
cacheNodesPrivatePreviewLegacyGetOperationListByResourceGroupGeneratedByMaximumSetRule();
}
main().catch(console.error);

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше