This commit is contained in:
colawwj 2022-04-20 16:17:25 +08:00 коммит произвёл GitHub
Родитель 94ef54776d
Коммит 5b5d787833
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
726 изменённых файлов: 30328 добавлений и 223 удалений

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

@ -13526,27 +13526,28 @@ packages:
dev: false
file:projects/arm-synapse.tgz:
resolution: {integrity: sha512-pF5nCbEJkFS+VU4cQ2zU0FtCrb9mix9XYvXfJxtpAgCvqkV1F9KSHE2nqH87y6ZrziviyJLsHvNwq79+LWGK4A==, tarball: file:projects/arm-synapse.tgz}
resolution: {integrity: sha512-i/SDXw3f7zBa2HF9/SaTj71qb9x4/Ik2qJQFMQ3xM0SON+o/dxJ5+b+UotJJ3VIVAte7pqIDe6eiMbp+DNS9yA==, tarball: file:projects/arm-synapse.tgz}
name: '@rush-temp/arm-synapse'
version: 0.0.0
dependencies:
'@azure-tools/test-recorder': 1.0.2
'@azure/identity': 2.0.4
'@microsoft/api-extractor': 7.22.1
'@rollup/plugin-commonjs': 11.0.2_rollup@1.32.1
'@rollup/plugin-json': 4.1.0_rollup@1.32.1
'@rollup/plugin-multi-entry': 3.0.1_rollup@1.32.1
'@rollup/plugin-node-resolve': 8.4.0_rollup@1.32.1
'@rollup/plugin-commonjs': 21.0.3_rollup@2.70.1
'@rollup/plugin-json': 4.1.0_rollup@2.70.1
'@rollup/plugin-multi-entry': 4.1.0_rollup@2.70.1
'@rollup/plugin-node-resolve': 13.2.0_rollup@2.70.1
cross-env: 7.0.3
mkdirp: 1.0.4
mocha: 7.2.0
rimraf: 3.0.2
rollup: 1.32.1
rollup-plugin-sourcemaps: 0.4.2_rollup@1.32.1
rollup: 2.70.1
rollup-plugin-sourcemaps: 0.6.3_rollup@2.70.1
tslib: 2.3.1
typescript: 4.2.4
uglify-js: 3.15.4
transitivePeerDependencies:
- '@types/node'
- debug
- encoding
- supports-color

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

@ -1,15 +1,26 @@
# Release History
## 8.1.0-beta.1 (2022-04-20)
**Features**
## 8.0.1 (Unreleased)
### Features Added
### Breaking Changes
### Bugs Fixed
### Other Changes
- Added operation group WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettings
- Added Interface DedicatedSQLminimalTlsSettingsListResult
- Added Interface DedicatedSQLminimalTlsSettingsPatchInfo
- Added Interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetOptionalParams
- Added Interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListNextOptionalParams
- Added Interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListOptionalParams
- Added Interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateOptionalParams
- Added Type Alias DedicatedSQLminimalTlsSettings
- Added Type Alias DedicatedSQLMinimalTlsSettingsName
- Added Type Alias WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetResponse
- Added Type Alias WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListNextResponse
- Added Type Alias WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListResponse
- Added Type Alias WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateResponse
- Class SynapseManagementClient has a new parameter workspaceManagedSqlServerDedicatedSQLMinimalTlsSettings
- Added Enum KnownDedicatedSQLMinimalTlsSettingsName
## 8.0.0 (2022-01-13)
The package of @azure/arm-synapse is using our next generation design principles since version 8.0.0, which contains breaking changes.

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

@ -1,21 +0,0 @@
The MIT License (MIT)
Copyright (c) 2021 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.

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

@ -16,6 +16,8 @@ Azure Synapse Analytics Management Client
- [LTS versions of Node.js](https://nodejs.org/about/releases/)
- 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].
@ -49,8 +51,17 @@ For more information about how to create an Azure AD Application check out [this
```javascript
const { SynapseManagementClient } = require("@azure/arm-synapse");
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 SynapseManagementClient(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 SynapseManagementClient(credential, subscriptionId);
```

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

@ -1,7 +1,8 @@
{
"commit": "1f1d5b0b9ce6cc94605b2fd619dce374fb6e033a",
"commit": "8a9bd9c5b65e5c3e5a8536f3c5b2b15bf9920b5d",
"readme": "specification/synapse/resource-manager/readme.md",
"autorest_command": "autorest --version=3.1.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\mydev\\azure-sdk-for-js ../azure-rest-api-specs/specification/synapse/resource-manager/readme.md --use=@autorest/typescript@6.0.0-alpha.16.20211217.1",
"autorest_command": "autorest --version=3.7.3 --typescript --modelerfour.lenient-model-deduplication --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\work\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\synapse\\resource-manager\\readme.md --use=@autorest/typescript@6.0.0-alpha.19.20220408.1 --generate-sample=true",
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
"use": "@autorest/typescript@6.0.0-alpha.16.20211217.1"
"release_tool": "@azure-tools/js-sdk-release-tools@2.2.6",
"use": "@autorest/typescript@6.0.0-alpha.19.20220408.1"
}

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

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

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

@ -3,7 +3,7 @@
"sdk-type": "mgmt",
"author": "Microsoft Corporation",
"description": "A generated SDK for SynapseManagementClient.",
"version": "8.0.1",
"version": "8.1.0-beta.1",
"engines": {
"node": ">=12.0.0"
},
@ -11,9 +11,9 @@
"@azure/core-lro": "^2.2.0",
"@azure/abort-controller": "^1.0.0",
"@azure/core-paging": "^1.2.0",
"@azure/core-client": "^1.0.0",
"@azure/core-client": "^1.5.0",
"@azure/core-auth": "^1.3.0",
"@azure/core-rest-pipeline": "^1.1.0",
"@azure/core-rest-pipeline": "^1.8.0",
"tslib": "^2.2.0"
},
"keywords": [
@ -29,13 +29,13 @@
"types": "./types/arm-synapse.d.ts",
"devDependencies": {
"@microsoft/api-extractor": "^7.18.11",
"@rollup/plugin-commonjs": "11.0.2",
"@rollup/plugin-json": "^4.0.0",
"@rollup/plugin-multi-entry": "^3.0.0",
"@rollup/plugin-node-resolve": "^8.0.0",
"@rollup/plugin-commonjs": "^21.0.1",
"@rollup/plugin-json": "^4.1.0",
"@rollup/plugin-multi-entry": "^4.1.0",
"@rollup/plugin-node-resolve": "^13.1.3",
"mkdirp": "^1.0.4",
"rollup": "^1.16.3",
"rollup-plugin-sourcemaps": "^0.4.2",
"rollup": "^2.66.1",
"rollup-plugin-sourcemaps": "^0.6.3",
"typescript": "~4.2.0",
"uglify-js": "^3.4.9",
"rimraf": "^3.0.0",
@ -98,5 +98,21 @@
"docs": "echo skipped"
},
"sideEffects": false,
"autoPublish": true
}
"//metadata": {
"constantPaths": [
{
"path": "src/synapseManagementClient.ts",
"prefix": "packageDetails"
}
]
},
"autoPublish": true,
"//sampleConfiguration": {
"productName": "",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-synapse?view=azure-node-preview"
}
}

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

