Skip to content

Commit c1349f2

Browse files
author
awstools
committed
feat(client-drs): Changed existing APIs and added new APIs to support using an account-level launch configuration template with AWS Elastic Disaster Recovery.
1 parent 3a4d2cb commit c1349f2

13 files changed

+2185
-115
lines changed

clients/client-drs/README.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,14 @@ CreateExtendedSourceServer
213213

214214
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/createextendedsourceservercommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/createextendedsourceservercommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/createextendedsourceservercommandoutput.html)
215215

216+
</details>
217+
<details>
218+
<summary>
219+
CreateLaunchConfigurationTemplate
220+
</summary>
221+
222+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/createlaunchconfigurationtemplatecommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/createlaunchconfigurationtemplatecommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/createlaunchconfigurationtemplatecommandoutput.html)
223+
216224
</details>
217225
<details>
218226
<summary>
@@ -229,6 +237,14 @@ DeleteJob
229237

230238
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/deletejobcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/deletejobcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/deletejobcommandoutput.html)
231239

240+
</details>
241+
<details>
242+
<summary>
243+
DeleteLaunchConfigurationTemplate
244+
</summary>
245+
246+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/deletelaunchconfigurationtemplatecommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/deletelaunchconfigurationtemplatecommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/deletelaunchconfigurationtemplatecommandoutput.html)
247+
232248
</details>
233249
<details>
234250
<summary>
@@ -269,6 +285,14 @@ DescribeJobs
269285

270286
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/describejobscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/describejobscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/describejobscommandoutput.html)
271287

288+
</details>
289+
<details>
290+
<summary>
291+
DescribeLaunchConfigurationTemplates
292+
</summary>
293+
294+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/describelaunchconfigurationtemplatescommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/describelaunchconfigurationtemplatescommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/describelaunchconfigurationtemplatescommandoutput.html)
295+
272296
</details>
273297
<details>
274298
<summary>
@@ -469,6 +493,14 @@ UpdateLaunchConfiguration
469493

470494
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/updatelaunchconfigurationcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/updatelaunchconfigurationcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/updatelaunchconfigurationcommandoutput.html)
471495

496+
</details>
497+
<details>
498+
<summary>
499+
UpdateLaunchConfigurationTemplate
500+
</summary>
501+
502+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/classes/updatelaunchconfigurationtemplatecommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/updatelaunchconfigurationtemplatecommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-drs/interfaces/updatelaunchconfigurationtemplatecommandoutput.html)
503+
472504
</details>
473505
<details>
474506
<summary>

clients/client-drs/src/Drs.ts

