@azure/arm-sqlvirtualmachine 5.0.0-beta.4 → 5.0.0-beta.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +2 -2
- package/dist/index.js +42 -13
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist-esm/samples-dev/availabilityGroupListenersCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/availabilityGroupListenersCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersCreateOrUpdateSample.js +50 -0
- package/dist-esm/samples-dev/availabilityGroupListenersCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersDeleteSample.d.ts +2 -0
- package/dist-esm/samples-dev/availabilityGroupListenersDeleteSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersDeleteSample.js +32 -0
- package/dist-esm/samples-dev/availabilityGroupListenersDeleteSample.js.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/availabilityGroupListenersGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersGetSample.js +32 -0
- package/dist-esm/samples-dev/availabilityGroupListenersGetSample.js.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersListByGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/availabilityGroupListenersListByGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/availabilityGroupListenersListByGroupSample.js +45 -0
- package/dist-esm/samples-dev/availabilityGroupListenersListByGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/operationsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/operationsListSample.js +43 -0
- package/dist-esm/samples-dev/operationsListSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.js +46 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsDeleteSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsDeleteSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsDeleteSample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsDeleteSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsGetSample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsGetSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.js +44 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListSample.js +43 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsListSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsUpdateSample.js +32 -0
- package/dist-esm/samples-dev/sqlVirtualMachineGroupsUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesCreateOrUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesCreateOrUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesCreateOrUpdateSample.js +269 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesCreateOrUpdateSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesDeleteSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesDeleteSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesDeleteSample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesDeleteSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesGetSample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesGetSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListByResourceGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListByResourceGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListByResourceGroupSample.js +44 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListByResourceGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListBySqlVMGroupSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListBySqlVMGroupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListBySqlVMGroupSample.js +45 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListBySqlVMGroupSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListSample.js +43 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesListSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesRedeploySample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesRedeploySample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesRedeploySample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesRedeploySample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesStartAssessmentSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesStartAssessmentSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesStartAssessmentSample.js +31 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesStartAssessmentSample.js.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesUpdateSample.d.ts +2 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesUpdateSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesUpdateSample.js +32 -0
- package/dist-esm/samples-dev/sqlVirtualMachinesUpdateSample.js.map +1 -0
- package/dist-esm/src/models/index.d.ts +11 -9
- package/dist-esm/src/models/index.d.ts.map +1 -1
- package/dist-esm/src/models/index.js +11 -11
- package/dist-esm/src/models/index.js.map +1 -1
- package/dist-esm/src/models/mappers.d.ts.map +1 -1
- package/dist-esm/src/models/mappers.js +1 -0
- package/dist-esm/src/models/mappers.js.map +1 -1
- package/dist-esm/src/sqlVirtualMachineManagementClient.d.ts +2 -0
- package/dist-esm/src/sqlVirtualMachineManagementClient.d.ts.map +1 -1
- package/dist-esm/src/sqlVirtualMachineManagementClient.js +30 -1
- package/dist-esm/src/sqlVirtualMachineManagementClient.js.map +1 -1
- package/dist-esm/test/sampleTest.js +11 -13
- package/dist-esm/test/sampleTest.js.map +1 -1
- package/package.json +18 -6
- package/review/arm-sqlvirtualmachine.api.md +28 -25
- package/src/models/index.ts +18 -8
- package/src/models/mappers.ts +1 -0
- package/src/sqlVirtualMachineManagementClient.ts +35 -1
- package/tsconfig.json +8 -2
- package/types/arm-sqlvirtualmachine.d.ts +35 -30
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersDeleteSample.d.ts","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersDeleteSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Deletes an availability group listener.
|
|
15
|
+
*
|
|
16
|
+
* @summary Deletes an availability group listener.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/DeleteAvailabilityGroupListener.json
|
|
18
|
+
*/
|
|
19
|
+
function deletesAnAvailabilityGroupListener() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const availabilityGroupListenerName = "agl-test";
|
|
25
|
+
const credential = new DefaultAzureCredential();
|
|
26
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
27
|
+
const result = yield client.availabilityGroupListeners.beginDeleteAndWait(resourceGroupName, sqlVirtualMachineGroupName, availabilityGroupListenerName);
|
|
28
|
+
console.log(result);
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
deletesAnAvailabilityGroupListener().catch(console.error);
|
|
32
|
+
//# sourceMappingURL=availabilityGroupListenersDeleteSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,kCAAkC;;QAC/C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,6BAA6B,GAAG,UAAU,CAAC;QACjD,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,kBAAkB,CACvE,iBAAiB,EACjB,0BAA0B,EAC1B,6BAA6B,CAC9B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,kCAAkC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersGetSample.d.ts","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersGetSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Gets an availability group listener.
|
|
15
|
+
*
|
|
16
|
+
* @summary Gets an availability group listener.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/GetAvailabilityGroupListener.json
|
|
18
|
+
*/
|
|
19
|
+
function getsAnAvailabilityGroupListener() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const availabilityGroupListenerName = "agl-test";
|
|
25
|
+
const credential = new DefaultAzureCredential();
|
|
26
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
27
|
+
const result = yield client.availabilityGroupListeners.get(resourceGroupName, sqlVirtualMachineGroupName, availabilityGroupListenerName);
|
|
28
|
+
console.log(result);
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
getsAnAvailabilityGroupListener().catch(console.error);
|
|
32
|
+
//# sourceMappingURL=availabilityGroupListenersGetSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersGetSample.js","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,+BAA+B;;QAC5C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,6BAA6B,GAAG,UAAU,CAAC;QACjD,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,0BAA0B,CAAC,GAAG,CACxD,iBAAiB,EACjB,0BAA0B,EAC1B,6BAA6B,CAC9B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,+BAA+B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersListByGroupSample.d.ts","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersListByGroupSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Lists all availability group listeners in a SQL virtual machine group.
|
|
15
|
+
*
|
|
16
|
+
* @summary Lists all availability group listeners in a SQL virtual machine group.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/ListByGroupAvailabilityGroupListener.json
|
|
18
|
+
*/
|
|
19
|
+
function listsAllAvailabilityGroupListenersInASqlVirtualMachineGroup() {
|
|
20
|
+
var e_1, _a;
|
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
23
|
+
const resourceGroupName = "testrg";
|
|
24
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
25
|
+
const credential = new DefaultAzureCredential();
|
|
26
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
27
|
+
const resArray = new Array();
|
|
28
|
+
try {
|
|
29
|
+
for (var _b = __asyncValues(client.availabilityGroupListeners.listByGroup(resourceGroupName, sqlVirtualMachineGroupName)), _c; _c = yield _b.next(), !_c.done;) {
|
|
30
|
+
let item = _c.value;
|
|
31
|
+
resArray.push(item);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
35
|
+
finally {
|
|
36
|
+
try {
|
|
37
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
|
38
|
+
}
|
|
39
|
+
finally { if (e_1) throw e_1.error; }
|
|
40
|
+
}
|
|
41
|
+
console.log(resArray);
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
listsAllAvailabilityGroupListenersInASqlVirtualMachineGroup().catch(console.error);
|
|
45
|
+
//# sourceMappingURL=availabilityGroupListenersListByGroupSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"availabilityGroupListenersListByGroupSample.js","sourceRoot":"","sources":["../../samples-dev/availabilityGroupListenersListByGroupSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,2DAA2D;;;QACxE,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,0BAA0B,CAAC,WAAW,CAClE,iBAAiB,EACjB,0BAA0B,CAC3B,CAAA,IAAA;gBAHU,IAAI,IAAI,WAAA,CAAA;gBAIjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,2DAA2D,EAAE,CAAC,KAAK,CACjE,OAAO,CAAC,KAAK,CACd,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operationsListSample.d.ts","sourceRoot":"","sources":["../../samples-dev/operationsListSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Lists all of the available SQL Virtual Machine Rest API operations.
|
|
15
|
+
*
|
|
16
|
+
* @summary Lists all of the available SQL Virtual Machine Rest API operations.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/ListOperation.json
|
|
18
|
+
*/
|
|
19
|
+
function listsAllOfTheAvailableSqlVirtualMachineRestApiOperations() {
|
|
20
|
+
var e_1, _a;
|
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
+
const subscriptionId = "00000000-0000-0000-0000-000000000000";
|
|
23
|
+
const credential = new DefaultAzureCredential();
|
|
24
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
25
|
+
const resArray = new Array();
|
|
26
|
+
try {
|
|
27
|
+
for (var _b = __asyncValues(client.operations.list()), _c; _c = yield _b.next(), !_c.done;) {
|
|
28
|
+
let item = _c.value;
|
|
29
|
+
resArray.push(item);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
33
|
+
finally {
|
|
34
|
+
try {
|
|
35
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
|
36
|
+
}
|
|
37
|
+
finally { if (e_1) throw e_1.error; }
|
|
38
|
+
}
|
|
39
|
+
console.log(resArray);
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
listsAllOfTheAvailableSqlVirtualMachineRestApiOperations().catch(console.error);
|
|
43
|
+
//# sourceMappingURL=operationsListSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"operationsListSample.js","sourceRoot":"","sources":["../../samples-dev/operationsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,wDAAwD;;;QACrE,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,UAAU,CAAC,IAAI,EAAE,CAAA,IAAA;gBAApC,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,wDAAwD,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsCreateOrUpdateSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Creates or updates a SQL virtual machine group.
|
|
15
|
+
*
|
|
16
|
+
* @summary Creates or updates a SQL virtual machine group.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/CreateOrUpdateSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function createsOrUpdatesASqlVirtualMachineGroup() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const parameters = {
|
|
25
|
+
location: "northeurope",
|
|
26
|
+
sqlImageOffer: "SQL2016-WS2016",
|
|
27
|
+
sqlImageSku: "Enterprise",
|
|
28
|
+
tags: { mytag: "myval" },
|
|
29
|
+
wsfcDomainProfile: {
|
|
30
|
+
clusterBootstrapAccount: "testrpadmin",
|
|
31
|
+
clusterOperatorAccount: "testrp@testdomain.com",
|
|
32
|
+
domainFqdn: "testdomain.com",
|
|
33
|
+
ouPath: "OU=WSCluster,DC=testdomain,DC=com",
|
|
34
|
+
sqlServiceAccount: "sqlservice@testdomain.com",
|
|
35
|
+
storageAccountPrimaryKey: "<primary storage access key>",
|
|
36
|
+
storageAccountUrl: "https://storgact.blob.core.windows.net/"
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
const credential = new DefaultAzureCredential();
|
|
40
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
41
|
+
const result = yield client.sqlVirtualMachineGroups.beginCreateOrUpdateAndWait(resourceGroupName, sqlVirtualMachineGroupName, parameters);
|
|
42
|
+
console.log(result);
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
createsOrUpdatesASqlVirtualMachineGroup().catch(console.error);
|
|
46
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsCreateOrUpdateSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsCreateOrUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsCreateOrUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,uCAAuC;;QACpD,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,UAAU,GAA2B;YACzC,QAAQ,EAAE,aAAa;YACvB,aAAa,EAAE,gBAAgB;YAC/B,WAAW,EAAE,YAAY;YACzB,IAAI,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE;YACxB,iBAAiB,EAAE;gBACjB,uBAAuB,EAAE,aAAa;gBACtC,sBAAsB,EAAE,uBAAuB;gBAC/C,UAAU,EAAE,gBAAgB;gBAC5B,MAAM,EAAE,mCAAmC;gBAC3C,iBAAiB,EAAE,2BAA2B;gBAC9C,wBAAwB,EAAE,8BAA8B;gBACxD,iBAAiB,EAAE,yCAAyC;aAC7D;SACF,CAAC;QACF,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,0BAA0B,CAC5E,iBAAiB,EACjB,0BAA0B,EAC1B,UAAU,CACX,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,uCAAuC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsDeleteSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsDeleteSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Deletes a SQL virtual machine group.
|
|
15
|
+
*
|
|
16
|
+
* @summary Deletes a SQL virtual machine group.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/DeleteSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function deletesASqlVirtualMachineGroup() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const credential = new DefaultAzureCredential();
|
|
25
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
26
|
+
const result = yield client.sqlVirtualMachineGroups.beginDeleteAndWait(resourceGroupName, sqlVirtualMachineGroupName);
|
|
27
|
+
console.log(result);
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
deletesASqlVirtualMachineGroup().catch(console.error);
|
|
31
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsDeleteSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsDeleteSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsDeleteSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,8BAA8B;;QAC3C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,kBAAkB,CACpE,iBAAiB,EACjB,0BAA0B,CAC3B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,8BAA8B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsGetSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsGetSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Gets a SQL virtual machine group.
|
|
15
|
+
*
|
|
16
|
+
* @summary Gets a SQL virtual machine group.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/GetSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function getsASqlVirtualMachineGroup() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const credential = new DefaultAzureCredential();
|
|
25
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
26
|
+
const result = yield client.sqlVirtualMachineGroups.get(resourceGroupName, sqlVirtualMachineGroupName);
|
|
27
|
+
console.log(result);
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
getsASqlVirtualMachineGroup().catch(console.error);
|
|
31
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsGetSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsGetSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsGetSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,2BAA2B;;QACxC,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,GAAG,CACrD,iBAAiB,EACjB,0BAA0B,CAC3B,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,2BAA2B,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsListByResourceGroupSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Gets all SQL virtual machine groups in a resource group.
|
|
15
|
+
*
|
|
16
|
+
* @summary Gets all SQL virtual machine groups in a resource group.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/ListByResourceGroupSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function getsAllSqlVirtualMachineGroupsInAResourceGroup() {
|
|
20
|
+
var e_1, _a;
|
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
23
|
+
const resourceGroupName = "testrg";
|
|
24
|
+
const credential = new DefaultAzureCredential();
|
|
25
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
26
|
+
const resArray = new Array();
|
|
27
|
+
try {
|
|
28
|
+
for (var _b = __asyncValues(client.sqlVirtualMachineGroups.listByResourceGroup(resourceGroupName)), _c; _c = yield _b.next(), !_c.done;) {
|
|
29
|
+
let item = _c.value;
|
|
30
|
+
resArray.push(item);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
34
|
+
finally {
|
|
35
|
+
try {
|
|
36
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
|
37
|
+
}
|
|
38
|
+
finally { if (e_1) throw e_1.error; }
|
|
39
|
+
}
|
|
40
|
+
console.log(resArray);
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
getsAllSqlVirtualMachineGroupsInAResourceGroup().catch(console.error);
|
|
44
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsListByResourceGroupSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsListByResourceGroupSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsListByResourceGroupSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,8CAA8C;;;QAC3D,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,uBAAuB,CAAC,mBAAmB,CACvE,iBAAiB,CAClB,CAAA,IAAA;gBAFU,IAAI,IAAI,WAAA,CAAA;gBAGjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,8CAA8C,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsListSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsListSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __asyncValues, __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Gets all SQL virtual machine groups in a subscription.
|
|
15
|
+
*
|
|
16
|
+
* @summary Gets all SQL virtual machine groups in a subscription.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/ListSubscriptionSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function getsAllSqlVirtualMachineGroupsInASubscription() {
|
|
20
|
+
var e_1, _a;
|
|
21
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
23
|
+
const credential = new DefaultAzureCredential();
|
|
24
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
25
|
+
const resArray = new Array();
|
|
26
|
+
try {
|
|
27
|
+
for (var _b = __asyncValues(client.sqlVirtualMachineGroups.list()), _c; _c = yield _b.next(), !_c.done;) {
|
|
28
|
+
let item = _c.value;
|
|
29
|
+
resArray.push(item);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
|
33
|
+
finally {
|
|
34
|
+
try {
|
|
35
|
+
if (_c && !_c.done && (_a = _b.return)) yield _a.call(_b);
|
|
36
|
+
}
|
|
37
|
+
finally { if (e_1) throw e_1.error; }
|
|
38
|
+
}
|
|
39
|
+
console.log(resArray);
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
getsAllSqlVirtualMachineGroupsInASubscription().catch(console.error);
|
|
43
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsListSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsListSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsListSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAAE,iCAAiC,EAAE,MAAM,8BAA8B,CAAC;AACjF,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,6CAA6C;;;QAC1D,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,QAAQ,GAAG,IAAI,KAAK,EAAE,CAAC;;YAC7B,KAAuB,IAAA,KAAA,cAAA,MAAM,CAAC,uBAAuB,CAAC,IAAI,EAAE,CAAA,IAAA;gBAAjD,IAAI,IAAI,WAAA,CAAA;gBACjB,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;aACrB;;;;;;;;;QACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;;CACvB;AAED,6CAA6C,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsUpdateSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsUpdateSample.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter } from "tslib";
|
|
9
|
+
// Copyright (c) Microsoft Corporation.
|
|
10
|
+
// Licensed under the MIT License.
|
|
11
|
+
import { SqlVirtualMachineManagementClient } from "@azure/arm-sqlvirtualmachine";
|
|
12
|
+
import { DefaultAzureCredential } from "@azure/identity";
|
|
13
|
+
/**
|
|
14
|
+
* This sample demonstrates how to Updates SQL virtual machine group tags.
|
|
15
|
+
*
|
|
16
|
+
* @summary Updates SQL virtual machine group tags.
|
|
17
|
+
* x-ms-original-file: specification/sqlvirtualmachine/resource-manager/Microsoft.SqlVirtualMachine/preview/2021-11-01-preview/examples/UpdateSqlVirtualMachineGroup.json
|
|
18
|
+
*/
|
|
19
|
+
function updatesASqlVirtualMachineGroupTags() {
|
|
20
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
21
|
+
const subscriptionId = "00000000-1111-2222-3333-444444444444";
|
|
22
|
+
const resourceGroupName = "testrg";
|
|
23
|
+
const sqlVirtualMachineGroupName = "testvmgroup";
|
|
24
|
+
const parameters = { tags: { mytag: "myval" } };
|
|
25
|
+
const credential = new DefaultAzureCredential();
|
|
26
|
+
const client = new SqlVirtualMachineManagementClient(credential, subscriptionId);
|
|
27
|
+
const result = yield client.sqlVirtualMachineGroups.beginUpdateAndWait(resourceGroupName, sqlVirtualMachineGroupName, parameters);
|
|
28
|
+
console.log(result);
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
updatesASqlVirtualMachineGroupTags().catch(console.error);
|
|
32
|
+
//# sourceMappingURL=sqlVirtualMachineGroupsUpdateSample.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachineGroupsUpdateSample.js","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachineGroupsUpdateSample.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,uCAAuC;AACvC,kCAAkC;AAClC,OAAO,EAEL,iCAAiC,EAClC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,SAAe,kCAAkC;;QAC/C,MAAM,cAAc,GAAG,sCAAsC,CAAC;QAC9D,MAAM,iBAAiB,GAAG,QAAQ,CAAC;QACnC,MAAM,0BAA0B,GAAG,aAAa,CAAC;QACjD,MAAM,UAAU,GAAiC,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,CAAC;QAC9E,MAAM,UAAU,GAAG,IAAI,sBAAsB,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,IAAI,iCAAiC,CAClD,UAAU,EACV,cAAc,CACf,CAAC;QACF,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,kBAAkB,CACpE,iBAAiB,EACjB,0BAA0B,EAC1B,UAAU,CACX,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB,CAAC;CAAA;AAED,kCAAkC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sqlVirtualMachinesCreateOrUpdateSample.d.ts","sourceRoot":"","sources":["../../samples-dev/sqlVirtualMachinesCreateOrUpdateSample.ts"],"names":[],"mappings":""}
|