@ -554,6 +554,26 @@ export type DataWarehouseUserActivityName = string;
// @public
export type DayOfWeek = string;
// @public
export type DedicatedSQLminimalTlsSettings = ProxyResource & {
readonly location?: string;
minimalTlsVersion?: string;
};
// @public
export interface DedicatedSQLminimalTlsSettingsListResult {
readonly nextLink?: string;
readonly value?: DedicatedSQLminimalTlsSettings[];
}
// @public
export type DedicatedSQLMinimalTlsSettingsName = string;
// @public
export interface DedicatedSQLminimalTlsSettingsPatchInfo {
minimalTlsVersion?: string;
}
// @public
export type DefaultPrincipalsModificationKind = string;
@ -1570,6 +1590,12 @@ export enum KnownDayOfWeek {
Wednesday = "Wednesday"
}
// @public
export enum KnownDedicatedSQLMinimalTlsSettingsName {
// (undocumented)
Default = "default"
}
// @public
export enum KnownDefaultPrincipalsModificationKind {
// (undocumented)
@ -4964,6 +4990,8 @@ export class SynapseManagementClient extends coreClient.ServiceClient {
// (undocumented)
workspaceManagedSqlServerBlobAuditingPolicies: WorkspaceManagedSqlServerBlobAuditingPolicies;
// (undocumented)
workspaceManagedSqlServerDedicatedSQLMinimalTlsSettings: WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettings;
// (undocumented)
workspaceManagedSqlServerEncryptionProtector: WorkspaceManagedSqlServerEncryptionProtector;
// (undocumented)
workspaceManagedSqlServerExtendedBlobAuditingPolicies: WorkspaceManagedSqlServerExtendedBlobAuditingPolicies;
@ -5294,6 +5322,44 @@ export interface WorkspaceManagedSqlServerBlobAuditingPoliciesListByWorkspaceOpt
// @public
export type WorkspaceManagedSqlServerBlobAuditingPoliciesListByWorkspaceResponse = ServerBlobAuditingPolicyListResult;
// @public
export interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettings {
beginUpdate(resourceGroupName: string, workspaceName: string, dedicatedSQLminimalTlsSettingsName: DedicatedSQLMinimalTlsSettingsName, parameters: DedicatedSQLminimalTlsSettings, options?: WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateOptionalParams): Promise<PollerLike<PollOperationState<WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateResponse>, WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateResponse>>;
beginUpdateAndWait(resourceGroupName: string, workspaceName: string, dedicatedSQLminimalTlsSettingsName: DedicatedSQLMinimalTlsSettingsName, parameters: DedicatedSQLminimalTlsSettings, options?: WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateOptionalParams): Promise<WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateResponse>;
get(resourceGroupName: string, workspaceName: string, dedicatedSQLminimalTlsSettingsName: string, options?: WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetOptionalParams): Promise<WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetResponse>;
list(resourceGroupName: string, workspaceName: string, options?: WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListOptionalParams): PagedAsyncIterableIterator<DedicatedSQLminimalTlsSettings>;
}
// @public
export interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetOptionalParams extends coreClient.OperationOptions {
}
// @public
export type WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsGetResponse = DedicatedSQLminimalTlsSettings;
// @public
export interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListNextOptionalParams extends coreClient.OperationOptions {
}
// @public
export type WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListNextResponse = DedicatedSQLminimalTlsSettingsListResult;
// @public
export interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListOptionalParams extends coreClient.OperationOptions {
}
// @public
export type WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsListResponse = DedicatedSQLminimalTlsSettingsListResult;
// @public
export interface WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateOptionalParams extends coreClient.OperationOptions {
resumeFrom?: string;
updateIntervalInMs?: number;
}
// @public
export type WorkspaceManagedSqlServerDedicatedSQLMinimalTlsSettingsUpdateResponse = DedicatedSQLminimalTlsSettings;
// @public
export interface WorkspaceManagedSqlServerEncryptionProtector {
beginCreateOrUpdate(resourceGroupName: string, workspaceName: string, encryptionProtectorName: EncryptionProtectorName, parameters: EncryptionProtector, options?: WorkspaceManagedSqlServerEncryptionProtectorCreateOrUpdateOptionalParams): Promise<PollerLike<PollOperationState<WorkspaceManagedSqlServerEncryptionProtectorCreateOrUpdateResponse>, WorkspaceManagedSqlServerEncryptionProtectorCreateOrUpdateResponse>>;

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

@ -14,62 +14,14 @@ import json from "@rollup/plugin-json";
import nodeBuiltins from "builtin-modules";
/**
* Gets the proper configuration needed for rollup's commonJS plugin for @opentelemetry/api.
*
* NOTE: this manual configuration is only needed because OpenTelemetry uses an
* __exportStar downleveled helper function to declare its exports which confuses
* rollup's automatic discovery mechanism.
*
* @returns an object reference that can be `...`'d into your cjs() configuration.
*/
export function openTelemetryCommonJs() {
const namedExports = {};
for (const key of [
"@opentelemetry/api",
"@azure/core-tracing/node_modules/@opentelemetry/api"
]) {
namedExports[key] = [
"SpanKind",
"TraceFlags",
"getSpan",
"setSpan",
"SpanStatusCode",
"getSpanContext",
"setSpanContext"
];
}
const releasedOpenTelemetryVersions = ["0.10.2", "1.0.0-rc.0"];
for (const version of releasedOpenTelemetryVersions) {
namedExports[
// working around a limitation in the rollup common.js plugin - it's not able to resolve these modules so the named exports listed above will not get applied. We have to drill down to the actual path.
`../../../common/temp/node_modules/.pnpm/@opentelemetry/api@${version}/node_modules/@opentelemetry/api/build/src/index.js`
] = [
"SpanKind",
"TraceFlags",
"getSpan",
"setSpan",
"StatusCode",
"CanonicalCode",
"getSpanContext",
"setSpanContext"
];
}
return namedExports;
}
// #region Warning Handler
/**
* A function that can determine whether a rollupwarning should be ignored. If
* A function that can determine whether a rollup warning should be ignored. If
* the function returns `true`, then the warning will not be displayed.
*/
function ignoreNiseSinonEvalWarnings(warning) {
function ignoreNiseSinonEval(warning) {
return (
warning.code === "EVAL" &&
warning.id &&
@ -78,17 +30,14 @@ function ignoreNiseSinonEvalWarnings(warning) {
);
}
function ignoreChaiCircularDependencyWarnings(warning) {
function ignoreChaiCircularDependency(warning) {
return (
warning.code === "CIRCULAR_DEPENDENCY" &&
warning.importer && warning.importer.includes("node_modules/chai") === true
);
}
const warningInhibitors = [
ignoreChaiCircularDependencyWarnings,
ignoreNiseSinonEvalWarnings
];
const warningInhibitors = [ignoreChaiCircularDependency, ignoreNiseSinonEval];
/**
* Construct a warning handler for the shared rollup configuration
@ -122,22 +71,7 @@ function makeBrowserTestConfig() {
nodeResolve({
mainFields: ["module", "browser"]
}),
cjs({
namedExports: {
// Chai's strange internal architecture makes it impossible to statically
// analyze its exports.
chai: [
"version",
"use",
"util",
"config",
"expect",
"should",
"assert"
],
...openTelemetryCommonJs()
}
}),
cjs(),
json(),
sourcemaps()
//viz({ filename: "dist-test/browser-stats.html", sourcemap: true })
@ -173,7 +107,7 @@ export function makeConfig(pkg, options) {
],
output: { file: "dist/index.js", format: "cjs", sourcemap: true },
preserveSymlinks: false,
plugins: [sourcemaps(), nodeResolve(), cjs()]
plugins: [sourcemaps(), nodeResolve()]
};
const config = [baseConfig];

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

@ -0,0 +1,4 @@
# App registration secret for AAD authentication
AZURE_CLIENT_SECRET=
AZURE_CLIENT_ID=
AZURE_TENANT_ID=

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

@ -0,0 +1,44 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
AzureADOnlyAuthentication,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create or Update a Azure Active Directory only authentication property for the workspaces
*
* @summary Create or Update a Azure Active Directory only authentication property for the workspaces
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/CreateOrUpdateAzureADOnlyAuthentication.json
*/
async function createOrUpdateAzureActiveDirectoryOnlyAuthenticationProperty() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "workspace-6852";
const workspaceName = "workspace-2080";
const azureADOnlyAuthenticationName = "default";
const azureADOnlyAuthenticationInfo: AzureADOnlyAuthentication = {
azureADOnlyAuthentication: true
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.azureADOnlyAuthentications.beginCreateAndWait(
resourceGroupName,
workspaceName,
azureADOnlyAuthenticationName,
azureADOnlyAuthenticationInfo
);
console.log(result);
}
createOrUpdateAzureActiveDirectoryOnlyAuthenticationProperty().catch(
console.error
);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a Azure Active Directory only authentication property
*
* @summary Gets a Azure Active Directory only authentication property
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/GetAzureADOnlyAuthentication.json
*/
async function getAzureActiveDirectoryOnlyAuthenticationProperty() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "workspace-6852";
const workspaceName = "workspace-2080";
const azureADOnlyAuthenticationName = "default";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.azureADOnlyAuthentications.get(
resourceGroupName,
workspaceName,
azureADOnlyAuthenticationName
);
console.log(result);
}
getAzureActiveDirectoryOnlyAuthenticationProperty().catch(console.error);

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

@ -0,0 +1,36 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a list of Azure Active Directory only authentication property for a workspace
*
* @summary Gets a list of Azure Active Directory only authentication property for a workspace
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ListAzureADOnlyAuthentication.json
*/
async function getAListOfAzureActiveDirectoryOnlyAuthenticationProperty() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "workspace-6852";
const workspaceName = "workspace-2080";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.azureADOnlyAuthentications.list(
resourceGroupName,
workspaceName
)) {
resArray.push(item);
}
console.log(resArray);
}
getAListOfAzureActiveDirectoryOnlyAuthenticationProperty().catch(console.error);

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

@ -0,0 +1,52 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
BigDataPoolResourceInfo,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create a new Big Data pool.
*
* @summary Create a new Big Data pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/CreateOrUpdateBigDataPool.json
*/
async function createOrUpdateABigDataPool() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const bigDataPoolName = "ExamplePool";
const bigDataPoolInfo: BigDataPoolResourceInfo = {
autoPause: { delayInMinutes: 15, enabled: true },
autoScale: { enabled: true, maxNodeCount: 50, minNodeCount: 3 },
defaultSparkLogFolder: "/logs",
libraryRequirements: { content: "", filename: "requirements.txt" },
location: "West US 2",
nodeCount: 4,
nodeSize: "Medium",
nodeSizeFamily: "MemoryOptimized",
sparkEventsFolder: "/events",
sparkVersion: "2.4",
tags: { key: "value" }
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.bigDataPools.beginCreateOrUpdateAndWait(
resourceGroupName,
workspaceName,
bigDataPoolName,
bigDataPoolInfo
);
console.log(result);
}
createOrUpdateABigDataPool().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Delete a Big Data pool from the workspace.
*
* @summary Delete a Big Data pool from the workspace.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/DeleteBigDataPool.json
*/
async function deleteABigDataPool() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const bigDataPoolName = "ExamplePool";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.bigDataPools.beginDeleteAndWait(
resourceGroupName,
workspaceName,
bigDataPoolName
);
console.log(result);
}
deleteABigDataPool().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get a Big Data pool.
*
* @summary Get a Big Data pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/GetBigDataPool.json
*/
async function getABigDataPool() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const bigDataPoolName = "ExamplePool";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.bigDataPools.get(
resourceGroupName,
workspaceName,
bigDataPoolName
);
console.log(result);
}
getABigDataPool().catch(console.error);

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

@ -0,0 +1,36 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to List Big Data pools in a workspace.
*
* @summary List Big Data pools in a workspace.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/ListBigDataPoolsInWorkspace.json
*/
async function listBigDataPoolsInAWorkspace() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.bigDataPools.listByWorkspace(
resourceGroupName,
workspaceName
)) {
resArray.push(item);
}
console.log(resArray);
}
listBigDataPoolsInAWorkspace().catch(console.error);

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

