Skip to content

Commit

Permalink
feat(client-service-catalog): This release introduces Service Catalog…
Browse files Browse the repository at this point in the history
… support for Terraform open source. It enables 1. The notify* APIs to Service Catalog. These APIs are used by the terraform engine to notify the result of the provisioning engine execution. 2. Adds a new TERRAFORM_OPEN_SOURCE product type in CreateProduct API.
  • Loading branch information
awstools committed Apr 3, 2023
1 parent 29ed27d commit 1aa221d
Show file tree
Hide file tree
Showing 13 changed files with 1,828 additions and 465 deletions.
24 changes: 24 additions & 0 deletions clients/client-service-catalog/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -780,6 +780,30 @@ ListTagOptions

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/classes/listtagoptionscommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/listtagoptionscommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/listtagoptionscommandoutput.html)

</details>
<details>
<summary>
NotifyProvisionProductEngineWorkflowResult
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/classes/notifyprovisionproductengineworkflowresultcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyprovisionproductengineworkflowresultcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyprovisionproductengineworkflowresultcommandoutput.html)

</details>
<details>
<summary>
NotifyTerminateProvisionedProductEngineWorkflowResult
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/classes/notifyterminateprovisionedproductengineworkflowresultcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyterminateprovisionedproductengineworkflowresultcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyterminateprovisionedproductengineworkflowresultcommandoutput.html)

</details>
<details>
<summary>
NotifyUpdateProvisionedProductEngineWorkflowResult
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/classes/notifyupdateprovisionedproductengineworkflowresultcommand.html) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyupdateprovisionedproductengineworkflowresultcommandinput.html) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/clients/client-service-catalog/interfaces/notifyupdateprovisionedproductengineworkflowresultcommandoutput.html)