Lines changed: 152 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,22 @@ import {
66
CreateExtendedSourceServerCommandInput,
77
CreateExtendedSourceServerCommandOutput,
88
} from "./commands/CreateExtendedSourceServerCommand";
9+
import {
10+
CreateLaunchConfigurationTemplateCommand,
11+
CreateLaunchConfigurationTemplateCommandInput,
12+
CreateLaunchConfigurationTemplateCommandOutput,
13+
} from "./commands/CreateLaunchConfigurationTemplateCommand";
914
import {
1015
CreateReplicationConfigurationTemplateCommand,
1116
CreateReplicationConfigurationTemplateCommandInput,
1217
CreateReplicationConfigurationTemplateCommandOutput,
1318
} from "./commands/CreateReplicationConfigurationTemplateCommand";
1419
import { DeleteJobCommand, DeleteJobCommandInput, DeleteJobCommandOutput } from "./commands/DeleteJobCommand";
20+
import {
21+
DeleteLaunchConfigurationTemplateCommand,
22+
DeleteLaunchConfigurationTemplateCommandInput,
23+
DeleteLaunchConfigurationTemplateCommandOutput,
24+
} from "./commands/DeleteLaunchConfigurationTemplateCommand";
1525
import {
1626
DeleteRecoveryInstanceCommand,
1727
DeleteRecoveryInstanceCommandInput,
@@ -37,6 +47,11 @@ import {
3747
DescribeJobsCommandInput,
3848
DescribeJobsCommandOutput,
3949
} from "./commands/DescribeJobsCommand";
50+
import {
51+
DescribeLaunchConfigurationTemplatesCommand,
52+
DescribeLaunchConfigurationTemplatesCommandInput,
53+
DescribeLaunchConfigurationTemplatesCommandOutput,
54+
} from "./commands/DescribeLaunchConfigurationTemplatesCommand";
4055
import {
4156
DescribeRecoveryInstancesCommand,
4257
DescribeRecoveryInstancesCommandInput,
@@ -158,6 +173,11 @@ import {
158173
UpdateLaunchConfigurationCommandInput,
159174
UpdateLaunchConfigurationCommandOutput,
160175
} from "./commands/UpdateLaunchConfigurationCommand";
176+
import {
177+
UpdateLaunchConfigurationTemplateCommand,
178+
UpdateLaunchConfigurationTemplateCommandInput,
179+
UpdateLaunchConfigurationTemplateCommandOutput,
180+
} from "./commands/UpdateLaunchConfigurationTemplateCommand";
161181
import {
162182
UpdateReplicationConfigurationCommand,
163183
UpdateReplicationConfigurationCommandInput,
@@ -208,6 +228,39 @@ export class Drs extends DrsClient {
208228
}
209229
}
210230

231+
/**
232+
* @public
233+
* <p>Creates a new Launch Configuration Template.</p>
234+
*/
235+
public createLaunchConfigurationTemplate(
236+
args: CreateLaunchConfigurationTemplateCommandInput,
237+
options?: __HttpHandlerOptions
238+
): Promise<CreateLaunchConfigurationTemplateCommandOutput>;
239+
public createLaunchConfigurationTemplate(
240+
args: CreateLaunchConfigurationTemplateCommandInput,
241+
cb: (err: any, data?: CreateLaunchConfigurationTemplateCommandOutput) => void
242+
): void;
243+
public createLaunchConfigurationTemplate(
244+
args: CreateLaunchConfigurationTemplateCommandInput,
245+
options: __HttpHandlerOptions,
246+
cb: (err: any, data?: CreateLaunchConfigurationTemplateCommandOutput) => void
247+
): void;
248+
public createLaunchConfigurationTemplate(
249+
args: CreateLaunchConfigurationTemplateCommandInput,
250+
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: CreateLaunchConfigurationTemplateCommandOutput) => void),
251+
cb?: (err: any, data?: CreateLaunchConfigurationTemplateCommandOutput) => void
252+
): Promise<CreateLaunchConfigurationTemplateCommandOutput> | void {
253+
const command = new CreateLaunchConfigurationTemplateCommand(args);
254+
if (typeof optionsOrCb === "function") {
255+
this.send(command, optionsOrCb);
256+
} else if (typeof cb === "function") {
257+
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
258+
this.send(command, optionsOrCb || {}, cb);
259+
} else {
260+
return this.send(command, optionsOrCb);
261+
}
262+
}
263+
211264
/**
212265
* @public
213266
* <p>Creates a new ReplicationConfigurationTemplate.</p>
@@ -270,6 +323,39 @@ export class Drs extends DrsClient {
270323
}
271324
}
272325

326+
/**
327+
* @public
328+
* <p>Deletes a single Launch Configuration Template by ID.</p>
329+
*/
330+
public deleteLaunchConfigurationTemplate(
331+
args: DeleteLaunchConfigurationTemplateCommandInput,
332+
options?: __HttpHandlerOptions
333+
): Promise<DeleteLaunchConfigurationTemplateCommandOutput>;
334+
public deleteLaunchConfigurationTemplate(
335+
args: DeleteLaunchConfigurationTemplateCommandInput,
336+
cb: (err: any, data?: DeleteLaunchConfigurationTemplateCommandOutput) => void
337+
): void;
338+
public deleteLaunchConfigurationTemplate(
339+
args: DeleteLaunchConfigurationTemplateCommandInput,
340+
options: __HttpHandlerOptions,
341+
cb: (err: any, data?: DeleteLaunchConfigurationTemplateCommandOutput) => void
342+
): void;
343+
public deleteLaunchConfigurationTemplate(
344+
args: DeleteLaunchConfigurationTemplateCommandInput,
345+
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: DeleteLaunchConfigurationTemplateCommandOutput) => void),
346+
cb?: (err: any, data?: DeleteLaunchConfigurationTemplateCommandOutput) => void
347+
): Promise<DeleteLaunchConfigurationTemplateCommandOutput> | void {
348+
const command = new DeleteLaunchConfigurationTemplateCommand(args);
349+
if (typeof optionsOrCb === "function") {
350+
this.send(command, optionsOrCb);
351+
} else if (typeof cb === "function") {
352+
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
353+
this.send(command, optionsOrCb || {}, cb);
354+
} else {
355+
return this.send(command, optionsOrCb);
356+
}
357+
}
358+
273359
/**
274360
* @public
275361
* <p>Deletes a single Recovery Instance by ID. This deletes the Recovery Instance resource from Elastic Disaster Recovery. The Recovery Instance must be disconnected first in order to delete it.</p>
@@ -434,6 +520,39 @@ export class Drs extends DrsClient {
434520
}
435521
}
436522

523+
/**
524+
* @public
525+
* <p>Lists all Launch Configuration Templates, filtered by Launch Configuration Template IDs</p>
526+
*/
527+
public describeLaunchConfigurationTemplates(
528+
args: DescribeLaunchConfigurationTemplatesCommandInput,
529+
options?: __HttpHandlerOptions
530+
): Promise<DescribeLaunchConfigurationTemplatesCommandOutput>;
531+
public describeLaunchConfigurationTemplates(
532+
args: DescribeLaunchConfigurationTemplatesCommandInput,
533+
cb: (err: any, data?: DescribeLaunchConfigurationTemplatesCommandOutput) => void
534+
): void;
535+
public describeLaunchConfigurationTemplates(
536+
args: DescribeLaunchConfigurationTemplatesCommandInput,
537+
options: __HttpHandlerOptions,
538+
cb: (err: any, data?: DescribeLaunchConfigurationTemplatesCommandOutput) => void
539+
): void;
540+
public describeLaunchConfigurationTemplates(
541+
args: DescribeLaunchConfigurationTemplatesCommandInput,
542+
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: DescribeLaunchConfigurationTemplatesCommandOutput) => void),
543+
cb?: (err: any, data?: DescribeLaunchConfigurationTemplatesCommandOutput) => void
544+
): Promise<DescribeLaunchConfigurationTemplatesCommandOutput> | void {
545+
const command = new DescribeLaunchConfigurationTemplatesCommand(args);
546+
if (typeof optionsOrCb === "function") {
547+
this.send(command, optionsOrCb);
548+
} else if (typeof cb === "function") {
549+
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
550+
this.send(command, optionsOrCb || {}, cb);
551+
} else {
552+
return this.send(command, optionsOrCb);
553+
}
554+
}
555+
437556
/**
438557
* @public
439558
* <p>Lists all Recovery Instances or multiple Recovery Instances by ID.</p>
@@ -1264,6 +1383,39 @@ export class Drs extends DrsClient {
12641383
}
12651384
}
12661385

1386+
/**
1387+
* @public
1388+
* <p>Updates an existing Launch Configuration Template by ID.</p>
1389+
*/
1390+
public updateLaunchConfigurationTemplate(
1391+
args: UpdateLaunchConfigurationTemplateCommandInput,
1392+
options?: __HttpHandlerOptions
1393+
): Promise<UpdateLaunchConfigurationTemplateCommandOutput>;
1394+
public updateLaunchConfigurationTemplate(
1395+
args: UpdateLaunchConfigurationTemplateCommandInput,
1396+
cb: (err: any, data?: UpdateLaunchConfigurationTemplateCommandOutput) => void
1397+
): void;
1398+
public updateLaunchConfigurationTemplate(
1399+
args: UpdateLaunchConfigurationTemplateCommandInput,
1400+
options: __HttpHandlerOptions,
1401+
cb: (err: any, data?: UpdateLaunchConfigurationTemplateCommandOutput) => void
1402+
): void;
1403+
public updateLaunchConfigurationTemplate(
1404+
args: UpdateLaunchConfigurationTemplateCommandInput,
1405+
optionsOrCb?: __HttpHandlerOptions | ((err: any, data?: UpdateLaunchConfigurationTemplateCommandOutput) => void),
1406+
cb?: (err: any, data?: UpdateLaunchConfigurationTemplateCommandOutput) => void
1407+
): Promise<UpdateLaunchConfigurationTemplateCommandOutput> | void {
1408+
const command = new UpdateLaunchConfigurationTemplateCommand(args);
1409+
if (typeof optionsOrCb === "function") {
1410+
this.send(command, optionsOrCb);
1411+
} else if (typeof cb === "function") {
1412+
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
1413+
this.send(command, optionsOrCb || {}, cb);
1414+
} else {
1415+
return this.send(command, optionsOrCb);
1416+
}
1417+
}
1418+
12671419
/**
12681420
* @public
12691421
* <p>Allows you to update a ReplicationConfiguration by Source Server ID.</p>

clients/client-drs/src/DrsClient.ts

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,19 @@ import {
5353
CreateExtendedSourceServerCommandInput,
5454
CreateExtendedSourceServerCommandOutput,
5555
} from "./commands/CreateExtendedSourceServerCommand";
56+
import {
57+
CreateLaunchConfigurationTemplateCommandInput,
58+
CreateLaunchConfigurationTemplateCommandOutput,
59+
} from "./commands/CreateLaunchConfigurationTemplateCommand";
5660
import {
5761
CreateReplicationConfigurationTemplateCommandInput,
5862
CreateReplicationConfigurationTemplateCommandOutput,
5963
} from "./commands/CreateReplicationConfigurationTemplateCommand";
6064
import { DeleteJobCommandInput, DeleteJobCommandOutput } from "./commands/DeleteJobCommand";
65+
import {
66+
DeleteLaunchConfigurationTemplateCommandInput,
67+
DeleteLaunchConfigurationTemplateCommandOutput,
68+
} from "./commands/DeleteLaunchConfigurationTemplateCommand";
6169
import {
6270
DeleteRecoveryInstanceCommandInput,
6371
DeleteRecoveryInstanceCommandOutput,
@@ -72,6 +80,10 @@ import {
7280
DescribeJobLogItemsCommandOutput,
7381
} from "./commands/DescribeJobLogItemsCommand";
7482
import { DescribeJobsCommandInput, DescribeJobsCommandOutput } from "./commands/DescribeJobsCommand";
83+
import {
84+
DescribeLaunchConfigurationTemplatesCommandInput,
85+
DescribeLaunchConfigurationTemplatesCommandOutput,
86+
} from "./commands/DescribeLaunchConfigurationTemplatesCommand";
7587
import {
7688
DescribeRecoveryInstancesCommandInput,
7789
DescribeRecoveryInstancesCommandOutput,
@@ -148,6 +160,10 @@ import {
148160
UpdateLaunchConfigurationCommandInput,
149161
UpdateLaunchConfigurationCommandOutput,
150162
} from "./commands/UpdateLaunchConfigurationCommand";
163+
import {
164+
UpdateLaunchConfigurationTemplateCommandInput,
165+
UpdateLaunchConfigurationTemplateCommandOutput,
166+
} from "./commands/UpdateLaunchConfigurationTemplateCommand";
151167
import {
152168
UpdateReplicationConfigurationCommandInput,
153169
UpdateReplicationConfigurationCommandOutput,
@@ -169,13 +185,16 @@ import { getRuntimeConfig as __getRuntimeConfig } from "./runtimeConfig";
169185
*/
170186
export type ServiceInputTypes =
171187
| CreateExtendedSourceServerCommandInput
188+
| CreateLaunchConfigurationTemplateCommandInput
172189
| CreateReplicationConfigurationTemplateCommandInput
173190
| DeleteJobCommandInput
191+
| DeleteLaunchConfigurationTemplateCommandInput
174192
| DeleteRecoveryInstanceCommandInput
175193
| DeleteReplicationConfigurationTemplateCommandInput
176194
| DeleteSourceServerCommandInput
177195
| DescribeJobLogItemsCommandInput
178196
| DescribeJobsCommandInput
197+
| DescribeLaunchConfigurationTemplatesCommandInput
179198
| DescribeRecoveryInstancesCommandInput
180199
| DescribeRecoverySnapshotsCommandInput
181200
| DescribeReplicationConfigurationTemplatesCommandInput
@@ -201,6 +220,7 @@ export type ServiceInputTypes =
201220
| UntagResourceCommandInput
202221
| UpdateFailbackReplicationConfigurationCommandInput
203222
| UpdateLaunchConfigurationCommandInput
223+
| UpdateLaunchConfigurationTemplateCommandInput
204224
| UpdateReplicationConfigurationCommandInput
205225
| UpdateReplicationConfigurationTemplateCommandInput;
206226