@ -0,0 +1,40 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
BigDataPoolPatchInfo,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Patch a Big Data pool.
*
* @summary Patch a Big Data pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/UpdateBigDataPool.json
*/
async function updateABigDataPool() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const bigDataPoolName = "ExamplePool";
const bigDataPoolPatchInfo: BigDataPoolPatchInfo = { tags: { key: "value" } };
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.bigDataPools.update(
resourceGroupName,
workspaceName,
bigDataPoolName,
bigDataPoolPatchInfo
);
console.log(result);
}
updateABigDataPool().catch(console.error);

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

@ -0,0 +1,65 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { DataMaskingPolicy, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking policy
*
* @summary Creates or updates a Sql pool data masking policy
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingPolicyCreateOrUpdateMax.json
*/
async function createOrUpdateDataMaskingPolicyMax() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const parameters: DataMaskingPolicy = {
dataMaskingState: "Enabled",
exemptPrincipals: "testuser;"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingPolicies.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingPolicyMax().catch(console.error);
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking policy
*
* @summary Creates or updates a Sql pool data masking policy
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingPolicyCreateOrUpdateMin.json
*/
async function createOrUpdateDataMaskingPolicyMin() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const parameters: DataMaskingPolicy = { dataMaskingState: "Enabled" };
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingPolicies.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingPolicyMin().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a Sql pool data masking policy.
*
* @summary Gets a Sql pool data masking policy.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingPolicyGet.json
*/
async function getDataMaskingPolicy() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingPolicies.get(
resourceGroupName,
workspaceName,
sqlPoolName
);
console.log(result);
}
getDataMaskingPolicy().catch(console.error);

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

@ -0,0 +1,147 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { DataMaskingRule, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking rule.
*
* @summary Creates or updates a Sql pool data masking rule.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleCreateOrUpdateDefaultMax.json
*/
async function createOrUpdateDataMaskingRuleForDefaultMax() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const dataMaskingRuleName = "rule1";
const parameters: DataMaskingRule = {
aliasName: "nickname",
columnName: "test1",
maskingFunction: "Default",
ruleState: "Enabled",
schemaName: "dbo",
tableName: "Table_1"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingRules.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
dataMaskingRuleName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingRuleForDefaultMax().catch(console.error);
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking rule.
*
* @summary Creates or updates a Sql pool data masking rule.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleCreateOrUpdateDefaultMin.json
*/
async function createOrUpdateDataMaskingRuleForDefaultMin() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const dataMaskingRuleName = "rule1";
const parameters: DataMaskingRule = {
columnName: "test1",
maskingFunction: "Default",
schemaName: "dbo",
tableName: "Table_1"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingRules.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
dataMaskingRuleName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingRuleForDefaultMin().catch(console.error);
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking rule.
*
* @summary Creates or updates a Sql pool data masking rule.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleCreateOrUpdateNumber.json
*/
async function createOrUpdateDataMaskingRuleForNumbers() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const dataMaskingRuleName = "rule1";
const parameters: DataMaskingRule = {
columnName: "test1",
maskingFunction: "Number",
numberFrom: "0",
numberTo: "2",
schemaName: "dbo",
tableName: "Table_1"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingRules.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
dataMaskingRuleName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingRuleForNumbers().catch(console.error);
/**
* This sample demonstrates how to Creates or updates a Sql pool data masking rule.
*
* @summary Creates or updates a Sql pool data masking rule.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleCreateOrUpdateText.json
*/
async function createOrUpdateDataMaskingRuleForText() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const dataMaskingRuleName = "rule1";
const parameters: DataMaskingRule = {
columnName: "test1",
maskingFunction: "Text",
prefixSize: "1",
replacementString: "asdf",
schemaName: "dbo",
suffixSize: "0",
tableName: "Table_1"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingRules.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
dataMaskingRuleName,
parameters
);
console.log(result);
}
createOrUpdateDataMaskingRuleForText().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets the specific Sql pool data masking rule.
*
* @summary Gets the specific Sql pool data masking rule.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleGet.json
*/
async function getDataMaskingRule() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const dataMaskingRuleName = "rule1";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.dataMaskingRules.get(
resourceGroupName,
workspaceName,
sqlPoolName,
dataMaskingRuleName
);
console.log(result);
}
getDataMaskingRule().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a list of Sql pool data masking rules.
*
* @summary Gets a list of Sql pool data masking rules.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DataMaskingRuleList.json
*/
async function listDataMaskingRules() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "sqlcrudtest-6852";
const workspaceName = "sqlcrudtest-2080";
const sqlPoolName = "sqlcrudtest-331";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.dataMaskingRules.listBySqlPool(
resourceGroupName,
workspaceName,
sqlPoolName
)) {
resArray.push(item);
}
console.log(resArray);
}
listDataMaskingRules().catch(console.error);

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

@ -0,0 +1,119 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
ExtendedSqlPoolBlobAuditingPolicy,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates an extended Sql pool's blob auditing policy.
*
* @summary Creates or updates an extended Sql pool's blob auditing policy.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ExtendedSqlPoolAzureMonitorAuditingCreateMin.json
*/
async function createOrUpdateAnExtendedSqlPoolAzureMonitorAuditingPolicyWithMinimalParameters() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "blobauditingtest-4799";
const workspaceName = "blobauditingtest-6440";
const sqlPoolName = "testdb";
const parameters: ExtendedSqlPoolBlobAuditingPolicy = {
isAzureMonitorTargetEnabled: true,
state: "Enabled"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.extendedSqlPoolBlobAuditingPolicies.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
parameters
);
console.log(result);
}
createOrUpdateAnExtendedSqlPoolAzureMonitorAuditingPolicyWithMinimalParameters().catch(
console.error
);
/**
* This sample demonstrates how to Creates or updates an extended Sql pool's blob auditing policy.
*
* @summary Creates or updates an extended Sql pool's blob auditing policy.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ExtendedSqlPoolBlobAuditingCreateMax.json
*/
async function createOrUpdateAnExtendedSqlPoolBlobAuditingPolicyWithAllParameters() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "blobauditingtest-4799";
const workspaceName = "blobauditingtest-6440";
const sqlPoolName = "testdb";
const parameters: ExtendedSqlPoolBlobAuditingPolicy = {
auditActionsAndGroups: [
"DATABASE_LOGOUT_GROUP",
"DATABASE_ROLE_MEMBER_CHANGE_GROUP",
"UPDATE on database::TestDatabaseName by public"
],
isAzureMonitorTargetEnabled: true,
isStorageSecondaryKeyInUse: false,
predicateExpression: "statement = 'select 1'",
retentionDays: 6,
state: "Enabled",
storageAccountAccessKey:
"sdlfkjabc+sdlfkjsdlkfsjdfLDKFTERLKFDFKLjsdfksjdflsdkfD2342309432849328476458/3RSD==",
storageAccountSubscriptionId: "00000000-1234-0000-5678-000000000000",
storageEndpoint: "https://mystorage.blob.core.windows.net"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.extendedSqlPoolBlobAuditingPolicies.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
parameters
);
console.log(result);
}
createOrUpdateAnExtendedSqlPoolBlobAuditingPolicyWithAllParameters().catch(
console.error
);
/**
* This sample demonstrates how to Creates or updates an extended Sql pool's blob auditing policy.
*
* @summary Creates or updates an extended Sql pool's blob auditing policy.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ExtendedSqlPoolBlobAuditingCreateMin.json
*/
async function createOrUpdateAnExtendedSqlPoolBlobAuditingPolicyWithMinimalParameters() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "blobauditingtest-4799";
const workspaceName = "blobauditingtest-6440";
const sqlPoolName = "testdb";
const parameters: ExtendedSqlPoolBlobAuditingPolicy = {
state: "Enabled",
storageAccountAccessKey:
"sdlfkjabc+sdlfkjsdlkfsjdfLDKFTERLKFDFKLjsdfksjdflsdkfD2342309432849328476458/3RSD==",
storageEndpoint: "https://mystorage.blob.core.windows.net"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.extendedSqlPoolBlobAuditingPolicies.createOrUpdate(
resourceGroupName,
workspaceName,
sqlPoolName,
parameters
);
console.log(result);
}
createOrUpdateAnExtendedSqlPoolBlobAuditingPolicyWithMinimalParameters().catch(
console.error
);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets an extended Sql pool's blob auditing policy.
*
* @summary Gets an extended Sql pool's blob auditing policy.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ExtendedSqlPoolBlobAuditingGet.json
*/
async function getAnExtendedDatabaseBlobAuditingPolicy() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "blobauditingtest-6852";
const workspaceName = "blobauditingtest-2080";
const sqlPoolName = "testdb";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.extendedSqlPoolBlobAuditingPolicies.get(
resourceGroupName,
workspaceName,
sqlPoolName
);
console.log(result);
}
getAnExtendedDatabaseBlobAuditingPolicy().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Lists extended auditing settings of a Sql pool.
*
* @summary Lists extended auditing settings of a Sql pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/SqlPoolExtendedAuditingSettingsList.json
*/
async function listExtendedAuditingSettingsOfADatabase() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "blobauditingtest-6852";
const workspaceName = "blobauditingtest-2080";
const sqlPoolName = "testdb";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.extendedSqlPoolBlobAuditingPolicies.listBySqlPool(
resourceGroupName,
workspaceName,
sqlPoolName
)) {
resArray.push(item);
}
console.log(resArray);
}
listExtendedAuditingSettingsOfADatabase().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to List authentication keys in an integration runtime
*
* @summary List authentication keys in an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_ListAuthKeys.json
*/
async function listAuthKeys() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeAuthKeysOperations.list(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
listAuthKeys().catch(console.error);

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

@ -0,0 +1,42 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
IntegrationRuntimeRegenerateKeyParameters,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Regenerate the authentication key for an integration runtime
*
* @summary Regenerate the authentication key for an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_RegenerateAuthKey.json
*/
async function regenerateAuthKey() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const regenerateKeyParameters: IntegrationRuntimeRegenerateKeyParameters = {
keyName: "authKey2"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeAuthKeysOperations.regenerate(
resourceGroupName,
workspaceName,
integrationRuntimeName,
regenerateKeyParameters
);
console.log(result);
}
regenerateAuthKey().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get connection info for an integration runtime
*
* @summary Get connection info for an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_GetConnectionInfo.json
*/
async function getConnectionInfo() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeConnectionInfos.get(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
getConnectionInfo().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Force the integration runtime to synchronize credentials across integration runtime nodes, and this will override the credentials across all worker nodes with those available on the dispatcher node. If you already have the latest credential backup file, you should manually import it (preferred) on any self-hosted integration runtime node than using this API directly.
*
* @summary Force the integration runtime to synchronize credentials across integration runtime nodes, and this will override the credentials across all worker nodes with those available on the dispatcher node. If you already have the latest credential backup file, you should manually import it (preferred) on any self-hosted integration runtime node than using this API directly.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_SyncCredentials.json
*/
async function syncCredentials() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeCredentials.sync(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
syncCredentials().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get monitoring data for an integration runtime
*
* @summary Get monitoring data for an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeMonitoringData_List.json
*/
async function getMonitoringData() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeMonitoringDataOperations.list(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
getMonitoringData().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get the IP address of an integration runtime node
*
* @summary Get the IP address of an integration runtime node
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeNodes_GetIpAddress.json
*/
async function getIntegrationRuntimeNodeIPAddress() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const nodeName = "Node_1";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeNodeIpAddressOperations.get(
resourceGroupName,
workspaceName,
integrationRuntimeName,
nodeName
);
console.log(result);
}
getIntegrationRuntimeNodeIPAddress().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Delete an integration runtime node
*
* @summary Delete an integration runtime node
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeNodes_Delete.json
*/
async function deleteIntegrationRuntimeNode() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const nodeName = "Node_1";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeNodes.delete(
resourceGroupName,
workspaceName,
integrationRuntimeName,
nodeName
);
console.log(result);
}
deleteIntegrationRuntimeNode().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get an integration runtime node
*
* @summary Get an integration runtime node
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeNodes_Get.json
*/
async function getIntegrationRuntimeNode() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const nodeName = "Node_1";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeNodes.get(
resourceGroupName,
workspaceName,
integrationRuntimeName,
nodeName
);
console.log(result);
}
getIntegrationRuntimeNode().catch(console.error);

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

@ -0,0 +1,44 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
UpdateIntegrationRuntimeNodeRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create an integration runtime node
*
* @summary Create an integration runtime node
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeNodes_Update.json
*/
async function updateIntegrationRuntimeNode() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const nodeName = "Node_1";
const updateIntegrationRuntimeNodeRequest: UpdateIntegrationRuntimeNodeRequest = {
concurrentJobsLimit: 2
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeNodes.update(
resourceGroupName,
workspaceName,
integrationRuntimeName,
nodeName,
updateIntegrationRuntimeNodeRequest
);
console.log(result);
}
updateIntegrationRuntimeNode().catch(console.error);

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

@ -0,0 +1,46 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
GetSsisObjectMetadataRequest,
IntegrationRuntimeObjectMetadataListOptionalParams,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get object metadata from an integration runtime
*
* @summary Get object metadata from an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeObjectMetadata_List.json
*/
async function getIntegrationRuntimeObjectMetadata() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "testactivityv2";
const getMetadataRequest: GetSsisObjectMetadataRequest = {
metadataPath: "ssisFolders"
};
const options: IntegrationRuntimeObjectMetadataListOptionalParams = {
getMetadataRequest
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeObjectMetadata.list(
resourceGroupName,
workspaceName,
integrationRuntimeName,
options
);
console.log(result);
}
getIntegrationRuntimeObjectMetadata().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Refresh the object metadata in an integration runtime
*
* @summary Refresh the object metadata in an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimeObjectMetadata_Refresh.json
*/
async function refreshObjectMetadata() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "testactivityv2";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeObjectMetadata.beginRefreshAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
refreshObjectMetadata().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get the integration runtime status
*
* @summary Get the integration runtime status
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_GetStatus.json
*/
async function getStatus() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimeStatusOperations.get(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
getStatus().catch(console.error);

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

@ -0,0 +1,45 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
IntegrationRuntimeResource,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create an integration runtime
*
* @summary Create an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Create.json
*/
async function createIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const integrationRuntime: IntegrationRuntimeResource = {
properties: {
type: "SelfHosted",
description: "A selfhosted integration runtime"
}
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginCreateAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName,
integrationRuntime
);
console.log(result);
}
createIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Delete an integration runtime
*
* @summary Delete an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Delete.json
*/
async function deleteIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginDeleteAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
deleteIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Disable interactive query in integration runtime
*
* @summary Disable interactive query in integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_DisableInteractiveQuery.json
*/
async function stopIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleManagedIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginDisableInteractiveQueryAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
stopIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Enable interactive query in integration runtime
*
* @summary Enable interactive query in integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_EnableInteractiveQuery.json
*/
async function stopIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleManagedIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginEnableInteractiveQueryAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
stopIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get an integration runtime
*
* @summary Get an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Get.json
*/
async function getIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.get(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
getIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,36 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to List all integration runtimes
*
* @summary List all integration runtimes
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_ListByWorkspace.json
*/
async function listIntegrationRuntimes() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.integrationRuntimes.listByWorkspace(
resourceGroupName,
workspaceName
)) {
resArray.push(item);
}
console.log(resArray);
}
listIntegrationRuntimes().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets the list of outbound network dependencies for a given Azure-SSIS integration runtime.
*
* @summary Gets the list of outbound network dependencies for a given Azure-SSIS integration runtime.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_ListOutboundNetworkDependenciesEndpoints.json
*/
async function getOutboundNetworkDependencyEndpoints() {
const subscriptionId = "ade9c2b6-c160-4305-9bb9-80342f6c1ae2";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.listOutboundNetworkDependenciesEndpoints(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
getOutboundNetworkDependencyEndpoints().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Start an integration runtime
*
* @summary Start an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Start.json
*/
async function startIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleManagedIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginStartAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
startIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Stop an integration runtime
*
* @summary Stop an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Stop.json
*/
async function stopIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleManagedIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.beginStopAndWait(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
stopIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
UpdateIntegrationRuntimeRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Update an integration runtime
*
* @summary Update an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Update.json
*/
async function updateIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const updateIntegrationRuntimeRequest: UpdateIntegrationRuntimeRequest = {
autoUpdate: "Off",
updateDelayOffset: '"PT3H"'
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.update(
resourceGroupName,
workspaceName,
integrationRuntimeName,
updateIntegrationRuntimeRequest
);
console.log(result);
}
updateIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Upgrade an integration runtime
*
* @summary Upgrade an integration runtime
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/IntegrationRuntimes_Upgrade.json
*/
async function upgradeIntegrationRuntime() {
const subscriptionId = "12345678-1234-1234-1234-12345678abc";
const resourceGroupName = "exampleResourceGroup";
const workspaceName = "exampleWorkspace";
const integrationRuntimeName = "exampleIntegrationRuntime";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.integrationRuntimes.upgrade(
resourceGroupName,
workspaceName,
integrationRuntimeName
);
console.log(result);
}
upgradeIntegrationRuntime().catch(console.error);

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

@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
IpFirewallRuleInfo,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a firewall rule
*
* @summary Creates or updates a firewall rule
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/CreateIpFirewallRule.json
*/
async function createAnIPFirewallRule() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const ruleName = "ExampleIpFirewallRule";
const ipFirewallRuleInfo: IpFirewallRuleInfo = {
endIpAddress: "10.0.0.254",
startIpAddress: "10.0.0.0"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.ipFirewallRules.beginCreateOrUpdateAndWait(
resourceGroupName,
workspaceName,
ruleName,
ipFirewallRuleInfo
);
console.log(result);
}
createAnIPFirewallRule().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes a firewall rule
*
* @summary Deletes a firewall rule
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DeleteIpFirewallRule.json
*/
async function deleteAnIPFirewallRuleFromAWorkspace() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const ruleName = "ExampleIpFirewallRule";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.ipFirewallRules.beginDeleteAndWait(
resourceGroupName,
workspaceName,
ruleName
);
console.log(result);
}
deleteAnIPFirewallRuleFromAWorkspace().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Get a firewall rule
*
* @summary Get a firewall rule
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/GetIpFirewallRule.json
*/
async function createAnIPFirewallRule() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const ruleName = "ExampleIpFirewallRule";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.ipFirewallRules.get(
resourceGroupName,
workspaceName,
ruleName
);
console.log(result);
}
createAnIPFirewallRule().catch(console.error);

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

@ -0,0 +1,36 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a list of firewall rules
*
* @summary Returns a list of firewall rules
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ListIpFirewallRules.json
*/
async function listIPFirewallRulesInAWorkspace() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.ipFirewallRules.listByWorkspace(
resourceGroupName,
workspaceName
)) {
resArray.push(item);
}
console.log(resArray);
}
listIPFirewallRulesInAWorkspace().catch(console.error);

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

