Skip to content

Commit 5e93ef1

Browse files
author
awstools
committed
feat(client-workspaces): New APIs introduced to import WorkSpaces BYOL image using a new process that leveraged EC2 Image Builder. WorkSpaces tests and fixes your image's compatibility issues and supports customized VM images.
1 parent ae2b9bc commit 5e93ef1

17 files changed

+1406
-200
lines changed

clients/client-workspaces/README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,14 @@ DescribeConnectionAliasPermissions
515515

516516
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/workspaces/command/DescribeConnectionAliasPermissionsCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/DescribeConnectionAliasPermissionsCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/DescribeConnectionAliasPermissionsCommandOutput/)
517517

518+
</details>
519+
<details>
520+
<summary>
521+
DescribeCustomWorkspaceImageImport
522+
</summary>
523+
524+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/workspaces/command/DescribeCustomWorkspaceImageImportCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/DescribeCustomWorkspaceImageImportCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/DescribeCustomWorkspaceImageImportCommandOutput/)
525+
518526
</details>
519527
<details>
520528
<summary>
@@ -659,6 +667,14 @@ ImportClientBranding
659667

660668
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/workspaces/command/ImportClientBrandingCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/ImportClientBrandingCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/ImportClientBrandingCommandOutput/)
661669

670+
</details>
671+
<details>
672+
<summary>
673+
ImportCustomWorkspaceImage
674+
</summary>
675+
676+
[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/workspaces/command/ImportCustomWorkspaceImageCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/ImportCustomWorkspaceImageCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-workspaces/Interface/ImportCustomWorkspaceImageCommandOutput/)
677+
662678
</details>
663679
<details>
664680
<summary>

