Skip to content

Commit

Permalink
feat(client-sagemaker): This release adds a new API UpdateClusterSoft…
Browse files Browse the repository at this point in the history
…ware for SageMaker HyperPod. This API allows users to patch HyperPod clusters with latest platform softwares.
  • Loading branch information
awstools committed Feb 15, 2024
1 parent 2905d17 commit bfe260b
Show file tree
Hide file tree
Showing 16 changed files with 319 additions and 58 deletions.
8 changes: 8 additions & 0 deletions clients/client-sagemaker/README.md
Expand Up @@ -2513,6 +2513,14 @@ UpdateCluster

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/sagemaker/command/UpdateClusterCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-sagemaker/Interface/UpdateClusterCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-sagemaker/Interface/UpdateClusterCommandOutput/)

</details>
<details>
<summary>
UpdateClusterSoftware
</summary>

[Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/sagemaker/command/UpdateClusterSoftwareCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-sagemaker/Interface/UpdateClusterSoftwareCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-sagemaker/Interface/UpdateClusterSoftwareCommandOutput/)

</details>
<details>
<summary>
Expand Down
23 changes: 23 additions & 0 deletions clients/client-sagemaker/src/SageMaker.ts
Expand Up @@ -1325,6 +1325,11 @@ import {
UpdateClusterCommandInput,
UpdateClusterCommandOutput,
} from "./commands/UpdateClusterCommand";
import {
UpdateClusterSoftwareCommand,
UpdateClusterSoftwareCommandInput,
UpdateClusterSoftwareCommandOutput,
} from "./commands/UpdateClusterSoftwareCommand";
import {
UpdateCodeRepositoryCommand,
UpdateCodeRepositoryCommandInput,
Expand Down Expand Up @@ -1759,6 +1764,7 @@ const commands = {
UpdateAppImageConfigCommand,
UpdateArtifactCommand,
UpdateClusterCommand,
UpdateClusterSoftwareCommand,
UpdateCodeRepositoryCommand,
UpdateContextCommand,
UpdateDeviceFleetCommand,
Expand Down Expand Up @@ -6259,6 +6265,23 @@ export interface SageMaker {
cb: (err: any, data?: UpdateClusterCommandOutput) => void
): void;

/**
* @see {@link UpdateClusterSoftwareCommand}
*/
updateClusterSoftware(
args: UpdateClusterSoftwareCommandInput,
options?: __HttpHandlerOptions
): Promise<UpdateClusterSoftwareCommandOutput>;
updateClusterSoftware(
args: UpdateClusterSoftwareCommandInput,
cb: (err: any, data?: UpdateClusterSoftwareCommandOutput) => void
): void;
updateClusterSoftware(
args: UpdateClusterSoftwareCommandInput,
options: __HttpHandlerOptions,
cb: (err: any, data?: UpdateClusterSoftwareCommandOutput) => void
): void;

/**
* @see {@link UpdateCodeRepositoryCommand}
*/
Expand Down
6 changes: 6 additions & 0 deletions clients/client-sagemaker/src/SageMakerClient.ts
Expand Up @@ -793,6 +793,10 @@ import {
} from "./commands/UpdateAppImageConfigCommand";
import { UpdateArtifactCommandInput, UpdateArtifactCommandOutput } from "./commands/UpdateArtifactCommand";
import { UpdateClusterCommandInput, UpdateClusterCommandOutput } from "./commands/UpdateClusterCommand";
import {
UpdateClusterSoftwareCommandInput,
UpdateClusterSoftwareCommandOutput,
} from "./commands/UpdateClusterSoftwareCommand";
import {
UpdateCodeRepositoryCommandInput,
UpdateCodeRepositoryCommandOutput,
Expand Down Expand Up @@ -1163,6 +1167,7 @@ export type ServiceInputTypes =
| UpdateAppImageConfigCommandInput
| UpdateArtifactCommandInput
| UpdateClusterCommandInput
| UpdateClusterSoftwareCommandInput
| UpdateCodeRepositoryCommandInput
| UpdateContextCommandInput
| UpdateDeviceFleetCommandInput
Expand Down Expand Up @@ -1487,6 +1492,7 @@ export type ServiceOutputTypes =
| UpdateAppImageConfigCommandOutput
| UpdateArtifactCommandOutput
| UpdateClusterCommandOutput
| UpdateClusterSoftwareCommandOutput
| UpdateCodeRepositoryCommandOutput
| UpdateContextCommandOutput
| UpdateDeviceFleetCommandOutput
Expand Down
14 changes: 7 additions & 7 deletions clients/client-sagemaker/src/commands/AddTagsCommand.ts
Expand Up @@ -45,13 +45,13 @@ export interface AddTagsCommandOutput extends AddTagsOutput, __MetadataBearer {}
* </p>
* </note>
* <note>
* <p>Tags that you add to a SageMaker Domain or User Profile by calling this API
* are also added to any Apps that the Domain or User Profile launches after you call
* this API, but not to Apps that the Domain or User Profile launched before you called
* this API. To make sure that the tags associated with a Domain or User Profile are
* also added to all Apps that the Domain or User Profile launches, add the tags when
* you first create the Domain or User Profile by specifying them in the
* <code>Tags</code> parameter of <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateDomain.html">CreateDomain</a>
* <p>Tags that you add to a SageMaker Domain or User Profile by calling this API are
* also added to any Apps that the Domain or User Profile launches after you call this
* API, but not to Apps that the Domain or User Profile launched before you called this
* API. To make sure that the tags associated with a Domain or User Profile are also
* added to all Apps that the Domain or User Profile launches, add the tags when you
* first create the Domain or User Profile by specifying them in the <code>Tags</code>
* parameter of <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateDomain.html">CreateDomain</a>
* or <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateUserProfile.html">CreateUserProfile</a>.</p>
* </note>
* @example
Expand Down
Expand Up @@ -33,7 +33,7 @@ export interface DeleteHyperParameterTuningJobCommandOutput extends __MetadataBe
* @public
* <p>Deletes a hyperparameter tuning job. The <code>DeleteHyperParameterTuningJob</code>
* API deletes only the tuning job entry that was created in SageMaker when you called the
* <code>CreateHyperParameterTuningJob</code> API. It does not delete training jobs,
* <code>CreateHyperParameterTuningJob</code> API. It does not delete training jobs,
* artifacts, or the IAM role that you specified when creating the model.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
Expand Down
6 changes: 3 additions & 3 deletions clients/client-sagemaker/src/commands/DeleteTagsCommand.ts
Expand Up @@ -36,9 +36,9 @@ export interface DeleteTagsCommandOutput extends DeleteTagsOutput, __MetadataBea
* launched before you called this API.</p>
* </note>
* <note>
* <p>When you call this API to delete tags from a SageMaker Domain or User
* Profile, the deleted tags are not removed from Apps that the SageMaker Domain
* or User Profile launched before you called this API.</p>
* <p>When you call this API to delete tags from a SageMaker Domain or User Profile, the
* deleted tags are not removed from Apps that the SageMaker Domain or User Profile
* launched before you called this API.</p>
* </note>
* @example
* Use a bare-bones client and the command you need to make an API call.
Expand Down
Expand Up @@ -28,7 +28,7 @@ export interface UpdateClusterCommandOutput extends UpdateClusterResponse, __Met

/**
* @public
* <p>Update a SageMaker HyperPod cluster.</p>
* <p>Updates a SageMaker HyperPod cluster.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
@@ -0,0 +1,89 @@
// smithy-typescript generated code
import { getEndpointPlugin } from "@smithy/middleware-endpoint";
import { getSerdePlugin } from "@smithy/middleware-serde";
import { Command as $Command } from "@smithy/smithy-client";
import { MetadataBearer as __MetadataBearer } from "@smithy/types";

import { commonParams } from "../endpoint/EndpointParameters";
import { UpdateClusterSoftwareRequest, UpdateClusterSoftwareResponse } from "../models/models_4";
import { de_UpdateClusterSoftwareCommand, se_UpdateClusterSoftwareCommand } from "../protocols/Aws_json1_1";
import { SageMakerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SageMakerClient";

/**
* @public
*/
export { __MetadataBearer, $Command };
/**
* @public
*
* The input for {@link UpdateClusterSoftwareCommand}.
*/
export interface UpdateClusterSoftwareCommandInput extends UpdateClusterSoftwareRequest {}
/**
* @public
*
* The output of {@link UpdateClusterSoftwareCommand}.
*/
export interface UpdateClusterSoftwareCommandOutput extends UpdateClusterSoftwareResponse, __MetadataBearer {}

/**
* @public
* <p>Updates the platform software of a SageMaker HyperPod cluster for security patching. To learn how to
* use this API, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/sagemaker-hyperpod-operate.html#sagemaker-hyperpod-operate-cli-command-update-cluster-software">Update the SageMaker HyperPod platform software of a cluster</a>.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
* import { SageMakerClient, UpdateClusterSoftwareCommand } from "@aws-sdk/client-sagemaker"; // ES Modules import
* // const { SageMakerClient, UpdateClusterSoftwareCommand } = require("@aws-sdk/client-sagemaker"); // CommonJS import
* const client = new SageMakerClient(config);
* const input = { // UpdateClusterSoftwareRequest
* ClusterName: "STRING_VALUE", // required
* };
* const command = new UpdateClusterSoftwareCommand(input);
* const response = await client.send(command);
* // { // UpdateClusterSoftwareResponse
* // ClusterArn: "STRING_VALUE", // required
* // };
*
* ```
*
* @param UpdateClusterSoftwareCommandInput - {@link UpdateClusterSoftwareCommandInput}
* @returns {@link UpdateClusterSoftwareCommandOutput}
* @see {@link UpdateClusterSoftwareCommandInput} for command's `input` shape.
* @see {@link UpdateClusterSoftwareCommandOutput} for command's `response` shape.
* @see {@link SageMakerClientResolvedConfig | config} for SageMakerClient's `config` shape.
*
* @throws {@link ConflictException} (client fault)
* <p>There was a conflict when you attempted to modify a SageMaker entity such as an
* <code>Experiment</code> or <code>Artifact</code>.</p>
*
* @throws {@link ResourceNotFound} (client fault)
* <p>Resource being access is not found.</p>
*
* @throws {@link SageMakerServiceException}
* <p>Base exception class for all service exceptions from SageMaker service.</p>
*
*/
export class UpdateClusterSoftwareCommand extends $Command
.classBuilder<
UpdateClusterSoftwareCommandInput,
UpdateClusterSoftwareCommandOutput,
SageMakerClientResolvedConfig,
ServiceInputTypes,
ServiceOutputTypes
>()
.ep({
...commonParams,
})
.m(function (this: any, Command: any, cs: any, config: SageMakerClientResolvedConfig, o: any) {
return [
getSerdePlugin(config, this.serialize, this.deserialize),
getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
];
})
.s("SageMaker", "UpdateClusterSoftware", {})
.n("SageMakerClient", "UpdateClusterSoftwareCommand")
.f(void 0, void 0)
.ser(se_UpdateClusterSoftwareCommand)
.de(de_UpdateClusterSoftwareCommand)
.build() {}
19 changes: 9 additions & 10 deletions clients/client-sagemaker/src/commands/UpdateEndpointCommand.ts
Expand Up @@ -28,16 +28,15 @@ export interface UpdateEndpointCommandOutput extends UpdateEndpointOutput, __Met

/**
* @public
* <p>Deploys the <code>EndpointConfig</code> specified in the request
* to a new fleet of instances. SageMaker shifts endpoint traffic to the new instances
* with the updated endpoint configuration and then deletes the old instances
* using the previous <code>EndpointConfig</code> (there is no availability loss).
* For more information about how to control the update and traffic shifting process, see
* <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/deployment-guardrails.html">
* Update models in production</a>.</p>
* <p>When SageMaker receives the request, it sets the endpoint status to
* <code>Updating</code>. After updating the endpoint, it sets the status to
* <code>InService</code>. To check the status of an endpoint, use the <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_DescribeEndpoint.html">DescribeEndpoint</a> API.
* <p>Deploys the <code>EndpointConfig</code> specified in the request to a new fleet of
* instances. SageMaker shifts endpoint traffic to the new instances with the updated endpoint
* configuration and then deletes the old instances using the previous
* <code>EndpointConfig</code> (there is no availability loss). For more information
* about how to control the update and traffic shifting process, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/deployment-guardrails.html"> Update
* models in production</a>.</p>
* <p>When SageMaker receives the request, it sets the endpoint status to <code>Updating</code>.
* After updating the endpoint, it sets the status to <code>InService</code>. To check the
* status of an endpoint, use the <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_DescribeEndpoint.html">DescribeEndpoint</a> API.
*
* </p>
* <note>
Expand Down
1 change: 1 addition & 0 deletions clients/client-sagemaker/src/commands/index.ts
Expand Up @@ -286,6 +286,7 @@ export * from "./UpdateActionCommand";
export * from "./UpdateAppImageConfigCommand";
export * from "./UpdateArtifactCommand";
export * from "./UpdateClusterCommand";
export * from "./UpdateClusterSoftwareCommand";
export * from "./UpdateCodeRepositoryCommand";
export * from "./UpdateContextCommand";
export * from "./UpdateDeviceFleetCommand";
Expand Down
6 changes: 3 additions & 3 deletions clients/client-sagemaker/src/models/models_0.ts
Expand Up @@ -1249,7 +1249,7 @@ export interface S3DataSource {
* <ul>
* <li>
* <p> A key name prefix might look like this:
* <code>s3://bucketname/exampleprefix/</code>
* <code>s3://bucketname/exampleprefix/</code>
* </p>
* </li>
* <li>
Expand Down Expand Up @@ -1531,8 +1531,8 @@ export interface OutputDataConfig {
*
* For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/UsingKMSEncryption.html">KMS-Managed Encryption
* Keys</a> in the <i>Amazon Simple Storage Service Developer Guide</i>. If the output
* data is stored in Amazon S3 Express One Zone, it is encrypted with server-side
* encryption with Amazon S3 managed keys (SSE-S3). KMS key is not supported for Amazon S3 Express One Zone</p>
* data is stored in Amazon S3 Express One Zone, it is encrypted with server-side encryption with Amazon S3
* managed keys (SSE-S3). KMS key is not supported for Amazon S3 Express One Zone</p>
* <p>The KMS key policy must grant permission to the IAM role that you specify in your
* <code>CreateTrainingJob</code>, <code>CreateTransformJob</code>, or
* <code>CreateHyperParameterTuningJob</code> requests. For more information, see
Expand Down
22 changes: 13 additions & 9 deletions clients/client-sagemaker/src/models/models_2.ts
Expand Up @@ -362,9 +362,10 @@ export interface ProfilerRuleConfiguration {

/**
* @public
* <p>Configuration for remote debugging for the <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateTrainingJob.html">CreateTrainingJob</a> API. To learn more about the remote
* debugging functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container through Amazon Web Services Systems Manager (SSM)
* for remote debugging</a>.</p>
* <p>Configuration for remote debugging for the <a href="https://docs.aws.amazon.com/sagemaker/latest/APIReference/API_CreateTrainingJob.html">CreateTrainingJob</a> API. To learn more about the remote debugging
* functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container
* through Amazon Web Services Systems Manager (SSM) for remote
* debugging</a>.</p>
*/
export interface RemoteDebugConfig {
/**
Expand Down Expand Up @@ -628,9 +629,10 @@ export interface CreateTrainingJobRequest {

/**
* @public
* <p>Configuration for remote debugging. To learn more about the remote
* debugging functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container through Amazon Web Services Systems Manager (SSM)
* for remote debugging</a>.</p>
* <p>Configuration for remote debugging. To learn more about the remote debugging
* functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container
* through Amazon Web Services Systems Manager (SSM) for remote
* debugging</a>.</p>
*/
RemoteDebugConfig?: RemoteDebugConfig;

Expand Down Expand Up @@ -3656,9 +3658,11 @@ export interface DescribeCompilationJobRequest {
* @public
* <p>Provides information about the location that is configured for storing model
* artifacts. </p>
* <p>Model artifacts are the output that results from training a model, and typically
* consist of trained parameters, a model definition that describes how to compute
* inferences, and other metadata.</p>
* <p>Model artifacts are outputs that result from training a model. They typically consist
* of trained parameters, a model definition that describes how to compute inferences, and
* other metadata. A SageMaker container stores your trained model artifacts in the
* <code>/opt/ml/model</code> directory. After training has completed, by default, these artifacts
* are uploaded to your Amazon S3 bucket as compressed files.</p>
*/
export interface ModelArtifacts {
/**
Expand Down
7 changes: 4 additions & 3 deletions clients/client-sagemaker/src/models/models_3.ts
Expand Up @@ -1073,9 +1073,10 @@ export interface DescribeTrainingJobResponse {

/**
* @public
* <p>Configuration for remote debugging. To learn more about the remote
* debugging functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container through Amazon Web Services Systems Manager (SSM)
* for remote debugging</a>.</p>
* <p>Configuration for remote debugging. To learn more about the remote debugging
* functionality of SageMaker, see <a href="https://docs.aws.amazon.com/sagemaker/latest/dg/train-remote-debugging.html">Access a training container
* through Amazon Web Services Systems Manager (SSM) for remote
* debugging</a>.</p>
*/
RemoteDebugConfig?: RemoteDebugConfig;

Expand Down

0 comments on commit bfe260b

Please sign in to comment.