@ -0,0 +1,49 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
ReplaceAllIpFirewallRulesRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Replaces firewall rules
*
* @summary Replaces firewall rules
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ReplaceAllIpFirewallRules.json
*/
async function replaceAllIPFirewallRulesInAWorkspace() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const request: ReplaceAllIpFirewallRulesRequest = {
ipFirewallRules: {
anotherExampleFirewallRule: {
endIpAddress: "10.0.1.254",
startIpAddress: "10.0.1.0"
},
exampleFirewallRule: {
endIpAddress: "10.0.0.254",
startIpAddress: "10.0.0.0"
}
}
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.ipFirewallRules.beginReplaceAllAndWait(
resourceGroupName,
workspaceName,
request
);
console.log(result);
}
replaceAllIPFirewallRulesInAWorkspace().catch(console.error);

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

@ -0,0 +1,40 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { Key, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a workspace key
*
* @summary Creates or updates a workspace key
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/CreateOrUpdateKey.json
*/
async function createOrUpdateAWorkspaceKey() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const keyName = "somekey";
const keyProperties: Key = {
isActiveCMK: true,
keyVaultUrl: "https://vault.azure.net/keys/somesecret"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.keys.createOrUpdate(
resourceGroupName,
workspaceName,
keyName,
keyProperties
);
console.log(result);
}
createOrUpdateAWorkspaceKey().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes a workspace key
*
* @summary Deletes a workspace key
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/DeleteKey.json
*/
async function deleteAWorkspaceKey() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const keyName = "somekey";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.keys.delete(
resourceGroupName,
workspaceName,
keyName
);
console.log(result);
}
deleteAWorkspaceKey().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a workspace key
*
* @summary Gets a workspace key
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/GetKey.json
*/
async function getAWorkspaceKey() {
const subscriptionId = "00000000-1111-2222-3333-444444444444";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const keyName = "somekey";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.keys.get(
resourceGroupName,
workspaceName,
keyName
);
console.log(result);
}
getAWorkspaceKey().catch(console.error);

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

