@azure/arm-hardwaresecuritymodules 2.0.0-beta.1 → 2.0.0-beta.2
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 +146 -2
- package/dist/index.js +2121 -1216
- 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/cloudHsmClusterBackupStatusGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClusterBackupStatusGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClusterBackupStatusGetSample.js +40 -0
- package/dist-esm/samples-dev/cloudHsmClusterBackupStatusGetSample.js.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.js +4 -4
- package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsCreateSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.js +1 -1
- package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsDeleteSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClusterPrivateEndpointConnectionsGetSample.js +1 -1
- package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.js +20 -4
- package/dist-esm/samples-dev/cloudHsmClusterPrivateLinkResourcesListByCloudHsmClusterSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClusterRestoreStatusGetSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClusterRestoreStatusGetSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClusterRestoreStatusGetSample.js +40 -0
- package/dist-esm/samples-dev/cloudHsmClusterRestoreStatusGetSample.js.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersBackupSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClustersBackupSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersBackupSample.js +39 -0
- package/dist-esm/samples-dev/cloudHsmClustersBackupSample.js.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.js +6 -6
- package/dist-esm/samples-dev/cloudHsmClustersCreateOrUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersDeleteSample.js +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersGetSample.js +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.js +2 -2
- package/dist-esm/samples-dev/cloudHsmClustersListByResourceGroupSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.js +2 -2
- package/dist-esm/samples-dev/cloudHsmClustersListBySubscriptionSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersRestoreSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClustersRestoreSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersRestoreSample.js +43 -0
- package/dist-esm/samples-dev/cloudHsmClustersRestoreSample.js.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.js +4 -4
- package/dist-esm/samples-dev/cloudHsmClustersUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/cloudHsmClustersValidateBackupPropertiesSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateBackupPropertiesSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateBackupPropertiesSample.js +39 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateBackupPropertiesSample.js.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateRestorePropertiesSample.d.ts +2 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateRestorePropertiesSample.d.ts.map +1 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateRestorePropertiesSample.js +46 -0
- package/dist-esm/samples-dev/cloudHsmClustersValidateRestorePropertiesSample.js.map +1 -0
- package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js +15 -15
- package/dist-esm/samples-dev/dedicatedHsmCreateOrUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/dedicatedHsmDeleteSample.js +1 -1
- package/dist-esm/samples-dev/dedicatedHsmGetSample.js +3 -3
- package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js +4 -4
- package/dist-esm/samples-dev/dedicatedHsmListByResourceGroupSample.js.map +1 -1
- package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js +4 -4
- package/dist-esm/samples-dev/dedicatedHsmListBySubscriptionSample.js.map +1 -1
- package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js +2 -2
- package/dist-esm/samples-dev/dedicatedHsmListOutboundNetworkDependenciesEndpointsSample.js.map +1 -1
- package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js +3 -3
- package/dist-esm/samples-dev/dedicatedHsmUpdateSample.js.map +1 -1
- package/dist-esm/samples-dev/operationsListSample.js +8 -8
- package/dist-esm/samples-dev/operationsListSample.js.map +1 -1
- package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.js +2 -2
- package/dist-esm/samples-dev/privateEndpointConnectionsListByCloudHsmClusterSample.js.map +1 -1
- package/dist-esm/src/azureHSMResourceProvider.d.ts +7 -2
- package/dist-esm/src/azureHSMResourceProvider.d.ts.map +1 -1
- package/dist-esm/src/azureHSMResourceProvider.js +44 -10
- package/dist-esm/src/azureHSMResourceProvider.js.map +1 -1
- package/dist-esm/src/index.d.ts +0 -1
- package/dist-esm/src/index.d.ts.map +1 -1
- package/dist-esm/src/lroImpl.js +1 -1
- package/dist-esm/src/models/index.d.ts +543 -263
- package/dist-esm/src/models/index.d.ts.map +1 -1
- package/dist-esm/src/models/index.js +109 -49
- package/dist-esm/src/models/index.js.map +1 -1
- package/dist-esm/src/models/mappers.d.ts +28 -16
- package/dist-esm/src/models/mappers.d.ts.map +1 -1
- package/dist-esm/src/models/mappers.js +832 -637
- package/dist-esm/src/models/mappers.js.map +1 -1
- package/dist-esm/src/models/parameters.d.ts +5 -12
- package/dist-esm/src/models/parameters.d.ts.map +1 -1
- package/dist-esm/src/models/parameters.js +76 -117
- package/dist-esm/src/models/parameters.js.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusterBackupStatus.d.ts +22 -0
- package/dist-esm/src/operations/cloudHsmClusterBackupStatus.d.ts.map +1 -0
- package/dist-esm/src/operations/cloudHsmClusterBackupStatus.js +61 -0
- package/dist-esm/src/operations/cloudHsmClusterBackupStatus.js.map +1 -0
- package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.d.ts +7 -7
- package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.d.ts.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.js +37 -29
- package/dist-esm/src/operations/cloudHsmClusterPrivateEndpointConnections.js.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.d.ts +23 -3
- package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.d.ts.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.js +105 -6
- package/dist-esm/src/operations/cloudHsmClusterPrivateLinkResources.js.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusterRestoreStatus.d.ts +22 -0
- package/dist-esm/src/operations/cloudHsmClusterRestoreStatus.d.ts.map +1 -0
- package/dist-esm/src/operations/cloudHsmClusterRestoreStatus.js +61 -0
- package/dist-esm/src/operations/cloudHsmClusterRestoreStatus.js.map +1 -0
- package/dist-esm/src/operations/cloudHsmClusters.d.ts +78 -10
- package/dist-esm/src/operations/cloudHsmClusters.d.ts.map +1 -1
- package/dist-esm/src/operations/cloudHsmClusters.js +467 -82
- package/dist-esm/src/operations/cloudHsmClusters.js.map +1 -1
- package/dist-esm/src/operations/dedicatedHsmOperations.d.ts +24 -24
- package/dist-esm/src/operations/dedicatedHsmOperations.d.ts.map +1 -1
- package/dist-esm/src/operations/dedicatedHsmOperations.js +117 -109
- package/dist-esm/src/operations/dedicatedHsmOperations.js.map +1 -1
- package/dist-esm/src/operations/index.d.ts +3 -1
- package/dist-esm/src/operations/index.d.ts.map +1 -1
- package/dist-esm/src/operations/index.js +3 -1
- package/dist-esm/src/operations/index.js.map +1 -1
- package/dist-esm/src/operations/operations.d.ts +4 -4
- package/dist-esm/src/operations/operations.d.ts.map +1 -1
- package/dist-esm/src/operations/operations.js +8 -8
- package/dist-esm/src/operations/operations.js.map +1 -1
- package/dist-esm/src/operations/privateEndpointConnections.d.ts +3 -3
- package/dist-esm/src/operations/privateEndpointConnections.d.ts.map +1 -1
- package/dist-esm/src/operations/privateEndpointConnections.js +14 -14
- package/dist-esm/src/operations/privateEndpointConnections.js.map +1 -1
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterBackupStatus.d.ts +14 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterBackupStatus.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterBackupStatus.js +9 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterBackupStatus.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.d.ts +7 -7
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.d.ts +4 -3
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterRestoreStatus.d.ts +14 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterRestoreStatus.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterRestoreStatus.js +9 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusterRestoreStatus.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/cloudHsmClusters.d.ts +78 -10
- package/dist-esm/src/operationsInterfaces/cloudHsmClusters.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts +18 -18
- package/dist-esm/src/operationsInterfaces/dedicatedHsmOperations.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/index.d.ts +3 -1
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/index.js +3 -1
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -1
- package/dist-esm/src/operationsInterfaces/operations.d.ts +3 -3
- package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -1
- package/dist-esm/src/operationsInterfaces/privateEndpointConnections.d.ts +1 -1
- package/dist-esm/src/pagingHelper.js.map +1 -1
- package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.d.ts.map +1 -1
- package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.js +6 -2
- package/dist-esm/test/hardwaresecuritymodules_operations_test.spec.js.map +1 -1
- package/package.json +14 -15
- package/review/arm-hardwaresecuritymodules.api.md +298 -93
- package/src/azureHSMResourceProvider.ts +67 -20
- package/src/lroImpl.ts +4 -4
- package/src/models/index.ts +633 -284
- package/src/models/mappers.ts +898 -675
- package/src/models/parameters.ts +82 -128
- package/src/operations/cloudHsmClusterBackupStatus.ts +82 -0
- package/src/operations/cloudHsmClusterPrivateEndpointConnections.ts +74 -56
- package/src/operations/cloudHsmClusterPrivateLinkResources.ts +145 -13
- package/src/operations/cloudHsmClusterRestoreStatus.ts +82 -0
- package/src/operations/cloudHsmClusters.ts +684 -151
- package/src/operations/dedicatedHsmOperations.ts +224 -215
- package/src/operations/index.ts +3 -1
- package/src/operations/operations.ts +17 -17
- package/src/operations/privateEndpointConnections.ts +30 -30
- package/src/operationsInterfaces/cloudHsmClusterBackupStatus.ts +30 -0
- package/src/operationsInterfaces/cloudHsmClusterPrivateEndpointConnections.ts +17 -11
- package/src/operationsInterfaces/cloudHsmClusterPrivateLinkResources.ts +6 -4
- package/src/operationsInterfaces/cloudHsmClusterRestoreStatus.ts +30 -0
- package/src/operationsInterfaces/cloudHsmClusters.ts +156 -19
- package/src/operationsInterfaces/dedicatedHsmOperations.ts +34 -28
- package/src/operationsInterfaces/index.ts +3 -1
- package/src/operationsInterfaces/operations.ts +4 -4
- package/src/operationsInterfaces/privateEndpointConnections.ts +3 -3
- package/src/pagingHelper.ts +1 -1
- package/types/arm-hardwaresecuritymodules.d.ts +625 -205
- package/types/tsdoc-metadata.json +1 -1
|
@@ -16,7 +16,7 @@ import { AzureHSMResourceProvider } from "../azureHSMResourceProvider";
|
|
|
16
16
|
import {
|
|
17
17
|
SimplePollerLike,
|
|
18
18
|
OperationState,
|
|
19
|
-
createHttpPoller
|
|
19
|
+
createHttpPoller,
|
|
20
20
|
} from "@azure/core-lro";
|
|
21
21
|
import { createLroSpec } from "../lroImpl";
|
|
22
22
|
import {
|
|
@@ -34,8 +34,18 @@ import {
|
|
|
34
34
|
CloudHsmClustersGetOptionalParams,
|
|
35
35
|
CloudHsmClustersGetResponse,
|
|
36
36
|
CloudHsmClustersDeleteOptionalParams,
|
|
37
|
+
CloudHsmClustersDeleteResponse,
|
|
38
|
+
CloudHsmClustersValidateBackupPropertiesOptionalParams,
|
|
39
|
+
CloudHsmClustersValidateBackupPropertiesResponse,
|
|
40
|
+
CloudHsmClustersBackupOptionalParams,
|
|
41
|
+
CloudHsmClustersBackupResponse,
|
|
42
|
+
CloudHsmClustersValidateRestorePropertiesOptionalParams,
|
|
43
|
+
CloudHsmClustersValidateRestorePropertiesResponse,
|
|
44
|
+
RestoreRequestProperties,
|
|
45
|
+
CloudHsmClustersRestoreOptionalParams,
|
|
46
|
+
CloudHsmClustersRestoreResponse,
|
|
37
47
|
CloudHsmClustersListByResourceGroupNextResponse,
|
|
38
|
-
CloudHsmClustersListBySubscriptionNextResponse
|
|
48
|
+
CloudHsmClustersListBySubscriptionNextResponse,
|
|
39
49
|
} from "../models";
|
|
40
50
|
|
|
41
51
|
/// <reference lib="esnext.asynciterable" />
|
|
@@ -59,7 +69,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
59
69
|
*/
|
|
60
70
|
public listByResourceGroup(
|
|
61
71
|
resourceGroupName: string,
|
|
62
|
-
options?: CloudHsmClustersListByResourceGroupOptionalParams
|
|
72
|
+
options?: CloudHsmClustersListByResourceGroupOptionalParams,
|
|
63
73
|
): PagedAsyncIterableIterator<CloudHsmCluster> {
|
|
64
74
|
const iter = this.listByResourceGroupPagingAll(resourceGroupName, options);
|
|
65
75
|
return {
|
|
@@ -76,16 +86,16 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
76
86
|
return this.listByResourceGroupPagingPage(
|
|
77
87
|
resourceGroupName,
|
|
78
88
|
options,
|
|
79
|
-
settings
|
|
89
|
+
settings,
|
|
80
90
|
);
|
|
81
|
-
}
|
|
91
|
+
},
|
|
82
92
|
};
|
|
83
93
|
}
|
|
84
94
|
|
|
85
95
|
private async *listByResourceGroupPagingPage(
|
|
86
96
|
resourceGroupName: string,
|
|
87
97
|
options?: CloudHsmClustersListByResourceGroupOptionalParams,
|
|
88
|
-
settings?: PageSettings
|
|
98
|
+
settings?: PageSettings,
|
|
89
99
|
): AsyncIterableIterator<CloudHsmCluster[]> {
|
|
90
100
|
let result: CloudHsmClustersListByResourceGroupResponse;
|
|
91
101
|
let continuationToken = settings?.continuationToken;
|
|
@@ -100,7 +110,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
100
110
|
result = await this._listByResourceGroupNext(
|
|
101
111
|
resourceGroupName,
|
|
102
112
|
continuationToken,
|
|
103
|
-
options
|
|
113
|
+
options,
|
|
104
114
|
);
|
|
105
115
|
continuationToken = result.nextLink;
|
|
106
116
|
let page = result.value || [];
|
|
@@ -111,11 +121,11 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
111
121
|
|
|
112
122
|
private async *listByResourceGroupPagingAll(
|
|
113
123
|
resourceGroupName: string,
|
|
114
|
-
options?: CloudHsmClustersListByResourceGroupOptionalParams
|
|
124
|
+
options?: CloudHsmClustersListByResourceGroupOptionalParams,
|
|
115
125
|
): AsyncIterableIterator<CloudHsmCluster> {
|
|
116
126
|
for await (const page of this.listByResourceGroupPagingPage(
|
|
117
127
|
resourceGroupName,
|
|
118
|
-
options
|
|
128
|
+
options,
|
|
119
129
|
)) {
|
|
120
130
|
yield* page;
|
|
121
131
|
}
|
|
@@ -126,7 +136,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
126
136
|
* @param options The options parameters.
|
|
127
137
|
*/
|
|
128
138
|
public listBySubscription(
|
|
129
|
-
options?: CloudHsmClustersListBySubscriptionOptionalParams
|
|
139
|
+
options?: CloudHsmClustersListBySubscriptionOptionalParams,
|
|
130
140
|
): PagedAsyncIterableIterator<CloudHsmCluster> {
|
|
131
141
|
const iter = this.listBySubscriptionPagingAll(options);
|
|
132
142
|
return {
|
|
@@ -141,13 +151,13 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
141
151
|
throw new Error("maxPageSize is not supported by this operation.");
|
|
142
152
|
}
|
|
143
153
|
return this.listBySubscriptionPagingPage(options, settings);
|
|
144
|
-
}
|
|
154
|
+
},
|
|
145
155
|
};
|
|
146
156
|
}
|
|
147
157
|
|
|
148
158
|
private async *listBySubscriptionPagingPage(
|
|
149
159
|
options?: CloudHsmClustersListBySubscriptionOptionalParams,
|
|
150
|
-
settings?: PageSettings
|
|
160
|
+
settings?: PageSettings,
|
|
151
161
|
): AsyncIterableIterator<CloudHsmCluster[]> {
|
|
152
162
|
let result: CloudHsmClustersListBySubscriptionResponse;
|
|
153
163
|
let continuationToken = settings?.continuationToken;
|
|
@@ -168,7 +178,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
168
178
|
}
|
|
169
179
|
|
|
170
180
|
private async *listBySubscriptionPagingAll(
|
|
171
|
-
options?: CloudHsmClustersListBySubscriptionOptionalParams
|
|
181
|
+
options?: CloudHsmClustersListBySubscriptionOptionalParams,
|
|
172
182
|
): AsyncIterableIterator<CloudHsmCluster> {
|
|
173
183
|
for await (const page of this.listBySubscriptionPagingPage(options)) {
|
|
174
184
|
yield* page;
|
|
@@ -179,7 +189,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
179
189
|
* Create or Update a Cloud HSM Cluster in the specified subscription.
|
|
180
190
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
181
191
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
182
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
192
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
183
193
|
* @param location The geo-location where the resource lives
|
|
184
194
|
* @param options The options parameters.
|
|
185
195
|
*/
|
|
@@ -187,7 +197,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
187
197
|
resourceGroupName: string,
|
|
188
198
|
cloudHsmClusterName: string,
|
|
189
199
|
location: string,
|
|
190
|
-
options?: CloudHsmClustersCreateOrUpdateOptionalParams
|
|
200
|
+
options?: CloudHsmClustersCreateOrUpdateOptionalParams,
|
|
191
201
|
): Promise<
|
|
192
202
|
SimplePollerLike<
|
|
193
203
|
OperationState<CloudHsmClustersCreateOrUpdateResponse>,
|
|
@@ -196,21 +206,20 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
196
206
|
> {
|
|
197
207
|
const directSendOperation = async (
|
|
198
208
|
args: coreClient.OperationArguments,
|
|
199
|
-
spec: coreClient.OperationSpec
|
|
209
|
+
spec: coreClient.OperationSpec,
|
|
200
210
|
): Promise<CloudHsmClustersCreateOrUpdateResponse> => {
|
|
201
211
|
return this.client.sendOperationRequest(args, spec);
|
|
202
212
|
};
|
|
203
213
|
const sendOperationFn = async (
|
|
204
214
|
args: coreClient.OperationArguments,
|
|
205
|
-
spec: coreClient.OperationSpec
|
|
215
|
+
spec: coreClient.OperationSpec,
|
|
206
216
|
) => {
|
|
207
|
-
let currentRawResponse:
|
|
208
|
-
|
|
209
|
-
| undefined = undefined;
|
|
217
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
218
|
+
undefined;
|
|
210
219
|
const providedCallback = args.options?.onResponse;
|
|
211
220
|
const callback: coreClient.RawResponseCallback = (
|
|
212
221
|
rawResponse: coreClient.FullOperationResponse,
|
|
213
|
-
flatResponse: unknown
|
|
222
|
+
flatResponse: unknown,
|
|
214
223
|
) => {
|
|
215
224
|
currentRawResponse = rawResponse;
|
|
216
225
|
providedCallback?.(rawResponse, flatResponse);
|
|
@@ -219,8 +228,8 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
219
228
|
...args,
|
|
220
229
|
options: {
|
|
221
230
|
...args.options,
|
|
222
|
-
onResponse: callback
|
|
223
|
-
}
|
|
231
|
+
onResponse: callback,
|
|
232
|
+
},
|
|
224
233
|
};
|
|
225
234
|
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
226
235
|
return {
|
|
@@ -228,15 +237,15 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
228
237
|
rawResponse: {
|
|
229
238
|
statusCode: currentRawResponse!.status,
|
|
230
239
|
body: currentRawResponse!.parsedBody,
|
|
231
|
-
headers: currentRawResponse!.headers.toJSON()
|
|
232
|
-
}
|
|
240
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
241
|
+
},
|
|
233
242
|
};
|
|
234
243
|
};
|
|
235
244
|
|
|
236
245
|
const lro = createLroSpec({
|
|
237
246
|
sendOperationFn,
|
|
238
247
|
args: { resourceGroupName, cloudHsmClusterName, location, options },
|
|
239
|
-
spec: createOrUpdateOperationSpec
|
|
248
|
+
spec: createOrUpdateOperationSpec,
|
|
240
249
|
});
|
|
241
250
|
const poller = await createHttpPoller<
|
|
242
251
|
CloudHsmClustersCreateOrUpdateResponse,
|
|
@@ -244,7 +253,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
244
253
|
>(lro, {
|
|
245
254
|
restoreFrom: options?.resumeFrom,
|
|
246
255
|
intervalInMs: options?.updateIntervalInMs,
|
|
247
|
-
resourceLocationConfig: "original-uri"
|
|
256
|
+
resourceLocationConfig: "original-uri",
|
|
248
257
|
});
|
|
249
258
|
await poller.poll();
|
|
250
259
|
return poller;
|
|
@@ -254,7 +263,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
254
263
|
* Create or Update a Cloud HSM Cluster in the specified subscription.
|
|
255
264
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
256
265
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
257
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
266
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
258
267
|
* @param location The geo-location where the resource lives
|
|
259
268
|
* @param options The options parameters.
|
|
260
269
|
*/
|
|
@@ -262,13 +271,13 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
262
271
|
resourceGroupName: string,
|
|
263
272
|
cloudHsmClusterName: string,
|
|
264
273
|
location: string,
|
|
265
|
-
options?: CloudHsmClustersCreateOrUpdateOptionalParams
|
|
274
|
+
options?: CloudHsmClustersCreateOrUpdateOptionalParams,
|
|
266
275
|
): Promise<CloudHsmClustersCreateOrUpdateResponse> {
|
|
267
276
|
const poller = await this.beginCreateOrUpdate(
|
|
268
277
|
resourceGroupName,
|
|
269
278
|
cloudHsmClusterName,
|
|
270
279
|
location,
|
|
271
|
-
options
|
|
280
|
+
options,
|
|
272
281
|
);
|
|
273
282
|
return poller.pollUntilDone();
|
|
274
283
|
}
|
|
@@ -277,13 +286,13 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
277
286
|
* Update a Cloud HSM Cluster in the specified subscription.
|
|
278
287
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
279
288
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
280
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
289
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
281
290
|
* @param options The options parameters.
|
|
282
291
|
*/
|
|
283
292
|
async beginUpdate(
|
|
284
293
|
resourceGroupName: string,
|
|
285
294
|
cloudHsmClusterName: string,
|
|
286
|
-
options?: CloudHsmClustersUpdateOptionalParams
|
|
295
|
+
options?: CloudHsmClustersUpdateOptionalParams,
|
|
287
296
|
): Promise<
|
|
288
297
|
SimplePollerLike<
|
|
289
298
|
OperationState<CloudHsmClustersUpdateResponse>,
|
|
@@ -292,21 +301,20 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
292
301
|
> {
|
|
293
302
|
const directSendOperation = async (
|
|
294
303
|
args: coreClient.OperationArguments,
|
|
295
|
-
spec: coreClient.OperationSpec
|
|
304
|
+
spec: coreClient.OperationSpec,
|
|
296
305
|
): Promise<CloudHsmClustersUpdateResponse> => {
|
|
297
306
|
return this.client.sendOperationRequest(args, spec);
|
|
298
307
|
};
|
|
299
308
|
const sendOperationFn = async (
|
|
300
309
|
args: coreClient.OperationArguments,
|
|
301
|
-
spec: coreClient.OperationSpec
|
|
310
|
+
spec: coreClient.OperationSpec,
|
|
302
311
|
) => {
|
|
303
|
-
let currentRawResponse:
|
|
304
|
-
|
|
305
|
-
| undefined = undefined;
|
|
312
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
313
|
+
undefined;
|
|
306
314
|
const providedCallback = args.options?.onResponse;
|
|
307
315
|
const callback: coreClient.RawResponseCallback = (
|
|
308
316
|
rawResponse: coreClient.FullOperationResponse,
|
|
309
|
-
flatResponse: unknown
|
|
317
|
+
flatResponse: unknown,
|
|
310
318
|
) => {
|
|
311
319
|
currentRawResponse = rawResponse;
|
|
312
320
|
providedCallback?.(rawResponse, flatResponse);
|
|
@@ -315,8 +323,8 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
315
323
|
...args,
|
|
316
324
|
options: {
|
|
317
325
|
...args.options,
|
|
318
|
-
onResponse: callback
|
|
319
|
-
}
|
|
326
|
+
onResponse: callback,
|
|
327
|
+
},
|
|
320
328
|
};
|
|
321
329
|
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
322
330
|
return {
|
|
@@ -324,15 +332,15 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
324
332
|
rawResponse: {
|
|
325
333
|
statusCode: currentRawResponse!.status,
|
|
326
334
|
body: currentRawResponse!.parsedBody,
|
|
327
|
-
headers: currentRawResponse!.headers.toJSON()
|
|
328
|
-
}
|
|
335
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
336
|
+
},
|
|
329
337
|
};
|
|
330
338
|
};
|
|
331
339
|
|
|
332
340
|
const lro = createLroSpec({
|
|
333
341
|
sendOperationFn,
|
|
334
342
|
args: { resourceGroupName, cloudHsmClusterName, options },
|
|
335
|
-
spec: updateOperationSpec
|
|
343
|
+
spec: updateOperationSpec,
|
|
336
344
|
});
|
|
337
345
|
const poller = await createHttpPoller<
|
|
338
346
|
CloudHsmClustersUpdateResponse,
|
|
@@ -340,7 +348,7 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
340
348
|
>(lro, {
|
|
341
349
|
restoreFrom: options?.resumeFrom,
|
|
342
350
|
intervalInMs: options?.updateIntervalInMs,
|
|
343
|
-
resourceLocationConfig: "location"
|
|
351
|
+
resourceLocationConfig: "location",
|
|
344
352
|
});
|
|
345
353
|
await poller.poll();
|
|
346
354
|
return poller;
|
|
@@ -350,18 +358,18 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
350
358
|
* Update a Cloud HSM Cluster in the specified subscription.
|
|
351
359
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
352
360
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
353
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
361
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
354
362
|
* @param options The options parameters.
|
|
355
363
|
*/
|
|
356
364
|
async beginUpdateAndWait(
|
|
357
365
|
resourceGroupName: string,
|
|
358
366
|
cloudHsmClusterName: string,
|
|
359
|
-
options?: CloudHsmClustersUpdateOptionalParams
|
|
367
|
+
options?: CloudHsmClustersUpdateOptionalParams,
|
|
360
368
|
): Promise<CloudHsmClustersUpdateResponse> {
|
|
361
369
|
const poller = await this.beginUpdate(
|
|
362
370
|
resourceGroupName,
|
|
363
371
|
cloudHsmClusterName,
|
|
364
|
-
options
|
|
372
|
+
options,
|
|
365
373
|
);
|
|
366
374
|
return poller.pollUntilDone();
|
|
367
375
|
}
|
|
@@ -370,17 +378,17 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
370
378
|
* Gets the specified Cloud HSM Cluster
|
|
371
379
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
372
380
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
373
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
381
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
374
382
|
* @param options The options parameters.
|
|
375
383
|
*/
|
|
376
384
|
get(
|
|
377
385
|
resourceGroupName: string,
|
|
378
386
|
cloudHsmClusterName: string,
|
|
379
|
-
options?: CloudHsmClustersGetOptionalParams
|
|
387
|
+
options?: CloudHsmClustersGetOptionalParams,
|
|
380
388
|
): Promise<CloudHsmClustersGetResponse> {
|
|
381
389
|
return this.client.sendOperationRequest(
|
|
382
390
|
{ resourceGroupName, cloudHsmClusterName, options },
|
|
383
|
-
getOperationSpec
|
|
391
|
+
getOperationSpec,
|
|
384
392
|
);
|
|
385
393
|
}
|
|
386
394
|
|
|
@@ -388,31 +396,35 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
388
396
|
* Deletes the specified Cloud HSM Cluster
|
|
389
397
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
390
398
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
391
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
399
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
392
400
|
* @param options The options parameters.
|
|
393
401
|
*/
|
|
394
402
|
async beginDelete(
|
|
395
403
|
resourceGroupName: string,
|
|
396
404
|
cloudHsmClusterName: string,
|
|
397
|
-
options?: CloudHsmClustersDeleteOptionalParams
|
|
398
|
-
): Promise<
|
|
405
|
+
options?: CloudHsmClustersDeleteOptionalParams,
|
|
406
|
+
): Promise<
|
|
407
|
+
SimplePollerLike<
|
|
408
|
+
OperationState<CloudHsmClustersDeleteResponse>,
|
|
409
|
+
CloudHsmClustersDeleteResponse
|
|
410
|
+
>
|
|
411
|
+
> {
|
|
399
412
|
const directSendOperation = async (
|
|
400
413
|
args: coreClient.OperationArguments,
|
|
401
|
-
spec: coreClient.OperationSpec
|
|
402
|
-
): Promise<
|
|
414
|
+
spec: coreClient.OperationSpec,
|
|
415
|
+
): Promise<CloudHsmClustersDeleteResponse> => {
|
|
403
416
|
return this.client.sendOperationRequest(args, spec);
|
|
404
417
|
};
|
|
405
418
|
const sendOperationFn = async (
|
|
406
419
|
args: coreClient.OperationArguments,
|
|
407
|
-
spec: coreClient.OperationSpec
|
|
420
|
+
spec: coreClient.OperationSpec,
|
|
408
421
|
) => {
|
|
409
|
-
let currentRawResponse:
|
|
410
|
-
|
|
411
|
-
| undefined = undefined;
|
|
422
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
423
|
+
undefined;
|
|
412
424
|
const providedCallback = args.options?.onResponse;
|
|
413
425
|
const callback: coreClient.RawResponseCallback = (
|
|
414
426
|
rawResponse: coreClient.FullOperationResponse,
|
|
415
|
-
flatResponse: unknown
|
|
427
|
+
flatResponse: unknown,
|
|
416
428
|
) => {
|
|
417
429
|
currentRawResponse = rawResponse;
|
|
418
430
|
providedCallback?.(rawResponse, flatResponse);
|
|
@@ -421,8 +433,8 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
421
433
|
...args,
|
|
422
434
|
options: {
|
|
423
435
|
...args.options,
|
|
424
|
-
onResponse: callback
|
|
425
|
-
}
|
|
436
|
+
onResponse: callback,
|
|
437
|
+
},
|
|
426
438
|
};
|
|
427
439
|
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
428
440
|
return {
|
|
@@ -430,20 +442,23 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
430
442
|
rawResponse: {
|
|
431
443
|
statusCode: currentRawResponse!.status,
|
|
432
444
|
body: currentRawResponse!.parsedBody,
|
|
433
|
-
headers: currentRawResponse!.headers.toJSON()
|
|
434
|
-
}
|
|
445
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
446
|
+
},
|
|
435
447
|
};
|
|
436
448
|
};
|
|
437
449
|
|
|
438
450
|
const lro = createLroSpec({
|
|
439
451
|
sendOperationFn,
|
|
440
452
|
args: { resourceGroupName, cloudHsmClusterName, options },
|
|
441
|
-
spec: deleteOperationSpec
|
|
453
|
+
spec: deleteOperationSpec,
|
|
442
454
|
});
|
|
443
|
-
const poller = await createHttpPoller<
|
|
455
|
+
const poller = await createHttpPoller<
|
|
456
|
+
CloudHsmClustersDeleteResponse,
|
|
457
|
+
OperationState<CloudHsmClustersDeleteResponse>
|
|
458
|
+
>(lro, {
|
|
444
459
|
restoreFrom: options?.resumeFrom,
|
|
445
460
|
intervalInMs: options?.updateIntervalInMs,
|
|
446
|
-
resourceLocationConfig: "location"
|
|
461
|
+
resourceLocationConfig: "location",
|
|
447
462
|
});
|
|
448
463
|
await poller.poll();
|
|
449
464
|
return poller;
|
|
@@ -453,18 +468,18 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
453
468
|
* Deletes the specified Cloud HSM Cluster
|
|
454
469
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
455
470
|
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
456
|
-
* Cloud HSM Cluster names must be between 3 and
|
|
471
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
457
472
|
* @param options The options parameters.
|
|
458
473
|
*/
|
|
459
474
|
async beginDeleteAndWait(
|
|
460
475
|
resourceGroupName: string,
|
|
461
476
|
cloudHsmClusterName: string,
|
|
462
|
-
options?: CloudHsmClustersDeleteOptionalParams
|
|
463
|
-
): Promise<
|
|
477
|
+
options?: CloudHsmClustersDeleteOptionalParams,
|
|
478
|
+
): Promise<CloudHsmClustersDeleteResponse> {
|
|
464
479
|
const poller = await this.beginDelete(
|
|
465
480
|
resourceGroupName,
|
|
466
481
|
cloudHsmClusterName,
|
|
467
|
-
options
|
|
482
|
+
options,
|
|
468
483
|
);
|
|
469
484
|
return poller.pollUntilDone();
|
|
470
485
|
}
|
|
@@ -477,11 +492,11 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
477
492
|
*/
|
|
478
493
|
private _listByResourceGroup(
|
|
479
494
|
resourceGroupName: string,
|
|
480
|
-
options?: CloudHsmClustersListByResourceGroupOptionalParams
|
|
495
|
+
options?: CloudHsmClustersListByResourceGroupOptionalParams,
|
|
481
496
|
): Promise<CloudHsmClustersListByResourceGroupResponse> {
|
|
482
497
|
return this.client.sendOperationRequest(
|
|
483
498
|
{ resourceGroupName, options },
|
|
484
|
-
listByResourceGroupOperationSpec
|
|
499
|
+
listByResourceGroupOperationSpec,
|
|
485
500
|
);
|
|
486
501
|
}
|
|
487
502
|
|
|
@@ -490,14 +505,394 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
490
505
|
* @param options The options parameters.
|
|
491
506
|
*/
|
|
492
507
|
private _listBySubscription(
|
|
493
|
-
options?: CloudHsmClustersListBySubscriptionOptionalParams
|
|
508
|
+
options?: CloudHsmClustersListBySubscriptionOptionalParams,
|
|
494
509
|
): Promise<CloudHsmClustersListBySubscriptionResponse> {
|
|
495
510
|
return this.client.sendOperationRequest(
|
|
496
511
|
{ options },
|
|
497
|
-
listBySubscriptionOperationSpec
|
|
512
|
+
listBySubscriptionOperationSpec,
|
|
498
513
|
);
|
|
499
514
|
}
|
|
500
515
|
|
|
516
|
+
/**
|
|
517
|
+
* Pre Backup operation to validate whether the customer can perform a backup on the Cloud HSM Cluster
|
|
518
|
+
* resource in the specified subscription.
|
|
519
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
520
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
521
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
522
|
+
* @param options The options parameters.
|
|
523
|
+
*/
|
|
524
|
+
async beginValidateBackupProperties(
|
|
525
|
+
resourceGroupName: string,
|
|
526
|
+
cloudHsmClusterName: string,
|
|
527
|
+
options?: CloudHsmClustersValidateBackupPropertiesOptionalParams,
|
|
528
|
+
): Promise<
|
|
529
|
+
SimplePollerLike<
|
|
530
|
+
OperationState<CloudHsmClustersValidateBackupPropertiesResponse>,
|
|
531
|
+
CloudHsmClustersValidateBackupPropertiesResponse
|
|
532
|
+
>
|
|
533
|
+
> {
|
|
534
|
+
const directSendOperation = async (
|
|
535
|
+
args: coreClient.OperationArguments,
|
|
536
|
+
spec: coreClient.OperationSpec,
|
|
537
|
+
): Promise<CloudHsmClustersValidateBackupPropertiesResponse> => {
|
|
538
|
+
return this.client.sendOperationRequest(args, spec);
|
|
539
|
+
};
|
|
540
|
+
const sendOperationFn = async (
|
|
541
|
+
args: coreClient.OperationArguments,
|
|
542
|
+
spec: coreClient.OperationSpec,
|
|
543
|
+
) => {
|
|
544
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
545
|
+
undefined;
|
|
546
|
+
const providedCallback = args.options?.onResponse;
|
|
547
|
+
const callback: coreClient.RawResponseCallback = (
|
|
548
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
549
|
+
flatResponse: unknown,
|
|
550
|
+
) => {
|
|
551
|
+
currentRawResponse = rawResponse;
|
|
552
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
553
|
+
};
|
|
554
|
+
const updatedArgs = {
|
|
555
|
+
...args,
|
|
556
|
+
options: {
|
|
557
|
+
...args.options,
|
|
558
|
+
onResponse: callback,
|
|
559
|
+
},
|
|
560
|
+
};
|
|
561
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
562
|
+
return {
|
|
563
|
+
flatResponse,
|
|
564
|
+
rawResponse: {
|
|
565
|
+
statusCode: currentRawResponse!.status,
|
|
566
|
+
body: currentRawResponse!.parsedBody,
|
|
567
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
568
|
+
},
|
|
569
|
+
};
|
|
570
|
+
};
|
|
571
|
+
|
|
572
|
+
const lro = createLroSpec({
|
|
573
|
+
sendOperationFn,
|
|
574
|
+
args: { resourceGroupName, cloudHsmClusterName, options },
|
|
575
|
+
spec: validateBackupPropertiesOperationSpec,
|
|
576
|
+
});
|
|
577
|
+
const poller = await createHttpPoller<
|
|
578
|
+
CloudHsmClustersValidateBackupPropertiesResponse,
|
|
579
|
+
OperationState<CloudHsmClustersValidateBackupPropertiesResponse>
|
|
580
|
+
>(lro, {
|
|
581
|
+
restoreFrom: options?.resumeFrom,
|
|
582
|
+
intervalInMs: options?.updateIntervalInMs,
|
|
583
|
+
resourceLocationConfig: "azure-async-operation",
|
|
584
|
+
});
|
|
585
|
+
await poller.poll();
|
|
586
|
+
return poller;
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
/**
|
|
590
|
+
* Pre Backup operation to validate whether the customer can perform a backup on the Cloud HSM Cluster
|
|
591
|
+
* resource in the specified subscription.
|
|
592
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
593
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
594
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
595
|
+
* @param options The options parameters.
|
|
596
|
+
*/
|
|
597
|
+
async beginValidateBackupPropertiesAndWait(
|
|
598
|
+
resourceGroupName: string,
|
|
599
|
+
cloudHsmClusterName: string,
|
|
600
|
+
options?: CloudHsmClustersValidateBackupPropertiesOptionalParams,
|
|
601
|
+
): Promise<CloudHsmClustersValidateBackupPropertiesResponse> {
|
|
602
|
+
const poller = await this.beginValidateBackupProperties(
|
|
603
|
+
resourceGroupName,
|
|
604
|
+
cloudHsmClusterName,
|
|
605
|
+
options,
|
|
606
|
+
);
|
|
607
|
+
return poller.pollUntilDone();
|
|
608
|
+
}
|
|
609
|
+
|
|
610
|
+
/**
|
|
611
|
+
* Create a backup of the Cloud HSM Cluster in the specified subscription
|
|
612
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
613
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
614
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
615
|
+
* @param options The options parameters.
|
|
616
|
+
*/
|
|
617
|
+
async beginBackup(
|
|
618
|
+
resourceGroupName: string,
|
|
619
|
+
cloudHsmClusterName: string,
|
|
620
|
+
options?: CloudHsmClustersBackupOptionalParams,
|
|
621
|
+
): Promise<
|
|
622
|
+
SimplePollerLike<
|
|
623
|
+
OperationState<CloudHsmClustersBackupResponse>,
|
|
624
|
+
CloudHsmClustersBackupResponse
|
|
625
|
+
>
|
|
626
|
+
> {
|
|
627
|
+
const directSendOperation = async (
|
|
628
|
+
args: coreClient.OperationArguments,
|
|
629
|
+
spec: coreClient.OperationSpec,
|
|
630
|
+
): Promise<CloudHsmClustersBackupResponse> => {
|
|
631
|
+
return this.client.sendOperationRequest(args, spec);
|
|
632
|
+
};
|
|
633
|
+
const sendOperationFn = async (
|
|
634
|
+
args: coreClient.OperationArguments,
|
|
635
|
+
spec: coreClient.OperationSpec,
|
|
636
|
+
) => {
|
|
637
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
638
|
+
undefined;
|
|
639
|
+
const providedCallback = args.options?.onResponse;
|
|
640
|
+
const callback: coreClient.RawResponseCallback = (
|
|
641
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
642
|
+
flatResponse: unknown,
|
|
643
|
+
) => {
|
|
644
|
+
currentRawResponse = rawResponse;
|
|
645
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
646
|
+
};
|
|
647
|
+
const updatedArgs = {
|
|
648
|
+
...args,
|
|
649
|
+
options: {
|
|
650
|
+
...args.options,
|
|
651
|
+
onResponse: callback,
|
|
652
|
+
},
|
|
653
|
+
};
|
|
654
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
655
|
+
return {
|
|
656
|
+
flatResponse,
|
|
657
|
+
rawResponse: {
|
|
658
|
+
statusCode: currentRawResponse!.status,
|
|
659
|
+
body: currentRawResponse!.parsedBody,
|
|
660
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
661
|
+
},
|
|
662
|
+
};
|
|
663
|
+
};
|
|
664
|
+
|
|
665
|
+
const lro = createLroSpec({
|
|
666
|
+
sendOperationFn,
|
|
667
|
+
args: { resourceGroupName, cloudHsmClusterName, options },
|
|
668
|
+
spec: backupOperationSpec,
|
|
669
|
+
});
|
|
670
|
+
const poller = await createHttpPoller<
|
|
671
|
+
CloudHsmClustersBackupResponse,
|
|
672
|
+
OperationState<CloudHsmClustersBackupResponse>
|
|
673
|
+
>(lro, {
|
|
674
|
+
restoreFrom: options?.resumeFrom,
|
|
675
|
+
intervalInMs: options?.updateIntervalInMs,
|
|
676
|
+
resourceLocationConfig: "azure-async-operation",
|
|
677
|
+
});
|
|
678
|
+
await poller.poll();
|
|
679
|
+
return poller;
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
/**
|
|
683
|
+
* Create a backup of the Cloud HSM Cluster in the specified subscription
|
|
684
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
685
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
686
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
687
|
+
* @param options The options parameters.
|
|
688
|
+
*/
|
|
689
|
+
async beginBackupAndWait(
|
|
690
|
+
resourceGroupName: string,
|
|
691
|
+
cloudHsmClusterName: string,
|
|
692
|
+
options?: CloudHsmClustersBackupOptionalParams,
|
|
693
|
+
): Promise<CloudHsmClustersBackupResponse> {
|
|
694
|
+
const poller = await this.beginBackup(
|
|
695
|
+
resourceGroupName,
|
|
696
|
+
cloudHsmClusterName,
|
|
697
|
+
options,
|
|
698
|
+
);
|
|
699
|
+
return poller.pollUntilDone();
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
/**
|
|
703
|
+
* Queued validating pre restore operation
|
|
704
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
705
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
706
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
707
|
+
* @param options The options parameters.
|
|
708
|
+
*/
|
|
709
|
+
async beginValidateRestoreProperties(
|
|
710
|
+
resourceGroupName: string,
|
|
711
|
+
cloudHsmClusterName: string,
|
|
712
|
+
options?: CloudHsmClustersValidateRestorePropertiesOptionalParams,
|
|
713
|
+
): Promise<
|
|
714
|
+
SimplePollerLike<
|
|
715
|
+
OperationState<CloudHsmClustersValidateRestorePropertiesResponse>,
|
|
716
|
+
CloudHsmClustersValidateRestorePropertiesResponse
|
|
717
|
+
>
|
|
718
|
+
> {
|
|
719
|
+
const directSendOperation = async (
|
|
720
|
+
args: coreClient.OperationArguments,
|
|
721
|
+
spec: coreClient.OperationSpec,
|
|
722
|
+
): Promise<CloudHsmClustersValidateRestorePropertiesResponse> => {
|
|
723
|
+
return this.client.sendOperationRequest(args, spec);
|
|
724
|
+
};
|
|
725
|
+
const sendOperationFn = async (
|
|
726
|
+
args: coreClient.OperationArguments,
|
|
727
|
+
spec: coreClient.OperationSpec,
|
|
728
|
+
) => {
|
|
729
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
730
|
+
undefined;
|
|
731
|
+
const providedCallback = args.options?.onResponse;
|
|
732
|
+
const callback: coreClient.RawResponseCallback = (
|
|
733
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
734
|
+
flatResponse: unknown,
|
|
735
|
+
) => {
|
|
736
|
+
currentRawResponse = rawResponse;
|
|
737
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
738
|
+
};
|
|
739
|
+
const updatedArgs = {
|
|
740
|
+
...args,
|
|
741
|
+
options: {
|
|
742
|
+
...args.options,
|
|
743
|
+
onResponse: callback,
|
|
744
|
+
},
|
|
745
|
+
};
|
|
746
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
747
|
+
return {
|
|
748
|
+
flatResponse,
|
|
749
|
+
rawResponse: {
|
|
750
|
+
statusCode: currentRawResponse!.status,
|
|
751
|
+
body: currentRawResponse!.parsedBody,
|
|
752
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
753
|
+
},
|
|
754
|
+
};
|
|
755
|
+
};
|
|
756
|
+
|
|
757
|
+
const lro = createLroSpec({
|
|
758
|
+
sendOperationFn,
|
|
759
|
+
args: { resourceGroupName, cloudHsmClusterName, options },
|
|
760
|
+
spec: validateRestorePropertiesOperationSpec,
|
|
761
|
+
});
|
|
762
|
+
const poller = await createHttpPoller<
|
|
763
|
+
CloudHsmClustersValidateRestorePropertiesResponse,
|
|
764
|
+
OperationState<CloudHsmClustersValidateRestorePropertiesResponse>
|
|
765
|
+
>(lro, {
|
|
766
|
+
restoreFrom: options?.resumeFrom,
|
|
767
|
+
intervalInMs: options?.updateIntervalInMs,
|
|
768
|
+
resourceLocationConfig: "azure-async-operation",
|
|
769
|
+
});
|
|
770
|
+
await poller.poll();
|
|
771
|
+
return poller;
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
/**
|
|
775
|
+
* Queued validating pre restore operation
|
|
776
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
777
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
778
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
779
|
+
* @param options The options parameters.
|
|
780
|
+
*/
|
|
781
|
+
async beginValidateRestorePropertiesAndWait(
|
|
782
|
+
resourceGroupName: string,
|
|
783
|
+
cloudHsmClusterName: string,
|
|
784
|
+
options?: CloudHsmClustersValidateRestorePropertiesOptionalParams,
|
|
785
|
+
): Promise<CloudHsmClustersValidateRestorePropertiesResponse> {
|
|
786
|
+
const poller = await this.beginValidateRestoreProperties(
|
|
787
|
+
resourceGroupName,
|
|
788
|
+
cloudHsmClusterName,
|
|
789
|
+
options,
|
|
790
|
+
);
|
|
791
|
+
return poller.pollUntilDone();
|
|
792
|
+
}
|
|
793
|
+
|
|
794
|
+
/**
|
|
795
|
+
* Restores all key materials of a specified Cloud HSM Cluster
|
|
796
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
797
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
798
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
799
|
+
* @param restoreRequestProperties Restore Operation Required properties
|
|
800
|
+
* @param options The options parameters.
|
|
801
|
+
*/
|
|
802
|
+
async beginRestore(
|
|
803
|
+
resourceGroupName: string,
|
|
804
|
+
cloudHsmClusterName: string,
|
|
805
|
+
restoreRequestProperties: RestoreRequestProperties,
|
|
806
|
+
options?: CloudHsmClustersRestoreOptionalParams,
|
|
807
|
+
): Promise<
|
|
808
|
+
SimplePollerLike<
|
|
809
|
+
OperationState<CloudHsmClustersRestoreResponse>,
|
|
810
|
+
CloudHsmClustersRestoreResponse
|
|
811
|
+
>
|
|
812
|
+
> {
|
|
813
|
+
const directSendOperation = async (
|
|
814
|
+
args: coreClient.OperationArguments,
|
|
815
|
+
spec: coreClient.OperationSpec,
|
|
816
|
+
): Promise<CloudHsmClustersRestoreResponse> => {
|
|
817
|
+
return this.client.sendOperationRequest(args, spec);
|
|
818
|
+
};
|
|
819
|
+
const sendOperationFn = async (
|
|
820
|
+
args: coreClient.OperationArguments,
|
|
821
|
+
spec: coreClient.OperationSpec,
|
|
822
|
+
) => {
|
|
823
|
+
let currentRawResponse: coreClient.FullOperationResponse | undefined =
|
|
824
|
+
undefined;
|
|
825
|
+
const providedCallback = args.options?.onResponse;
|
|
826
|
+
const callback: coreClient.RawResponseCallback = (
|
|
827
|
+
rawResponse: coreClient.FullOperationResponse,
|
|
828
|
+
flatResponse: unknown,
|
|
829
|
+
) => {
|
|
830
|
+
currentRawResponse = rawResponse;
|
|
831
|
+
providedCallback?.(rawResponse, flatResponse);
|
|
832
|
+
};
|
|
833
|
+
const updatedArgs = {
|
|
834
|
+
...args,
|
|
835
|
+
options: {
|
|
836
|
+
...args.options,
|
|
837
|
+
onResponse: callback,
|
|
838
|
+
},
|
|
839
|
+
};
|
|
840
|
+
const flatResponse = await directSendOperation(updatedArgs, spec);
|
|
841
|
+
return {
|
|
842
|
+
flatResponse,
|
|
843
|
+
rawResponse: {
|
|
844
|
+
statusCode: currentRawResponse!.status,
|
|
845
|
+
body: currentRawResponse!.parsedBody,
|
|
846
|
+
headers: currentRawResponse!.headers.toJSON(),
|
|
847
|
+
},
|
|
848
|
+
};
|
|
849
|
+
};
|
|
850
|
+
|
|
851
|
+
const lro = createLroSpec({
|
|
852
|
+
sendOperationFn,
|
|
853
|
+
args: {
|
|
854
|
+
resourceGroupName,
|
|
855
|
+
cloudHsmClusterName,
|
|
856
|
+
restoreRequestProperties,
|
|
857
|
+
options,
|
|
858
|
+
},
|
|
859
|
+
spec: restoreOperationSpec,
|
|
860
|
+
});
|
|
861
|
+
const poller = await createHttpPoller<
|
|
862
|
+
CloudHsmClustersRestoreResponse,
|
|
863
|
+
OperationState<CloudHsmClustersRestoreResponse>
|
|
864
|
+
>(lro, {
|
|
865
|
+
restoreFrom: options?.resumeFrom,
|
|
866
|
+
intervalInMs: options?.updateIntervalInMs,
|
|
867
|
+
resourceLocationConfig: "azure-async-operation",
|
|
868
|
+
});
|
|
869
|
+
await poller.poll();
|
|
870
|
+
return poller;
|
|
871
|
+
}
|
|
872
|
+
|
|
873
|
+
/**
|
|
874
|
+
* Restores all key materials of a specified Cloud HSM Cluster
|
|
875
|
+
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
876
|
+
* @param cloudHsmClusterName The name of the Cloud HSM Cluster within the specified resource group.
|
|
877
|
+
* Cloud HSM Cluster names must be between 3 and 23 characters in length.
|
|
878
|
+
* @param restoreRequestProperties Restore Operation Required properties
|
|
879
|
+
* @param options The options parameters.
|
|
880
|
+
*/
|
|
881
|
+
async beginRestoreAndWait(
|
|
882
|
+
resourceGroupName: string,
|
|
883
|
+
cloudHsmClusterName: string,
|
|
884
|
+
restoreRequestProperties: RestoreRequestProperties,
|
|
885
|
+
options?: CloudHsmClustersRestoreOptionalParams,
|
|
886
|
+
): Promise<CloudHsmClustersRestoreResponse> {
|
|
887
|
+
const poller = await this.beginRestore(
|
|
888
|
+
resourceGroupName,
|
|
889
|
+
cloudHsmClusterName,
|
|
890
|
+
restoreRequestProperties,
|
|
891
|
+
options,
|
|
892
|
+
);
|
|
893
|
+
return poller.pollUntilDone();
|
|
894
|
+
}
|
|
895
|
+
|
|
501
896
|
/**
|
|
502
897
|
* ListByResourceGroupNext
|
|
503
898
|
* @param resourceGroupName The name of the resource group. The name is case insensitive.
|
|
@@ -507,11 +902,11 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
507
902
|
private _listByResourceGroupNext(
|
|
508
903
|
resourceGroupName: string,
|
|
509
904
|
nextLink: string,
|
|
510
|
-
options?: CloudHsmClustersListByResourceGroupNextOptionalParams
|
|
905
|
+
options?: CloudHsmClustersListByResourceGroupNextOptionalParams,
|
|
511
906
|
): Promise<CloudHsmClustersListByResourceGroupNextResponse> {
|
|
512
907
|
return this.client.sendOperationRequest(
|
|
513
908
|
{ resourceGroupName, nextLink, options },
|
|
514
|
-
listByResourceGroupNextOperationSpec
|
|
909
|
+
listByResourceGroupNextOperationSpec,
|
|
515
910
|
);
|
|
516
911
|
}
|
|
517
912
|
|
|
@@ -522,11 +917,11 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
522
917
|
*/
|
|
523
918
|
private _listBySubscriptionNext(
|
|
524
919
|
nextLink: string,
|
|
525
|
-
options?: CloudHsmClustersListBySubscriptionNextOptionalParams
|
|
920
|
+
options?: CloudHsmClustersListBySubscriptionNextOptionalParams,
|
|
526
921
|
): Promise<CloudHsmClustersListBySubscriptionNextResponse> {
|
|
527
922
|
return this.client.sendOperationRequest(
|
|
528
923
|
{ nextLink, options },
|
|
529
|
-
listBySubscriptionNextOperationSpec
|
|
924
|
+
listBySubscriptionNextOperationSpec,
|
|
530
925
|
);
|
|
531
926
|
}
|
|
532
927
|
}
|
|
@@ -534,217 +929,355 @@ export class CloudHsmClustersImpl implements CloudHsmClusters {
|
|
|
534
929
|
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
|
|
535
930
|
|
|
536
931
|
const createOrUpdateOperationSpec: coreClient.OperationSpec = {
|
|
537
|
-
path:
|
|
538
|
-
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
932
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
539
933
|
httpMethod: "PUT",
|
|
540
934
|
responses: {
|
|
541
935
|
200: {
|
|
542
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
936
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
543
937
|
},
|
|
544
938
|
201: {
|
|
545
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
939
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
546
940
|
},
|
|
547
941
|
202: {
|
|
548
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
942
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
549
943
|
},
|
|
550
944
|
204: {
|
|
551
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
945
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
552
946
|
},
|
|
553
947
|
default: {
|
|
554
|
-
bodyMapper: Mappers.
|
|
555
|
-
}
|
|
948
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
949
|
+
},
|
|
556
950
|
},
|
|
557
951
|
requestBody: {
|
|
558
952
|
parameterPath: {
|
|
559
953
|
tags: ["options", "tags"],
|
|
560
954
|
location: ["location"],
|
|
561
|
-
sku: ["options", "sku"],
|
|
562
955
|
identity: ["options", "identity"],
|
|
563
|
-
|
|
956
|
+
sku: ["options", "sku"],
|
|
564
957
|
autoGeneratedDomainNameLabelScope: [
|
|
565
958
|
"options",
|
|
566
|
-
"autoGeneratedDomainNameLabelScope"
|
|
959
|
+
"autoGeneratedDomainNameLabelScope",
|
|
567
960
|
],
|
|
568
|
-
securityDomain: ["options", "securityDomain"],
|
|
569
|
-
hsms: ["options", "hsms"],
|
|
570
961
|
publicNetworkAccess: ["options", "publicNetworkAccess"],
|
|
571
|
-
privateEndpointConnections: ["options", "privateEndpointConnections"],
|
|
572
|
-
restoreProperties: ["options", "restoreProperties"],
|
|
573
|
-
backupProperties: ["options", "backupProperties"]
|
|
574
962
|
},
|
|
575
|
-
mapper: { ...Mappers.CloudHsmCluster, required: true }
|
|
963
|
+
mapper: { ...Mappers.CloudHsmCluster, required: true },
|
|
576
964
|
},
|
|
577
965
|
queryParameters: [Parameters.apiVersion],
|
|
578
966
|
urlParameters: [
|
|
579
967
|
Parameters.$host,
|
|
580
968
|
Parameters.subscriptionId,
|
|
581
969
|
Parameters.resourceGroupName,
|
|
582
|
-
Parameters.cloudHsmClusterName
|
|
970
|
+
Parameters.cloudHsmClusterName,
|
|
583
971
|
],
|
|
584
972
|
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
585
973
|
mediaType: "json",
|
|
586
|
-
serializer
|
|
974
|
+
serializer,
|
|
587
975
|
};
|
|
588
976
|
const updateOperationSpec: coreClient.OperationSpec = {
|
|
589
|
-
path:
|
|
590
|
-
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
977
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
591
978
|
httpMethod: "PATCH",
|
|
592
979
|
responses: {
|
|
593
980
|
200: {
|
|
594
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
981
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
595
982
|
},
|
|
596
983
|
201: {
|
|
597
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
984
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
598
985
|
},
|
|
599
986
|
202: {
|
|
600
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
987
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
601
988
|
},
|
|
602
989
|
204: {
|
|
603
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
990
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
604
991
|
},
|
|
605
992
|
default: {
|
|
606
|
-
bodyMapper: Mappers.
|
|
607
|
-
}
|
|
993
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
994
|
+
},
|
|
608
995
|
},
|
|
609
996
|
requestBody: {
|
|
610
997
|
parameterPath: {
|
|
611
998
|
tags: ["options", "tags"],
|
|
612
|
-
sku: ["options", "sku"],
|
|
613
999
|
identity: ["options", "identity"],
|
|
614
|
-
backupProperties: ["options", "backupProperties"]
|
|
615
1000
|
},
|
|
616
|
-
mapper: { ...Mappers.CloudHsmClusterPatchParameters, required: true }
|
|
1001
|
+
mapper: { ...Mappers.CloudHsmClusterPatchParameters, required: true },
|
|
617
1002
|
},
|
|
618
1003
|
queryParameters: [Parameters.apiVersion],
|
|
619
1004
|
urlParameters: [
|
|
620
1005
|
Parameters.$host,
|
|
621
1006
|
Parameters.subscriptionId,
|
|
622
1007
|
Parameters.resourceGroupName,
|
|
623
|
-
Parameters.cloudHsmClusterName
|
|
1008
|
+
Parameters.cloudHsmClusterName,
|
|
624
1009
|
],
|
|
625
1010
|
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
626
1011
|
mediaType: "json",
|
|
627
|
-
serializer
|
|
1012
|
+
serializer,
|
|
628
1013
|
};
|
|
629
1014
|
const getOperationSpec: coreClient.OperationSpec = {
|
|
630
|
-
path:
|
|
631
|
-
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
1015
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
632
1016
|
httpMethod: "GET",
|
|
633
1017
|
responses: {
|
|
634
1018
|
200: {
|
|
635
|
-
bodyMapper: Mappers.CloudHsmCluster
|
|
1019
|
+
bodyMapper: Mappers.CloudHsmCluster,
|
|
636
1020
|
},
|
|
637
1021
|
default: {
|
|
638
|
-
bodyMapper: Mappers.
|
|
639
|
-
}
|
|
1022
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1023
|
+
},
|
|
640
1024
|
},
|
|
641
1025
|
queryParameters: [Parameters.apiVersion],
|
|
642
1026
|
urlParameters: [
|
|
643
1027
|
Parameters.$host,
|
|
644
1028
|
Parameters.subscriptionId,
|
|
645
1029
|
Parameters.resourceGroupName,
|
|
646
|
-
Parameters.cloudHsmClusterName
|
|
1030
|
+
Parameters.cloudHsmClusterName,
|
|
647
1031
|
],
|
|
648
1032
|
headerParameters: [Parameters.accept],
|
|
649
|
-
serializer
|
|
1033
|
+
serializer,
|
|
650
1034
|
};
|
|
651
1035
|
const deleteOperationSpec: coreClient.OperationSpec = {
|
|
652
|
-
path:
|
|
653
|
-
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
1036
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}",
|
|
654
1037
|
httpMethod: "DELETE",
|
|
655
1038
|
responses: {
|
|
656
|
-
200: {
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
1039
|
+
200: {
|
|
1040
|
+
headersMapper: Mappers.CloudHsmClustersDeleteHeaders,
|
|
1041
|
+
},
|
|
1042
|
+
201: {
|
|
1043
|
+
headersMapper: Mappers.CloudHsmClustersDeleteHeaders,
|
|
1044
|
+
},
|
|
1045
|
+
202: {
|
|
1046
|
+
headersMapper: Mappers.CloudHsmClustersDeleteHeaders,
|
|
1047
|
+
},
|
|
1048
|
+
204: {
|
|
1049
|
+
headersMapper: Mappers.CloudHsmClustersDeleteHeaders,
|
|
1050
|
+
},
|
|
660
1051
|
default: {
|
|
661
|
-
bodyMapper: Mappers.
|
|
662
|
-
}
|
|
1052
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1053
|
+
},
|
|
663
1054
|
},
|
|
664
1055
|
queryParameters: [Parameters.apiVersion],
|
|
665
1056
|
urlParameters: [
|
|
666
1057
|
Parameters.$host,
|
|
667
1058
|
Parameters.subscriptionId,
|
|
668
1059
|
Parameters.resourceGroupName,
|
|
669
|
-
Parameters.cloudHsmClusterName
|
|
1060
|
+
Parameters.cloudHsmClusterName,
|
|
670
1061
|
],
|
|
671
1062
|
headerParameters: [Parameters.accept],
|
|
672
|
-
serializer
|
|
1063
|
+
serializer,
|
|
673
1064
|
};
|
|
674
1065
|
const listByResourceGroupOperationSpec: coreClient.OperationSpec = {
|
|
675
|
-
path:
|
|
676
|
-
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
|
|
1066
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
|
|
677
1067
|
httpMethod: "GET",
|
|
678
1068
|
responses: {
|
|
679
1069
|
200: {
|
|
680
|
-
bodyMapper: Mappers.CloudHsmClusterListResult
|
|
1070
|
+
bodyMapper: Mappers.CloudHsmClusterListResult,
|
|
681
1071
|
},
|
|
682
1072
|
default: {
|
|
683
|
-
bodyMapper: Mappers.
|
|
684
|
-
}
|
|
1073
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1074
|
+
},
|
|
685
1075
|
},
|
|
686
1076
|
queryParameters: [Parameters.apiVersion, Parameters.skiptoken],
|
|
687
1077
|
urlParameters: [
|
|
688
1078
|
Parameters.$host,
|
|
689
1079
|
Parameters.subscriptionId,
|
|
690
|
-
Parameters.resourceGroupName
|
|
1080
|
+
Parameters.resourceGroupName,
|
|
691
1081
|
],
|
|
692
1082
|
headerParameters: [Parameters.accept],
|
|
693
|
-
serializer
|
|
1083
|
+
serializer,
|
|
694
1084
|
};
|
|
695
1085
|
const listBySubscriptionOperationSpec: coreClient.OperationSpec = {
|
|
696
|
-
path:
|
|
697
|
-
"/subscriptions/{subscriptionId}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
|
|
1086
|
+
path: "/subscriptions/{subscriptionId}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters",
|
|
698
1087
|
httpMethod: "GET",
|
|
699
1088
|
responses: {
|
|
700
1089
|
200: {
|
|
701
|
-
bodyMapper: Mappers.CloudHsmClusterListResult
|
|
1090
|
+
bodyMapper: Mappers.CloudHsmClusterListResult,
|
|
702
1091
|
},
|
|
703
1092
|
default: {
|
|
704
|
-
bodyMapper: Mappers.
|
|
705
|
-
}
|
|
1093
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1094
|
+
},
|
|
706
1095
|
},
|
|
707
1096
|
queryParameters: [Parameters.apiVersion, Parameters.skiptoken],
|
|
708
1097
|
urlParameters: [Parameters.$host, Parameters.subscriptionId],
|
|
709
1098
|
headerParameters: [Parameters.accept],
|
|
710
|
-
serializer
|
|
1099
|
+
serializer,
|
|
1100
|
+
};
|
|
1101
|
+
const validateBackupPropertiesOperationSpec: coreClient.OperationSpec = {
|
|
1102
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/validateBackupProperties",
|
|
1103
|
+
httpMethod: "POST",
|
|
1104
|
+
responses: {
|
|
1105
|
+
200: {
|
|
1106
|
+
bodyMapper: Mappers.BackupResult,
|
|
1107
|
+
headersMapper: Mappers.CloudHsmClustersValidateBackupPropertiesHeaders,
|
|
1108
|
+
},
|
|
1109
|
+
201: {
|
|
1110
|
+
bodyMapper: Mappers.BackupResult,
|
|
1111
|
+
headersMapper: Mappers.CloudHsmClustersValidateBackupPropertiesHeaders,
|
|
1112
|
+
},
|
|
1113
|
+
202: {
|
|
1114
|
+
bodyMapper: Mappers.BackupResult,
|
|
1115
|
+
headersMapper: Mappers.CloudHsmClustersValidateBackupPropertiesHeaders,
|
|
1116
|
+
},
|
|
1117
|
+
204: {
|
|
1118
|
+
bodyMapper: Mappers.BackupResult,
|
|
1119
|
+
headersMapper: Mappers.CloudHsmClustersValidateBackupPropertiesHeaders,
|
|
1120
|
+
},
|
|
1121
|
+
default: {
|
|
1122
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1123
|
+
},
|
|
1124
|
+
},
|
|
1125
|
+
requestBody: Parameters.backupRequestProperties,
|
|
1126
|
+
queryParameters: [Parameters.apiVersion],
|
|
1127
|
+
urlParameters: [
|
|
1128
|
+
Parameters.$host,
|
|
1129
|
+
Parameters.subscriptionId,
|
|
1130
|
+
Parameters.resourceGroupName,
|
|
1131
|
+
Parameters.cloudHsmClusterName,
|
|
1132
|
+
],
|
|
1133
|
+
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
1134
|
+
mediaType: "json",
|
|
1135
|
+
serializer,
|
|
1136
|
+
};
|
|
1137
|
+
const backupOperationSpec: coreClient.OperationSpec = {
|
|
1138
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/backup",
|
|
1139
|
+
httpMethod: "POST",
|
|
1140
|
+
responses: {
|
|
1141
|
+
200: {
|
|
1142
|
+
bodyMapper: Mappers.BackupResult,
|
|
1143
|
+
headersMapper: Mappers.CloudHsmClustersBackupHeaders,
|
|
1144
|
+
},
|
|
1145
|
+
201: {
|
|
1146
|
+
bodyMapper: Mappers.BackupResult,
|
|
1147
|
+
headersMapper: Mappers.CloudHsmClustersBackupHeaders,
|
|
1148
|
+
},
|
|
1149
|
+
202: {
|
|
1150
|
+
bodyMapper: Mappers.BackupResult,
|
|
1151
|
+
headersMapper: Mappers.CloudHsmClustersBackupHeaders,
|
|
1152
|
+
},
|
|
1153
|
+
204: {
|
|
1154
|
+
bodyMapper: Mappers.BackupResult,
|
|
1155
|
+
headersMapper: Mappers.CloudHsmClustersBackupHeaders,
|
|
1156
|
+
},
|
|
1157
|
+
default: {
|
|
1158
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1159
|
+
},
|
|
1160
|
+
},
|
|
1161
|
+
requestBody: Parameters.backupRequestProperties,
|
|
1162
|
+
queryParameters: [Parameters.apiVersion],
|
|
1163
|
+
urlParameters: [
|
|
1164
|
+
Parameters.$host,
|
|
1165
|
+
Parameters.subscriptionId,
|
|
1166
|
+
Parameters.resourceGroupName,
|
|
1167
|
+
Parameters.cloudHsmClusterName,
|
|
1168
|
+
],
|
|
1169
|
+
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
1170
|
+
mediaType: "json",
|
|
1171
|
+
serializer,
|
|
1172
|
+
};
|
|
1173
|
+
const validateRestorePropertiesOperationSpec: coreClient.OperationSpec = {
|
|
1174
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/validateRestoreProperties",
|
|
1175
|
+
httpMethod: "POST",
|
|
1176
|
+
responses: {
|
|
1177
|
+
200: {
|
|
1178
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1179
|
+
headersMapper: Mappers.CloudHsmClustersValidateRestorePropertiesHeaders,
|
|
1180
|
+
},
|
|
1181
|
+
201: {
|
|
1182
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1183
|
+
headersMapper: Mappers.CloudHsmClustersValidateRestorePropertiesHeaders,
|
|
1184
|
+
},
|
|
1185
|
+
202: {
|
|
1186
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1187
|
+
headersMapper: Mappers.CloudHsmClustersValidateRestorePropertiesHeaders,
|
|
1188
|
+
},
|
|
1189
|
+
204: {
|
|
1190
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1191
|
+
headersMapper: Mappers.CloudHsmClustersValidateRestorePropertiesHeaders,
|
|
1192
|
+
},
|
|
1193
|
+
default: {
|
|
1194
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1195
|
+
},
|
|
1196
|
+
},
|
|
1197
|
+
requestBody: Parameters.restoreRequestProperties,
|
|
1198
|
+
queryParameters: [Parameters.apiVersion],
|
|
1199
|
+
urlParameters: [
|
|
1200
|
+
Parameters.$host,
|
|
1201
|
+
Parameters.subscriptionId,
|
|
1202
|
+
Parameters.resourceGroupName,
|
|
1203
|
+
Parameters.cloudHsmClusterName,
|
|
1204
|
+
],
|
|
1205
|
+
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
1206
|
+
mediaType: "json",
|
|
1207
|
+
serializer,
|
|
1208
|
+
};
|
|
1209
|
+
const restoreOperationSpec: coreClient.OperationSpec = {
|
|
1210
|
+
path: "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HardwareSecurityModules/cloudHsmClusters/{cloudHsmClusterName}/restore",
|
|
1211
|
+
httpMethod: "POST",
|
|
1212
|
+
responses: {
|
|
1213
|
+
200: {
|
|
1214
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1215
|
+
headersMapper: Mappers.CloudHsmClustersRestoreHeaders,
|
|
1216
|
+
},
|
|
1217
|
+
201: {
|
|
1218
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1219
|
+
headersMapper: Mappers.CloudHsmClustersRestoreHeaders,
|
|
1220
|
+
},
|
|
1221
|
+
202: {
|
|
1222
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1223
|
+
headersMapper: Mappers.CloudHsmClustersRestoreHeaders,
|
|
1224
|
+
},
|
|
1225
|
+
204: {
|
|
1226
|
+
bodyMapper: Mappers.RestoreResult,
|
|
1227
|
+
headersMapper: Mappers.CloudHsmClustersRestoreHeaders,
|
|
1228
|
+
},
|
|
1229
|
+
default: {
|
|
1230
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1231
|
+
},
|
|
1232
|
+
},
|
|
1233
|
+
requestBody: Parameters.restoreRequestProperties1,
|
|
1234
|
+
queryParameters: [Parameters.apiVersion],
|
|
1235
|
+
urlParameters: [
|
|
1236
|
+
Parameters.$host,
|
|
1237
|
+
Parameters.subscriptionId,
|
|
1238
|
+
Parameters.resourceGroupName,
|
|
1239
|
+
Parameters.cloudHsmClusterName,
|
|
1240
|
+
],
|
|
1241
|
+
headerParameters: [Parameters.contentType, Parameters.accept],
|
|
1242
|
+
mediaType: "json",
|
|
1243
|
+
serializer,
|
|
711
1244
|
};
|
|
712
1245
|
const listByResourceGroupNextOperationSpec: coreClient.OperationSpec = {
|
|
713
1246
|
path: "{nextLink}",
|
|
714
1247
|
httpMethod: "GET",
|
|
715
1248
|
responses: {
|
|
716
1249
|
200: {
|
|
717
|
-
bodyMapper: Mappers.CloudHsmClusterListResult
|
|
1250
|
+
bodyMapper: Mappers.CloudHsmClusterListResult,
|
|
718
1251
|
},
|
|
719
1252
|
default: {
|
|
720
|
-
bodyMapper: Mappers.
|
|
721
|
-
}
|
|
1253
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1254
|
+
},
|
|
722
1255
|
},
|
|
723
1256
|
urlParameters: [
|
|
724
1257
|
Parameters.$host,
|
|
725
1258
|
Parameters.subscriptionId,
|
|
726
1259
|
Parameters.resourceGroupName,
|
|
727
|
-
Parameters.nextLink
|
|
1260
|
+
Parameters.nextLink,
|
|
728
1261
|
],
|
|
729
1262
|
headerParameters: [Parameters.accept],
|
|
730
|
-
serializer
|
|
1263
|
+
serializer,
|
|
731
1264
|
};
|
|
732
1265
|
const listBySubscriptionNextOperationSpec: coreClient.OperationSpec = {
|
|
733
1266
|
path: "{nextLink}",
|
|
734
1267
|
httpMethod: "GET",
|
|
735
1268
|
responses: {
|
|
736
1269
|
200: {
|
|
737
|
-
bodyMapper: Mappers.CloudHsmClusterListResult
|
|
1270
|
+
bodyMapper: Mappers.CloudHsmClusterListResult,
|
|
738
1271
|
},
|
|
739
1272
|
default: {
|
|
740
|
-
bodyMapper: Mappers.
|
|
741
|
-
}
|
|
1273
|
+
bodyMapper: Mappers.ErrorResponse,
|
|
1274
|
+
},
|
|
742
1275
|
},
|
|
743
1276
|
urlParameters: [
|
|
744
1277
|
Parameters.$host,
|
|
745
1278
|
Parameters.subscriptionId,
|
|
746
|
-
Parameters.nextLink
|
|
1279
|
+
Parameters.nextLink,
|
|
747
1280
|
],
|
|
748
1281
|
headerParameters: [Parameters.accept],
|
|
749
|
-
serializer
|
|
1282
|
+
serializer,
|
|
750
1283
|
};
|