@@ -209,13 +229,16 @@ export type ServiceInputTypes =
209229
*/
210230
export type ServiceOutputTypes =
211231
| CreateExtendedSourceServerCommandOutput
232+
| CreateLaunchConfigurationTemplateCommandOutput
212233
| CreateReplicationConfigurationTemplateCommandOutput
213234
| DeleteJobCommandOutput
235+
| DeleteLaunchConfigurationTemplateCommandOutput
214236
| DeleteRecoveryInstanceCommandOutput
215237
| DeleteReplicationConfigurationTemplateCommandOutput
216238
| DeleteSourceServerCommandOutput
217239
| DescribeJobLogItemsCommandOutput
218240
| DescribeJobsCommandOutput
241+
| DescribeLaunchConfigurationTemplatesCommandOutput
219242
| DescribeRecoveryInstancesCommandOutput
220243
| DescribeRecoverySnapshotsCommandOutput
221244
| DescribeReplicationConfigurationTemplatesCommandOutput
@@ -241,6 +264,7 @@ export type ServiceOutputTypes =
241264
| UntagResourceCommandOutput
242265
| UpdateFailbackReplicationConfigurationCommandOutput
243266
| UpdateLaunchConfigurationCommandOutput
267+
| UpdateLaunchConfigurationTemplateCommandOutput
244268
| UpdateReplicationConfigurationCommandOutput
245269
| UpdateReplicationConfigurationTemplateCommandOutput;
246270

0 commit comments

Comments
 (0)