@ -0,0 +1,36 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a list of keys in a workspace
*
* @summary Returns a list of keys in a workspace
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/stable/2021-06-01/examples/ListKeysInWorkspace.json
*/
async function listKeysInWorkspace() {
const subscriptionId = "01234567-89ab-4def-0123-456789abcdef";
const resourceGroupName = "ExampleResourceGroup";
const workspaceName = "ExampleWorkspace";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.keys.listByWorkspace(
resourceGroupName,
workspaceName
)) {
resArray.push(item);
}
console.log(resArray);
}
listKeysInWorkspace().catch(console.error);

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

@ -0,0 +1,31 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Lists available operations for the Kusto sub-resources inside Microsoft.Synapse provider.
*
* @summary Lists available operations for the Kusto sub-resources inside Microsoft.Synapse provider.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoOperationsList.json
*/
async function kustoOperationsList() {
const subscriptionId = "00000000-0000-0000-0000-000000000000";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoOperations.list()) {
resArray.push(item);
}
console.log(resArray);
}
kustoOperationsList().catch(console.error);

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

@ -0,0 +1,56 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
AttachedDatabaseConfiguration,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates an attached database configuration.
*
* @summary Creates or updates an attached database configuration.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolAttachedDatabaseConfigurationsCreateOrUpdate.json
*/
async function kustoPoolAttachedDatabaseConfigurationsCreateOrUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const attachedDatabaseConfigurationName = "attachedDatabaseConfigurations1";
const resourceGroupName = "kustorptest";
const parameters: AttachedDatabaseConfiguration = {
kustoPoolResourceId:
"/subscriptions/12345678-1234-1234-1234-123456789098/resourceGroups/kustorptest/providers/Microsoft.Synapse/Workspaces/kustorptest/KustoPools/kustoclusterrptest4",
databaseName: "kustodatabase",
defaultPrincipalsModificationKind: "Union",
location: "westus",
tableLevelSharingProperties: {
externalTablesToExclude: ["ExternalTable2"],
externalTablesToInclude: ["ExternalTable1"],
materializedViewsToExclude: ["MaterializedViewTable2"],
materializedViewsToInclude: ["MaterializedViewTable1"],
tablesToExclude: ["Table2"],
tablesToInclude: ["Table1"]
}
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolAttachedDatabaseConfigurations.beginCreateOrUpdateAndWait(
workspaceName,
kustoPoolName,
attachedDatabaseConfigurationName,
resourceGroupName,
parameters
);
console.log(result);
}
kustoPoolAttachedDatabaseConfigurationsCreateOrUpdate().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes the attached database configuration with the given name.
*
* @summary Deletes the attached database configuration with the given name.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolAttachedDatabaseConfigurationsDelete.json
*/
async function kustoPoolAttachedDatabaseConfigurationsDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const attachedDatabaseConfigurationName = "attachedDatabaseConfigurations1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolAttachedDatabaseConfigurations.beginDeleteAndWait(
workspaceName,
kustoPoolName,
attachedDatabaseConfigurationName,
resourceGroupName
);
console.log(result);
}
kustoPoolAttachedDatabaseConfigurationsDelete().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns an attached database configuration.
*
* @summary Returns an attached database configuration.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolAttachedDatabaseConfigurationsGet.json
*/
async function kustoPoolAttachedDatabaseConfigurationsGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const attachedDatabaseConfigurationName = "attachedDatabaseConfigurations1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolAttachedDatabaseConfigurations.get(
workspaceName,
kustoPoolName,
attachedDatabaseConfigurationName,
resourceGroupName
);
console.log(result);
}
kustoPoolAttachedDatabaseConfigurationsGet().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns the list of attached database configurations of the given Kusto Pool.
*
* @summary Returns the list of attached database configurations of the given Kusto Pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolAttachedDatabaseConfigurationsListByKustoPool.json
*/
async function kustoPoolAttachedDatabaseConfigurationsListByKustoPool() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPoolAttachedDatabaseConfigurations.listByKustoPool(
workspaceName,
kustoPoolName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolAttachedDatabaseConfigurationsListByKustoPool().catch(console.error);

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

@ -0,0 +1,74 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
DatabaseCheckNameRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the Kusto Pool child resource name is valid and is not already in use.
*
* @summary Checks that the Kusto Pool child resource name is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolAttachedDatabaseConfigurationCheckNameAvailability.json
*/
async function kustoPoolAttachedDatabaseConfigurationCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const resourceName: DatabaseCheckNameRequest = {
name: "adc1",
type:
"Microsoft.Synapse/workspaces/kustoPools/attachedDatabaseConfigurations"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolChildResource.checkNameAvailability(
workspaceName,
kustoPoolName,
resourceGroupName,
resourceName
);
console.log(result);
}
kustoPoolAttachedDatabaseConfigurationCheckNameAvailability().catch(
console.error
);
/**
* This sample demonstrates how to Checks that the Kusto Pool child resource name is valid and is not already in use.
*
* @summary Checks that the Kusto Pool child resource name is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasesCheckNameAvailability.json
*/
async function kustoPoolDatabasesCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const resourceName: DatabaseCheckNameRequest = {
name: "database1",
type: "Microsoft.Synapse/workspaces/kustoPools/databases"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolChildResource.checkNameAvailability(
workspaceName,
kustoPoolName,
resourceGroupName,
resourceName
);
console.log(result);
}
kustoPoolDatabasesCheckNameAvailability().catch(console.error);

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

@ -0,0 +1,45 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
DataConnectionCheckNameRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the data connection name is valid and is not already in use.
*
* @summary Checks that the data connection name is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsCheckNameAvailability.json
*/
async function kustoPoolDataConnectionsCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const dataConnectionName: DataConnectionCheckNameRequest = {
name: "DataConnections8",
type: "Microsoft.Synapse/workspaces/kustoPools/databases/dataConnections"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.checkNameAvailability(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
dataConnectionName
);
console.log(result);
}
kustoPoolDataConnectionsCheckNameAvailability().catch(console.error);

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

@ -0,0 +1,50 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
EventHubDataConnection,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a data connection.
*
* @summary Creates or updates a data connection.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsCreateOrUpdate.json
*/
async function kustoPoolDataConnectionsCreateOrUpdateJson() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const dataConnectionName = "DataConnections8";
const parameters: EventHubDataConnection = {
consumerGroup: "testConsumerGroup1",
eventHubResourceId:
"/subscriptions/12345678-1234-1234-1234-123456789098/resourceGroups/kustorptest/providers/Microsoft.EventHub/namespaces/eventhubTestns1/eventhubs/eventhubTest1",
kind: "EventHub",
location: "westus"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.beginCreateOrUpdateAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
dataConnectionName,
parameters
);
console.log(result);
}
kustoPoolDataConnectionsCreateOrUpdateJson().catch(console.error);

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