</details>
<details>
<summary>
Expand Down
129 changes: 129 additions & 0 deletions clients/client-service-catalog/src/ServiceCatalog.ts
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,21 @@ import {
ListTagOptionsCommandInput,
ListTagOptionsCommandOutput,
} from "./commands/ListTagOptionsCommand";
import {
NotifyProvisionProductEngineWorkflowResultCommand,
NotifyProvisionProductEngineWorkflowResultCommandInput,
NotifyProvisionProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyProvisionProductEngineWorkflowResultCommand";
import {
NotifyTerminateProvisionedProductEngineWorkflowResultCommand,
NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyTerminateProvisionedProductEngineWorkflowResultCommand";
import {
NotifyUpdateProvisionedProductEngineWorkflowResultCommand,
NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyUpdateProvisionedProductEngineWorkflowResultCommand";
import {
ProvisionProductCommand,
ProvisionProductCommandInput,
Expand Down Expand Up @@ -3007,6 +3022,120 @@ export class ServiceCatalog extends ServiceCatalogClient {
}
}

/**
* @public
* <p>
* Notifies the result
* of the provisioning engine execution.
* </p>
*/
public notifyProvisionProductEngineWorkflowResult(
args: NotifyProvisionProductEngineWorkflowResultCommandInput,
options?: __HttpHandlerOptions
): Promise<NotifyProvisionProductEngineWorkflowResultCommandOutput>;
public notifyProvisionProductEngineWorkflowResult(
args: NotifyProvisionProductEngineWorkflowResultCommandInput,
cb: (err: any, data?: NotifyProvisionProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyProvisionProductEngineWorkflowResult(
args: NotifyProvisionProductEngineWorkflowResultCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: NotifyProvisionProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyProvisionProductEngineWorkflowResult(
args: NotifyProvisionProductEngineWorkflowResultCommandInput,
optionsOrCb?:
| __HttpHandlerOptions
| ((err: any, data?: NotifyProvisionProductEngineWorkflowResultCommandOutput) => void),
cb?: (err: any, data?: NotifyProvisionProductEngineWorkflowResultCommandOutput) => void
): Promise<NotifyProvisionProductEngineWorkflowResultCommandOutput> | void {
const command = new NotifyProvisionProductEngineWorkflowResultCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* @public
* <p>
* Notifies the result
* of the terminate engine execution.
* </p>
*/
public notifyTerminateProvisionedProductEngineWorkflowResult(
args: NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
options?: __HttpHandlerOptions
): Promise<NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput>;
public notifyTerminateProvisionedProductEngineWorkflowResult(
args: NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
cb: (err: any, data?: NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyTerminateProvisionedProductEngineWorkflowResult(
args: NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyTerminateProvisionedProductEngineWorkflowResult(
args: NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
optionsOrCb?:
| __HttpHandlerOptions
| ((err: any, data?: NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput) => void),
cb?: (err: any, data?: NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput) => void
): Promise<NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput> | void {
const command = new NotifyTerminateProvisionedProductEngineWorkflowResultCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* @public
* <p>
* Notifies the result
* of the update engine execution.
* </p>
*/
public notifyUpdateProvisionedProductEngineWorkflowResult(
args: NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
options?: __HttpHandlerOptions
): Promise<NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput>;
public notifyUpdateProvisionedProductEngineWorkflowResult(
args: NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
cb: (err: any, data?: NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyUpdateProvisionedProductEngineWorkflowResult(
args: NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput) => void
): void;
public notifyUpdateProvisionedProductEngineWorkflowResult(
args: NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
optionsOrCb?:
| __HttpHandlerOptions
| ((err: any, data?: NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput) => void),
cb?: (err: any, data?: NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput) => void
): Promise<NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput> | void {
const command = new NotifyUpdateProvisionedProductEngineWorkflowResultCommand(args);
if (typeof optionsOrCb === "function") {
this.send(command, optionsOrCb);
} else if (typeof cb === "function") {
if (typeof optionsOrCb !== "object") throw new Error(`Expect http options but get ${typeof optionsOrCb}`);
this.send(command, optionsOrCb || {}, cb);
} else {
return this.send(command, optionsOrCb);
}
}

/**
* @public
* <p>
Expand Down
18 changes: 18 additions & 0 deletions clients/client-service-catalog/src/ServiceCatalogClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,18 @@ import {
ListStackInstancesForProvisionedProductCommandOutput,
} from "./commands/ListStackInstancesForProvisionedProductCommand";
import { ListTagOptionsCommandInput, ListTagOptionsCommandOutput } from "./commands/ListTagOptionsCommand";
import {
NotifyProvisionProductEngineWorkflowResultCommandInput,
NotifyProvisionProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyProvisionProductEngineWorkflowResultCommand";
import {
NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput,
NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyTerminateProvisionedProductEngineWorkflowResultCommand";
import {
NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput,
NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput,
} from "./commands/NotifyUpdateProvisionedProductEngineWorkflowResultCommand";
import { ProvisionProductCommandInput, ProvisionProductCommandOutput } from "./commands/ProvisionProductCommand";
import {
RejectPortfolioShareCommandInput,
Expand Down Expand Up @@ -405,6 +417,9 @@ export type ServiceInputTypes =
| ListServiceActionsForProvisioningArtifactCommandInput
| ListStackInstancesForProvisionedProductCommandInput
| ListTagOptionsCommandInput
| NotifyProvisionProductEngineWorkflowResultCommandInput
| NotifyTerminateProvisionedProductEngineWorkflowResultCommandInput
| NotifyUpdateProvisionedProductEngineWorkflowResultCommandInput
| ProvisionProductCommandInput
| RejectPortfolioShareCommandInput
| ScanProvisionedProductsCommandInput
Expand Down Expand Up @@ -497,6 +512,9 @@ export type ServiceOutputTypes =
| ListServiceActionsForProvisioningArtifactCommandOutput
| ListStackInstancesForProvisionedProductCommandOutput
| ListTagOptionsCommandOutput
| NotifyProvisionProductEngineWorkflowResultCommandOutput
| NotifyTerminateProvisionedProductEngineWorkflowResultCommandOutput
| NotifyUpdateProvisionedProductEngineWorkflowResultCommandOutput
| ProvisionProductCommandOutput
| RejectPortfolioShareCommandOutput
| ScanProvisionedProductsCommandOutput
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ export interface AssociateServiceActionWithProvisioningArtifactCommandOutput
* @throws {@link DuplicateResourceException} (client fault)
* <p>The specified resource is a duplicate.</p>
*
* @throws {@link InvalidParametersException} (client fault)
* <p>One or more parameters provided to the operation are not valid.</p>
*
* @throws {@link LimitExceededException} (client fault)
* <p>The current limits of the service would have been exceeded by this operation. Decrease your
* resource use or increase your service limits and retry the operation.</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export interface CreateProductCommandOutput extends CreateProductOutput, __Metad
* SupportDescription: "STRING_VALUE",
* SupportEmail: "STRING_VALUE",
* SupportUrl: "STRING_VALUE",
* ProductType: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE", // required
* ProductType: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE" || "DEFAULT_CUSTOM" || "TERRAFORM_OPEN_SOURCE", // required
* Tags: [ // AddTags
* { // Tag
* Key: "STRING_VALUE", // required
Expand All @@ -69,7 +69,7 @@ export interface CreateProductCommandOutput extends CreateProductOutput, __Metad
* Info: { // ProvisioningArtifactInfo
* "<keys>": "STRING_VALUE",
* },
* Type: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE_AMI" || "MARKETPLACE_CAR",
* Type: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE_AMI" || "MARKETPLACE_CAR" || "DEFAULT_CUSTOM" || "TERRAFORM_OPEN_SOURCE",
* DisableTemplateValidation: true || false,
* },
* IdempotencyToken: "STRING_VALUE", // required
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export interface CreateProvisioningArtifactCommandOutput extends CreateProvision
* Info: { // ProvisioningArtifactInfo
* "<keys>": "STRING_VALUE",
* },
* Type: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE_AMI" || "MARKETPLACE_CAR",
* Type: "CLOUD_FORMATION_TEMPLATE" || "MARKETPLACE_AMI" || "MARKETPLACE_CAR" || "DEFAULT_CUSTOM" || "TERRAFORM_OPEN_SOURCE",
* DisableTemplateValidation: true || false,
* },
* IdempotencyToken: "STRING_VALUE", // required
Expand Down
Loading

0 comments on commit 1aa221d

Please sign in to comment.