aws_sdk_sagemaker/client/
batch_replace_cluster_nodes.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`BatchReplaceClusterNodes`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`cluster_name(impl Into<String>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::cluster_name) / [`set_cluster_name(Option<String>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::set_cluster_name):<br>required: **true**<br><p>The name or Amazon Resource Name (ARN) of the SageMaker HyperPod cluster containing the nodes to replace.</p><br>
7    ///   - [`node_ids(impl Into<String>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::node_ids) / [`set_node_ids(Option<Vec::<String>>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::set_node_ids):<br>required: **false**<br><p>A list of EC2 instance IDs to replace with new hardware. You can specify between 1 and 25 instance IDs.</p><important>  <p>Replace operations destroy all instance volumes (root and secondary). Ensure you have backed up any important data before proceeding.</p> </important> <note>  <ul>   <li>    <p>Either <code>NodeIds</code> or <code>NodeLogicalIds</code> must be provided (or both), but at least one is required.</p></li>   <li>    <p>Each instance ID must follow the pattern <code>i-</code> followed by 17 hexadecimal characters (for example, <code>i-0123456789abcdef0</code>).</p></li>   <li>    <p>For SageMaker HyperPod clusters using the Slurm workload manager, you cannot replace instances that are configured as Slurm controller nodes.</p></li>  </ul> </note><br>
8    ///   - [`node_logical_ids(impl Into<String>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::node_logical_ids) / [`set_node_logical_ids(Option<Vec::<String>>)`](crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::set_node_logical_ids):<br>required: **false**<br><p>A list of logical node IDs to replace with new hardware. You can specify between 1 and 25 logical node IDs.</p> <p>The <code>NodeLogicalId</code> is a unique identifier that persists throughout the node's lifecycle and can be used to track nodes that are still being provisioned and don't yet have an EC2 instance ID assigned.</p><important>  <ul>   <li>    <p>Replace operations destroy all instance volumes (root and secondary). Ensure you have backed up any important data before proceeding.</p></li>   <li>    <p>This parameter is only supported for clusters using <code>Continuous</code> as the <code>NodeProvisioningMode</code>. For clusters using the default provisioning mode, use <code>NodeIds</code> instead.</p></li>   <li>    <p>Either <code>NodeIds</code> or <code>NodeLogicalIds</code> must be provided (or both), but at least one is required.</p></li>  </ul> </important><br>
9    /// - On success, responds with [`BatchReplaceClusterNodesOutput`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesOutput) with field(s):
10    ///   - [`successful(Option<Vec::<String>>)`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesOutput::successful): <p>A list of EC2 instance IDs for which the replacement operation was successfully initiated.</p>
11    ///   - [`failed(Option<Vec::<BatchReplaceClusterNodesError>>)`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesOutput::failed): <p>A list of errors encountered for EC2 instance IDs that could not be replaced. Each error includes the instance ID, an error code, and a descriptive message.</p>
12    ///   - [`failed_node_logical_ids(Option<Vec::<BatchReplaceClusterNodeLogicalIdsError>>)`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesOutput::failed_node_logical_ids): <p>A list of errors encountered for logical node IDs that could not be replaced. Each error includes the logical node ID, an error code, and a descriptive message. This field is only present when <code>NodeLogicalIds</code> were provided in the request.</p>
13    ///   - [`successful_node_logical_ids(Option<Vec::<String>>)`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesOutput::successful_node_logical_ids): <p>A list of logical node IDs for which the replacement operation was successfully initiated. This field is only present when <code>NodeLogicalIds</code> were provided in the request.</p>
14    /// - On failure, responds with [`SdkError<BatchReplaceClusterNodesError>`](crate::operation::batch_replace_cluster_nodes::BatchReplaceClusterNodesError)
15    pub fn batch_replace_cluster_nodes(&self) -> crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder {
16        crate::operation::batch_replace_cluster_nodes::builders::BatchReplaceClusterNodesFluentBuilder::new(self.handle.clone())
17    }
18}