@ -0,0 +1,45 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
DataConnectionValidation,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the data connection parameters are valid.
*
* @summary Checks that the data connection parameters are valid.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionValidation.json
*/
async function kustoPoolDataConnectionValidation() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const parameters: DataConnectionValidation = {
dataConnectionName: "DataConnections8",
properties: { kind: "EventHub" }
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.beginDataConnectionValidationAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
parameters
);
console.log(result);
}
kustoPoolDataConnectionValidation().catch(console.error);

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

@ -0,0 +1,39 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes the data connection with the given name.
*
* @summary Deletes the data connection with the given name.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsDelete.json
*/
async function kustoPoolDataConnectionsDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const dataConnectionName = "kustoeventhubconnection1";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.beginDeleteAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
dataConnectionName
);
console.log(result);
}
kustoPoolDataConnectionsDelete().catch(console.error);

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

@ -0,0 +1,39 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a data connection.
*
* @summary Returns a data connection.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsGet.json
*/
async function kustoPoolDataConnectionsGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const dataConnectionName = "DataConnections8";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.get(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
dataConnectionName
);
console.log(result);
}
kustoPoolDataConnectionsGet().catch(console.error);

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

@ -0,0 +1,40 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns the list of data connections of the given Kusto pool database.
*
* @summary Returns the list of data connections of the given Kusto pool database.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsListByDatabase.json
*/
async function kustoPoolDataConnectionsListByDatabase() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPoolDataConnections.listByDatabase(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolDataConnectionsListByDatabase().catch(console.error);

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

@ -0,0 +1,50 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
EventHubDataConnection,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Updates a data connection.
*
* @summary Updates a data connection.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDataConnectionsUpdate.json
*/
async function kustoPoolDataConnectionsUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const dataConnectionName = "DataConnections8";
const parameters: EventHubDataConnection = {
consumerGroup: "testConsumerGroup1",
eventHubResourceId:
"/subscriptions/12345678-1234-1234-1234-123456789098/resourceGroups/kustorptest/providers/Microsoft.EventHub/namespaces/eventhubTestns1/eventhubs/eventhubTest1",
kind: "EventHub",
location: "westus"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDataConnections.beginUpdateAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
dataConnectionName,
parameters
);
console.log(result);
}
kustoPoolDataConnectionsUpdate().catch(console.error);

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