clients/client-workspaces/src/WorkSpaces.ts

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,11 @@ import {
179179
DescribeConnectionAliasPermissionsCommandInput,
180180
DescribeConnectionAliasPermissionsCommandOutput,
181181
} from "./commands/DescribeConnectionAliasPermissionsCommand";
182+
import {
183+
DescribeCustomWorkspaceImageImportCommand,
184+
DescribeCustomWorkspaceImageImportCommandInput,
185+
DescribeCustomWorkspaceImageImportCommandOutput,
186+
} from "./commands/DescribeCustomWorkspaceImageImportCommand";
182187
import {
183188
DescribeImageAssociationsCommand,
184189
DescribeImageAssociationsCommandInput,
@@ -269,6 +274,11 @@ import {
269274
ImportClientBrandingCommandInput,
270275
ImportClientBrandingCommandOutput,
271276
} from "./commands/ImportClientBrandingCommand";
277+
import {
278+
ImportCustomWorkspaceImageCommand,
279+
ImportCustomWorkspaceImageCommandInput,
280+
ImportCustomWorkspaceImageCommandOutput,
281+
} from "./commands/ImportCustomWorkspaceImageCommand";
272282
import {
273283
ImportWorkspaceImageCommand,
274284
ImportWorkspaceImageCommandInput,
@@ -479,6 +489,7 @@ const commands = {
479489
DescribeConnectClientAddInsCommand,
480490
DescribeConnectionAliasesCommand,
481491
DescribeConnectionAliasPermissionsCommand,
492+
DescribeCustomWorkspaceImageImportCommand,
482493
DescribeImageAssociationsCommand,
483494
DescribeIpGroupsCommand,
484495
DescribeTagsCommand,
@@ -497,6 +508,7 @@ const commands = {
497508
DisassociateWorkspaceApplicationCommand,
498509
GetAccountLinkCommand,
499510
ImportClientBrandingCommand,
511+
ImportCustomWorkspaceImageCommand,
500512
ImportWorkspaceImageCommand,
501513
ListAccountLinksCommand,
502514
ListAvailableManagementCidrRangesCommand,
@@ -1141,6 +1153,23 @@ export interface WorkSpaces {
11411153
cb: (err: any, data?: DescribeConnectionAliasPermissionsCommandOutput) => void
11421154
): void;
11431155

1156+
/**
1157+
* @see {@link DescribeCustomWorkspaceImageImportCommand}
1158+
*/
1159+
describeCustomWorkspaceImageImport(
1160+
args: DescribeCustomWorkspaceImageImportCommandInput,
1161+
options?: __HttpHandlerOptions
1162+
): Promise<DescribeCustomWorkspaceImageImportCommandOutput>;
1163+
describeCustomWorkspaceImageImport(
1164+
args: DescribeCustomWorkspaceImageImportCommandInput,
1165+
cb: (err: any, data?: DescribeCustomWorkspaceImageImportCommandOutput) => void
1166+
): void;
1167+
describeCustomWorkspaceImageImport(
1168+
args: DescribeCustomWorkspaceImageImportCommandInput,
1169+
options: __HttpHandlerOptions,
1170+
cb: (err: any, data?: DescribeCustomWorkspaceImageImportCommandOutput) => void
1171+
): void;
1172+
11441173
/**
11451174
* @see {@link DescribeImageAssociationsCommand}
11461175
*/
@@ -1446,6 +1475,23 @@ export interface WorkSpaces {
14461475
cb: (err: any, data?: ImportClientBrandingCommandOutput) => void
14471476
): void;
14481477

1478+
/**
1479+
* @see {@link ImportCustomWorkspaceImageCommand}
1480+
*/
1481+
importCustomWorkspaceImage(
1482+
args: ImportCustomWorkspaceImageCommandInput,
1483+
options?: __HttpHandlerOptions
1484+
): Promise<ImportCustomWorkspaceImageCommandOutput>;
1485+
importCustomWorkspaceImage(
1486+
args: ImportCustomWorkspaceImageCommandInput,
1487+
cb: (err: any, data?: ImportCustomWorkspaceImageCommandOutput) => void
1488+
): void;
1489+
importCustomWorkspaceImage(
1490+
args: ImportCustomWorkspaceImageCommandInput,
1491+
options: __HttpHandlerOptions,
1492+
cb: (err: any, data?: ImportCustomWorkspaceImageCommandOutput) => void
1493+
): void;
1494+
14491495
/**
14501496
* @see {@link ImportWorkspaceImageCommand}
14511497
*/

clients/client-workspaces/src/WorkSpacesClient.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,10 @@ import {
174174
DescribeConnectionAliasPermissionsCommandInput,
175175
DescribeConnectionAliasPermissionsCommandOutput,
176176
} from "./commands/DescribeConnectionAliasPermissionsCommand";
177+
import {
178+
DescribeCustomWorkspaceImageImportCommandInput,
179+
DescribeCustomWorkspaceImageImportCommandOutput,
180+
} from "./commands/DescribeCustomWorkspaceImageImportCommand";
177181
import {
178182
DescribeImageAssociationsCommandInput,
179183
DescribeImageAssociationsCommandOutput,
@@ -234,6 +238,10 @@ import {
234238
ImportClientBrandingCommandInput,
235239
ImportClientBrandingCommandOutput,
236240
} from "./commands/ImportClientBrandingCommand";
241+
import {
242+
ImportCustomWorkspaceImageCommandInput,
243+
ImportCustomWorkspaceImageCommandOutput,
244+
} from "./commands/ImportCustomWorkspaceImageCommand";
237245
import {
238246
ImportWorkspaceImageCommandInput,
239247
ImportWorkspaceImageCommandOutput,
@@ -392,6 +400,7 @@ export type ServiceInputTypes =
392400
| DescribeConnectClientAddInsCommandInput
393401
| DescribeConnectionAliasPermissionsCommandInput
394402
| DescribeConnectionAliasesCommandInput
403+
| DescribeCustomWorkspaceImageImportCommandInput
395404
| DescribeImageAssociationsCommandInput
396405
| DescribeIpGroupsCommandInput
397406
| DescribeTagsCommandInput
@@ -410,6 +419,7 @@ export type ServiceInputTypes =
410419
| DisassociateWorkspaceApplicationCommandInput
411420
| GetAccountLinkCommandInput
412421
| ImportClientBrandingCommandInput
422+
| ImportCustomWorkspaceImageCommandInput
413423
| ImportWorkspaceImageCommandInput
414424
| ListAccountLinksCommandInput
415425
| ListAvailableManagementCidrRangesCommandInput
@@ -486,6 +496,7 @@ export type ServiceOutputTypes =
486496
| DescribeConnectClientAddInsCommandOutput
487497
| DescribeConnectionAliasPermissionsCommandOutput
488498
| DescribeConnectionAliasesCommandOutput
499+
| DescribeCustomWorkspaceImageImportCommandOutput
489500
| DescribeImageAssociationsCommandOutput
490501
| DescribeIpGroupsCommandOutput
491502
| DescribeTagsCommandOutput
@@ -504,6 +515,7 @@ export type ServiceOutputTypes =
504515
| DisassociateWorkspaceApplicationCommandOutput
505516
| GetAccountLinkCommandOutput
506517
| ImportClientBrandingCommandOutput
518+
| ImportCustomWorkspaceImageCommandOutput
507519
| ImportWorkspaceImageCommandOutput
508520
| ListAccountLinksCommandOutput
509521
| ListAvailableManagementCidrRangesCommandOutput

clients/client-workspaces/src/commands/DescribeAccountCommand.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ export interface DescribeAccountCommandOutput extends DescribeAccountResult, __M
4343
* // DedicatedTenancySupport: "ENABLED" || "DISABLED",
4444
* // DedicatedTenancyManagementCidrRange: "STRING_VALUE",
4545
* // DedicatedTenancyAccountType: "SOURCE_ACCOUNT" || "TARGET_ACCOUNT",
46+
* // Message: "STRING_VALUE",
4647
* // };
4748
*
4849
* ```
Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
// smithy-typescript generated code
2+
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
3+
import { getSerdePlugin } from "@smithy/middleware-serde";
4+
import { Command as $Command } from "@smithy/smithy-client";
5+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
6+
7+
import { commonParams } from "../endpoint/EndpointParameters";
8+
import {
9+
DescribeCustomWorkspaceImageImportRequest,
10+
DescribeCustomWorkspaceImageImportResult,
11+
} from "../models/models_0";
12+
import {
13+
de_DescribeCustomWorkspaceImageImportCommand,
14+
se_DescribeCustomWorkspaceImageImportCommand,
15+
} from "../protocols/Aws_json1_1";
16+
import { ServiceInputTypes, ServiceOutputTypes, WorkSpacesClientResolvedConfig } from "../WorkSpacesClient";
17+
18+
/**
19+
* @public
20+
*/
21+
export type { __MetadataBearer };
22+
export { $Command };
23+
/**
24+
* @public
25+
*
26+
* The input for {@link DescribeCustomWorkspaceImageImportCommand}.
27+
*/
28+
export interface DescribeCustomWorkspaceImageImportCommandInput extends DescribeCustomWorkspaceImageImportRequest {}
29+
/**
30+
* @public
31+
*
32+
* The output of {@link DescribeCustomWorkspaceImageImportCommand}.
33+
*/
34+
export interface DescribeCustomWorkspaceImageImportCommandOutput
35+
extends DescribeCustomWorkspaceImageImportResult,
36+
__MetadataBearer {}
37+
38+
/**
39+
* <p>Retrieves information about a WorkSpace BYOL image being imported via ImportCustomWorkspaceImage.</p>
40+
* @example
41+
* Use a bare-bones client and the command you need to make an API call.
42+
* ```javascript
43+
* import { WorkSpacesClient, DescribeCustomWorkspaceImageImportCommand } from "@aws-sdk/client-workspaces"; // ES Modules import
44+
* // const { WorkSpacesClient, DescribeCustomWorkspaceImageImportCommand } = require("@aws-sdk/client-workspaces"); // CommonJS import
45+
* const client = new WorkSpacesClient(config);
46+
* const input = { // DescribeCustomWorkspaceImageImportRequest
47+
* ImageId: "STRING_VALUE", // required
48+
* };
49+
* const command = new DescribeCustomWorkspaceImageImportCommand(input);
50+
* const response = await client.send(command);
51+
* // { // DescribeCustomWorkspaceImageImportResult
52+
* // ImageId: "STRING_VALUE",
53+
* // InfrastructureConfigurationArn: "STRING_VALUE",
54+
* // State: "PENDING" || "IN_PROGRESS" || "COMPLETED" || "ERROR",
55+
* // Created: new Date("TIMESTAMP"),
56+
* // LastUpdatedTime: new Date("TIMESTAMP"),
57+
* // ImageSource: { // ImageSourceIdentifier Union: only one key present
58+
* // Ec2ImportTaskId: "STRING_VALUE",
59+
* // ImageBuildVersionArn: "STRING_VALUE",
60+
* // Ec2ImageId: "STRING_VALUE",
61+
* // },
62+
* // ImageBuilderInstanceId: "STRING_VALUE",
63+
* // ErrorDetails: [ // CustomWorkspaceImageImportErrorDetailsList
64+
* // { // CustomWorkspaceImageImportErrorDetails
65+
* // ErrorCode: "STRING_VALUE",
66+
* // ErrorMessage: "STRING_VALUE",
67+
* // },
68+
* // ],
69+
* // };
70+
*
71+
* ```
72+
*
73+
* @param DescribeCustomWorkspaceImageImportCommandInput - {@link DescribeCustomWorkspaceImageImportCommandInput}
74+
* @returns {@link DescribeCustomWorkspaceImageImportCommandOutput}
75+
* @see {@link DescribeCustomWorkspaceImageImportCommandInput} for command's `input` shape.
76+
* @see {@link DescribeCustomWorkspaceImageImportCommandOutput} for command's `response` shape.
77+
* @see {@link WorkSpacesClientResolvedConfig | config} for WorkSpacesClient's `config` shape.
78+
*
79+
* @throws {@link AccessDeniedException} (client fault)
80+
* <p>The user is not authorized to access a resource.</p>
81+
*
82+
* @throws {@link ResourceNotFoundException} (client fault)
83+
* <p>The resource could not be found.</p>
84+
*
85+
* @throws {@link WorkSpacesServiceException}
86+
* <p>Base exception class for all service exceptions from WorkSpaces service.</p>
87+
*
88+
*
89+
* @public
90+
*/
91+
export class DescribeCustomWorkspaceImageImportCommand extends $Command
92+
.classBuilder<
93+
DescribeCustomWorkspaceImageImportCommandInput,
94+
DescribeCustomWorkspaceImageImportCommandOutput,
95+
WorkSpacesClientResolvedConfig,
96+
ServiceInputTypes,
97+
ServiceOutputTypes
98+
>()
99+
.ep(commonParams)
100+
.m(function (this: any, Command: any, cs: any, config: WorkSpacesClientResolvedConfig, o: any) {
101+
return [
102+
getSerdePlugin(config, this.serialize, this.deserialize),
103+
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
104+
];
105+
})
106+
.s("WorkspacesService", "DescribeCustomWorkspaceImageImport", {})
107+
.n("WorkSpacesClient", "DescribeCustomWorkspaceImageImportCommand")
108+
.f(void 0, void 0)
109+
.ser(se_DescribeCustomWorkspaceImageImportCommand)
110+
.de(de_DescribeCustomWorkspaceImageImportCommand)
111+
.build() {
112+
/** @internal type navigation helper, not in runtime. */
113+
protected declare static __types: {
114+
api: {
115+
input: DescribeCustomWorkspaceImageImportRequest;
116+
output: DescribeCustomWorkspaceImageImportResult;
117+
};
118+
sdk: {
119+
input: DescribeCustomWorkspaceImageImportCommandInput;
120+
output: DescribeCustomWorkspaceImageImportCommandOutput;
121+
};
122+
};
123+
}

0 commit comments

Comments
 (0)