@ -0,0 +1,48 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
DatabasePrincipalAssignmentCheckNameRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the database principal assignment is valid and is not already in use.
*
* @summary Checks that the database principal assignment is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasePrincipalAssignmentsCheckNameAvailability.json
*/
async function kustoPoolDatabasePrincipalAssignmentsCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const resourceGroupName = "kustorptest";
const principalAssignmentName: DatabasePrincipalAssignmentCheckNameRequest = {
name: "kustoprincipal1",
type:
"Microsoft.Synapse/workspaces/kustoPools/databases/principalAssignments"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabasePrincipalAssignments.checkNameAvailability(
workspaceName,
kustoPoolName,
databaseName,
resourceGroupName,
principalAssignmentName
);
console.log(result);
}
kustoPoolDatabasePrincipalAssignmentsCheckNameAvailability().catch(
console.error
);

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

@ -0,0 +1,49 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
DatabasePrincipalAssignment,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates a Kusto pool database principalAssignment.
*
* @summary Creates a Kusto pool database principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasePrincipalAssignmentsCreateOrUpdate.json
*/
async function kustoPoolDatabasePrincipalAssignmentsCreateOrUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const parameters: DatabasePrincipalAssignment = {
principalId: "87654321-1234-1234-1234-123456789123",
principalType: "App",
role: "Admin",
tenantId: "12345678-1234-1234-1234-123456789123"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabasePrincipalAssignments.beginCreateOrUpdateAndWait(
workspaceName,
kustoPoolName,
databaseName,
principalAssignmentName,
resourceGroupName,
parameters
);
console.log(result);
}
kustoPoolDatabasePrincipalAssignmentsCreateOrUpdate().catch(console.error);

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

@ -0,0 +1,39 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes a Kusto pool principalAssignment.
*
* @summary Deletes a Kusto pool principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasePrincipalAssignmentsDelete.json
*/
async function kustoPoolDatabasePrincipalAssignmentsDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabasePrincipalAssignments.beginDeleteAndWait(
workspaceName,
kustoPoolName,
databaseName,
principalAssignmentName,
resourceGroupName
);
console.log(result);
}
kustoPoolDatabasePrincipalAssignmentsDelete().catch(console.error);

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

@ -0,0 +1,39 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a Kusto pool database principalAssignment.
*
* @summary Gets a Kusto pool database principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasePrincipalAssignmentsGet.json
*/
async function kustoPoolDatabasePrincipalAssignmentsGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabasePrincipalAssignments.get(
workspaceName,
kustoPoolName,
databaseName,
principalAssignmentName,
resourceGroupName
);
console.log(result);
}
kustoPoolDatabasePrincipalAssignmentsGet().catch(console.error);

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

@ -0,0 +1,40 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Lists all Kusto pool database principalAssignments.
*
* @summary Lists all Kusto pool database principalAssignments.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasePrincipalAssignmentsList.json
*/
async function kustoPoolDatabasePrincipalAssignmentsList() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "Kustodatabase8";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPoolDatabasePrincipalAssignments.list(
workspaceName,
kustoPoolName,
databaseName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolDatabasePrincipalAssignmentsList().catch(console.error);

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

@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ReadWriteDatabase, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Creates or updates a database.
*
* @summary Creates or updates a database.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasesCreateOrUpdate.json
*/
async function kustoPoolDatabasesCreateOrUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const parameters: ReadWriteDatabase = {
kind: "ReadWrite",
location: "westus",
softDeletePeriod: "P1D"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabases.beginCreateOrUpdateAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
parameters
);
console.log(result);
}
kustoPoolDatabasesCreateOrUpdate().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes the database with the given name.
*
* @summary Deletes the database with the given name.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasesDelete.json
*/
async function kustoPoolDatabasesDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabases.beginDeleteAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName
);
console.log(result);
}
kustoPoolDatabasesDelete().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a database.
*
* @summary Returns a database.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasesGet.json
*/
async function kustoPoolDatabasesGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabases.get(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName
);
console.log(result);
}
kustoPoolDatabasesGet().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns the list of databases of the given Kusto pool.
*
* @summary Returns the list of databases of the given Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoDatabasesListByKustoPool.json
*/
async function kustoDatabasesListByKustoPool() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPoolDatabases.listByKustoPool(
resourceGroupName,
workspaceName,
kustoPoolName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoDatabasesListByKustoPool().catch(console.error);

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

@ -0,0 +1,42 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { ReadWriteDatabase, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Updates a database.
*
* @summary Updates a database.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolDatabasesUpdate.json
*/
async function kustoPoolDatabasesUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const databaseName = "KustoDatabase8";
const parameters: ReadWriteDatabase = {
kind: "ReadWrite",
softDeletePeriod: "P1D"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolDatabases.beginUpdateAndWait(
resourceGroupName,
workspaceName,
kustoPoolName,
databaseName,
parameters
);
console.log(result);
}
kustoPoolDatabasesUpdate().catch(console.error);

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

@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
ClusterPrincipalAssignmentCheckNameRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the principal assignment name is valid and is not already in use.
*
* @summary Checks that the principal assignment name is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolPrincipalAssignmentsCheckNameAvailability.json
*/
async function kustoPoolPrincipalAssignmentsCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const principalAssignmentName: ClusterPrincipalAssignmentCheckNameRequest = {
name: "kustoprincipal1",
type: "Microsoft.Synapse/workspaces/kustoPools/principalAssignments"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolPrincipalAssignments.checkNameAvailability(
workspaceName,
kustoPoolName,
resourceGroupName,
principalAssignmentName
);
console.log(result);
}
kustoPoolPrincipalAssignmentsCheckNameAvailability().catch(console.error);

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

@ -0,0 +1,47 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
ClusterPrincipalAssignment,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create a Kusto pool principalAssignment.
*
* @summary Create a Kusto pool principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolPrincipalAssignmentsCreateOrUpdate.json
*/
async function kustoPoolPrincipalAssignmentsCreateOrUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const parameters: ClusterPrincipalAssignment = {
principalId: "87654321-1234-1234-1234-123456789123",
principalType: "App",
role: "AllDatabasesAdmin",
tenantId: "12345678-1234-1234-1234-123456789123"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolPrincipalAssignments.beginCreateOrUpdateAndWait(
workspaceName,
kustoPoolName,
principalAssignmentName,
resourceGroupName,
parameters
);
console.log(result);
}
kustoPoolPrincipalAssignmentsCreateOrUpdate().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes a Kusto pool principalAssignment.
*
* @summary Deletes a Kusto pool principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolPrincipalAssignmentsDelete.json
*/
async function kustoPoolPrincipalAssignmentsDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolPrincipalAssignments.beginDeleteAndWait(
workspaceName,
kustoPoolName,
principalAssignmentName,
resourceGroupName
);
console.log(result);
}
kustoPoolPrincipalAssignmentsDelete().catch(console.error);

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

@ -0,0 +1,37 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a Kusto pool principalAssignment.
*
* @summary Gets a Kusto pool principalAssignment.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolPrincipalAssignmentsGet.json
*/
async function kustoPoolPrincipalAssignmentsGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const principalAssignmentName = "kustoprincipal1";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPoolPrincipalAssignments.get(
workspaceName,
kustoPoolName,
principalAssignmentName,
resourceGroupName
);
console.log(result);
}
kustoPoolPrincipalAssignmentsGet().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Lists all Kusto pool principalAssignments.
*
* @summary Lists all Kusto pool principalAssignments.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolPrincipalAssignmentsList.json
*/
async function kustoPoolPrincipalAssignmentsList() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPoolPrincipalAssignments.list(
workspaceName,
kustoPoolName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolPrincipalAssignmentsList().catch(console.error);

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

@ -0,0 +1,42 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
LanguageExtensionsList,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Add a list of language extensions that can run within KQL queries.
*
* @summary Add a list of language extensions that can run within KQL queries.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolLanguageExtensionsAdd.json
*/
async function kustoPoolAddLanguageExtensions() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const languageExtensionsToAdd: LanguageExtensionsList = {
value: [{ languageExtensionName: "PYTHON" }, { languageExtensionName: "R" }]
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginAddLanguageExtensionsAndWait(
workspaceName,
kustoPoolName,
resourceGroupName,
languageExtensionsToAdd
);
console.log(result);
}
kustoPoolAddLanguageExtensions().catch(console.error);

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

@ -0,0 +1,39 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
KustoPoolCheckNameRequest,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Checks that the kusto pool name is valid and is not already in use.
*
* @summary Checks that the kusto pool name is valid and is not already in use.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsCheckNameAvailability.json
*/
async function kustoPoolsCheckNameAvailability() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const location = "westus";
const kustoPoolName: KustoPoolCheckNameRequest = {
name: "kustoclusterrptest4",
type: "Microsoft.Synapse/workspaces/kustoPools"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.checkNameAvailability(
location,
kustoPoolName
);
console.log(result);
}
kustoPoolsCheckNameAvailability().catch(console.error);

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

@ -0,0 +1,43 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { KustoPool, SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Create or update a Kusto pool.
*
* @summary Create or update a Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsCreateOrUpdate.json
*/
async function kustoPoolsCreateOrUpdate() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const resourceGroupName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const parameters: KustoPool = {
enablePurge: true,
enableStreamingIngest: true,
location: "westus",
sku: { name: "Storage optimized", capacity: 2, size: "Medium" },
workspaceUID: "11111111-2222-3333-444444444444"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginCreateOrUpdateAndWait(
workspaceName,
resourceGroupName,
kustoPoolName,
parameters
);
console.log(result);
}
kustoPoolsCreateOrUpdate().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Deletes a Kusto pool.
*
* @summary Deletes a Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsDelete.json
*/
async function kustoPoolsDelete() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const resourceGroupName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginDeleteAndWait(
workspaceName,
resourceGroupName,
kustoPoolName
);
console.log(result);
}
kustoPoolsDelete().catch(console.error);

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

@ -0,0 +1,44 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
FollowerDatabaseDefinition,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Detaches all followers of a database owned by this Kusto Pool.
*
* @summary Detaches all followers of a database owned by this Kusto Pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolFollowerDatabasesDetach.json
*/
async function kustoPoolDetachFollowerDatabases() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const followerDatabaseToRemove: FollowerDatabaseDefinition = {
attachedDatabaseConfigurationName: "myAttachedDatabaseConfiguration",
kustoPoolResourceId:
"/subscriptions/12345678-1234-1234-1234-123456789098/resourceGroups/kustorptest/providers/Microsoft.Synapse/workspaces/kustorptest/kustoPools/leader4"
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginDetachFollowerDatabasesAndWait(
workspaceName,
kustoPoolName,
resourceGroupName,
followerDatabaseToRemove
);
console.log(result);
}
kustoPoolDetachFollowerDatabases().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Gets a Kusto pool.
*
* @summary Gets a Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsGet.json
*/
async function kustoPoolsGet() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.get(
workspaceName,
kustoPoolName,
resourceGroupName
);
console.log(result);
}
kustoPoolsGet().catch(console.error);

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

@ -0,0 +1,33 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to List all Kusto pools
*
* @summary List all Kusto pools
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsListByWorkspace.json
*/
async function listKustoPoolsInAWorkspace() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const resourceGroupName = "kustorptest";
const workspaceName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.listByWorkspace(
resourceGroupName,
workspaceName
);
console.log(result);
}
listKustoPoolsInAWorkspace().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a list of databases that are owned by this Kusto Pool and were followed by another Kusto Pool.
*
* @summary Returns a list of databases that are owned by this Kusto Pool and were followed by another Kusto Pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolFollowerDatabasesList.json
*/
async function kustoPoolListFollowerDatabases() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPools.listFollowerDatabases(
workspaceName,
kustoPoolName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolListFollowerDatabases().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns a list of language extensions that can run within KQL queries.
*
* @summary Returns a list of language extensions that can run within KQL queries.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolLanguageExtensionsList.json
*/
async function kustoPoolListLanguageExtensions() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPools.listLanguageExtensions(
workspaceName,
kustoPoolName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolListLanguageExtensions().catch(console.error);

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

@ -0,0 +1,38 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Returns the SKUs available for the provided resource.
*
* @summary Returns the SKUs available for the provided resource.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsListResourceSkus.json
*/
async function kustoPoolsListResourceSkus() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "synapseWorkspaceName";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPools.listSkusByResource(
workspaceName,
kustoPoolName,
resourceGroupName
)) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolsListResourceSkus().catch(console.error);

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

@ -0,0 +1,31 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Lists eligible SKUs for Kusto Pool resource.
*
* @summary Lists eligible SKUs for Kusto Pool resource.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsListSkus.json
*/
async function kustoPoolsListSkus() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const resArray = new Array();
for await (let item of client.kustoPools.listSkus()) {
resArray.push(item);
}
console.log(resArray);
}
kustoPoolsListSkus().catch(console.error);

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

@ -0,0 +1,42 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import {
LanguageExtensionsList,
SynapseManagementClient
} from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Remove a list of language extensions that can run within KQL queries.
*
* @summary Remove a list of language extensions that can run within KQL queries.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolLanguageExtensionsRemove.json
*/
async function kustoPoolRemoveLanguageExtensions() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const languageExtensionsToRemove: LanguageExtensionsList = {
value: [{ languageExtensionName: "PYTHON" }, { languageExtensionName: "R" }]
};
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginRemoveLanguageExtensionsAndWait(
workspaceName,
kustoPoolName,
resourceGroupName,
languageExtensionsToRemove
);
console.log(result);
}
kustoPoolRemoveLanguageExtensions().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Starts a Kusto pool.
*
* @summary Starts a Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsStart.json
*/
async function kustoPoolsStop() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginStartAndWait(
workspaceName,
kustoPoolName,
resourceGroupName
);
console.log(result);
}
kustoPoolsStop().catch(console.error);

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

@ -0,0 +1,35 @@
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
import { SynapseManagementClient } from "@azure/arm-synapse";
import { DefaultAzureCredential } from "@azure/identity";
/**
* This sample demonstrates how to Stops a Kusto pool.
*
* @summary Stops a Kusto pool.
* x-ms-original-file: specification/synapse/resource-manager/Microsoft.Synapse/preview/2021-06-01-preview/examples/KustoPoolsStop.json
*/
async function kustoPoolsStop() {
const subscriptionId = "12345678-1234-1234-1234-123456789098";
const workspaceName = "kustorptest";
const kustoPoolName = "kustoclusterrptest4";
const resourceGroupName = "kustorptest";
const credential = new DefaultAzureCredential();
const client = new SynapseManagementClient(credential, subscriptionId);
const result = await client.kustoPools.beginStopAndWait(
workspaceName,
kustoPoolName,
resourceGroupName
);
console.log(result);
}
kustoPoolsStop().catch(console.error);

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