aws_sdk_redshift/client/
modify_cluster.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 [`ModifyCluster`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`cluster_identifier(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::cluster_identifier) / [`set_cluster_identifier(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_cluster_identifier):<br>required: **true**<br><p>The unique identifier of the cluster to be modified.</p> <p>Example: <code>examplecluster</code></p><br>
7    ///   - [`cluster_type(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::cluster_type) / [`set_cluster_type(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_cluster_type):<br>required: **false**<br><p>The new cluster type.</p> <p>When you submit your cluster resize request, your existing cluster goes into a read-only mode. After Amazon Redshift provisions a new cluster based on your resize requirements, there will be outage for a period while the old cluster is deleted and your connection is switched to the new cluster. You can use <code>DescribeResize</code> to track the progress of the resize request.</p> <p>Valid Values: <code> multi-node | single-node </code></p><br>
8    ///   - [`node_type(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::node_type) / [`set_node_type(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_node_type):<br>required: **false**<br><p>The new node type of the cluster. If you specify a new node type, you must also specify the number of nodes parameter.</p> <p>For more information about resizing clusters, go to <a href="https://docs.aws.amazon.com/redshift/latest/mgmt/rs-resize-tutorial.html">Resizing Clusters in Amazon Redshift</a> in the <i>Amazon Redshift Cluster Management Guide</i>.</p> <p>Valid Values: <code>dc2.large</code> | <code>dc2.8xlarge</code> | <code>ra3.large</code> | <code>ra3.xlplus</code> | <code>ra3.4xlarge</code> | <code>ra3.16xlarge</code></p><br>
9    ///   - [`number_of_nodes(i32)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::number_of_nodes) / [`set_number_of_nodes(Option<i32>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_number_of_nodes):<br>required: **false**<br><p>The new number of nodes of the cluster. If you specify a new number of nodes, you must also specify the node type parameter.</p> <p>For more information about resizing clusters, go to <a href="https://docs.aws.amazon.com/redshift/latest/mgmt/rs-resize-tutorial.html">Resizing Clusters in Amazon Redshift</a> in the <i>Amazon Redshift Cluster Management Guide</i>.</p> <p>Valid Values: Integer greater than <code>0</code>.</p><br>
10    ///   - [`cluster_security_groups(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::cluster_security_groups) / [`set_cluster_security_groups(Option<Vec::<String>>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_cluster_security_groups):<br>required: **false**<br><p>A list of cluster security groups to be authorized on this cluster. This change is asynchronously applied as soon as possible.</p> <p>Security groups currently associated with the cluster, and not in the list of groups to apply, will be revoked from the cluster.</p> <p>Constraints:</p> <ul>  <li>   <p>Must be 1 to 255 alphanumeric characters or hyphens</p></li>  <li>   <p>First character must be a letter</p></li>  <li>   <p>Cannot end with a hyphen or contain two consecutive hyphens</p></li> </ul><br>
11    ///   - [`vpc_security_group_ids(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::vpc_security_group_ids) / [`set_vpc_security_group_ids(Option<Vec::<String>>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_vpc_security_group_ids):<br>required: **false**<br><p>A list of virtual private cloud (VPC) security groups to be associated with the cluster. This change is asynchronously applied as soon as possible.</p><br>
12    ///   - [`master_user_password(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::master_user_password) / [`set_master_user_password(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_master_user_password):<br>required: **false**<br><p>The new password for the cluster admin user. This change is asynchronously applied as soon as possible. Between the time of the request and the completion of the request, the <code>MasterUserPassword</code> element exists in the <code>PendingModifiedValues</code> element of the operation response.</p> <p>You can't use <code>MasterUserPassword</code> if <code>ManageMasterPassword</code> is <code>true</code>.</p><note>  <p>Operations never return the password, so this operation provides a way to regain access to the admin user account for a cluster if the password is lost.</p> </note> <p>Default: Uses existing setting.</p> <p>Constraints:</p> <ul>  <li>   <p>Must be between 8 and 64 characters in length.</p></li>  <li>   <p>Must contain at least one uppercase letter.</p></li>  <li>   <p>Must contain at least one lowercase letter.</p></li>  <li>   <p>Must contain one number.</p></li>  <li>   <p>Can be any printable ASCII character (ASCII code 33-126) except <code>'</code> (single quote), <code>"</code> (double quote), <code>\</code>, <code>/</code>, or <code>@</code>.</p></li> </ul><br>
13    ///   - [`cluster_parameter_group_name(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::cluster_parameter_group_name) / [`set_cluster_parameter_group_name(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_cluster_parameter_group_name):<br>required: **false**<br><p>The name of the cluster parameter group to apply to this cluster. This change is applied only after the cluster is rebooted. To reboot a cluster use <code>RebootCluster</code>.</p> <p>Default: Uses existing setting.</p> <p>Constraints: The cluster parameter group must be in the same parameter group family that matches the cluster version.</p><br>
14    ///   - [`automated_snapshot_retention_period(i32)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::automated_snapshot_retention_period) / [`set_automated_snapshot_retention_period(Option<i32>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_automated_snapshot_retention_period):<br>required: **false**<br><p>The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Even if automated snapshots are disabled, you can still create manual snapshots when you want with <code>CreateClusterSnapshot</code>.</p> <p>If you decrease the automated snapshot retention period from its current value, existing automated snapshots that fall outside of the new retention period will be immediately deleted.</p> <p>You can't disable automated snapshots for RA3 node types. Set the automated retention period from 1-35 days.</p> <p>Default: Uses existing setting.</p> <p>Constraints: Must be a value from 0 to 35.</p><br>
15    ///   - [`manual_snapshot_retention_period(i32)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::manual_snapshot_retention_period) / [`set_manual_snapshot_retention_period(Option<i32>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_manual_snapshot_retention_period):<br>required: **false**<br><p>The default for number of days that a newly created manual snapshot is retained. If the value is -1, the manual snapshot is retained indefinitely. This value doesn't retroactively change the retention periods of existing manual snapshots.</p> <p>The value must be either -1 or an integer between 1 and 3,653.</p> <p>The default value is -1.</p><br>
16    ///   - [`preferred_maintenance_window(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::preferred_maintenance_window) / [`set_preferred_maintenance_window(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_preferred_maintenance_window):<br>required: **false**<br><p>The weekly time range (in UTC) during which system maintenance can occur, if necessary. If system maintenance is necessary during the window, it may result in an outage.</p> <p>This maintenance window change is made immediately. If the new maintenance window indicates the current time, there must be at least 120 minutes between the current time and end of the window in order to ensure that pending changes are applied.</p> <p>Default: Uses existing setting.</p> <p>Format: ddd:hh24:mi-ddd:hh24:mi, for example <code>wed:07:30-wed:08:00</code>.</p> <p>Valid Days: Mon | Tue | Wed | Thu | Fri | Sat | Sun</p> <p>Constraints: Must be at least 30 minutes.</p><br>
17    ///   - [`cluster_version(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::cluster_version) / [`set_cluster_version(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_cluster_version):<br>required: **false**<br><p>The new version number of the Amazon Redshift engine to upgrade to.</p> <p>For major version upgrades, if a non-default cluster parameter group is currently in use, a new cluster parameter group in the cluster parameter group family for the new version must be specified. The new cluster parameter group can be the default for that cluster parameter group family. For more information about parameters and parameter groups, go to <a href="https://docs.aws.amazon.com/redshift/latest/mgmt/working-with-parameter-groups.html">Amazon Redshift Parameter Groups</a> in the <i>Amazon Redshift Cluster Management Guide</i>.</p> <p>Example: <code>1.0</code></p><br>
18    ///   - [`allow_version_upgrade(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::allow_version_upgrade) / [`set_allow_version_upgrade(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_allow_version_upgrade):<br>required: **false**<br><p>If <code>true</code>, major version upgrades will be applied automatically to the cluster during the maintenance window.</p> <p>Default: <code>false</code></p><br>
19    ///   - [`hsm_client_certificate_identifier(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::hsm_client_certificate_identifier) / [`set_hsm_client_certificate_identifier(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_hsm_client_certificate_identifier):<br>required: **false**<br><p>Specifies the name of the HSM client certificate the Amazon Redshift cluster uses to retrieve the data encryption keys stored in an HSM.</p><br>
20    ///   - [`hsm_configuration_identifier(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::hsm_configuration_identifier) / [`set_hsm_configuration_identifier(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_hsm_configuration_identifier):<br>required: **false**<br><p>Specifies the name of the HSM configuration that contains the information the Amazon Redshift cluster can use to retrieve and store keys in an HSM.</p><br>
21    ///   - [`new_cluster_identifier(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::new_cluster_identifier) / [`set_new_cluster_identifier(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_new_cluster_identifier):<br>required: **false**<br><p>The new identifier for the cluster.</p> <p>Constraints:</p> <ul>  <li>   <p>Must contain from 1 to 63 alphanumeric characters or hyphens.</p></li>  <li>   <p>Alphabetic characters must be lowercase.</p></li>  <li>   <p>First character must be a letter.</p></li>  <li>   <p>Cannot end with a hyphen or contain two consecutive hyphens.</p></li>  <li>   <p>Must be unique for all clusters within an Amazon Web Services account.</p></li> </ul> <p>Example: <code>examplecluster</code></p><br>
22    ///   - [`publicly_accessible(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::publicly_accessible) / [`set_publicly_accessible(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_publicly_accessible):<br>required: **false**<br><p>If <code>true</code>, the cluster can be accessed from a public network. Only clusters in VPCs can be set to be publicly available.</p> <p>Default: false</p><br>
23    ///   - [`elastic_ip(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::elastic_ip) / [`set_elastic_ip(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_elastic_ip):<br>required: **false**<br><p>The Elastic IP (EIP) address for the cluster.</p> <p>Constraints: The cluster must be provisioned in EC2-VPC and publicly-accessible through an Internet gateway. For more information about provisioning clusters in EC2-VPC, go to <a href="https://docs.aws.amazon.com/redshift/latest/mgmt/working-with-clusters.html#cluster-platforms">Supported Platforms to Launch Your Cluster</a> in the Amazon Redshift Cluster Management Guide.</p><br>
24    ///   - [`enhanced_vpc_routing(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::enhanced_vpc_routing) / [`set_enhanced_vpc_routing(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_enhanced_vpc_routing):<br>required: **false**<br><p>An option that specifies whether to create the cluster with enhanced VPC routing enabled. To create a cluster that uses enhanced VPC routing, the cluster must be in a VPC. For more information, see <a href="https://docs.aws.amazon.com/redshift/latest/mgmt/enhanced-vpc-routing.html">Enhanced VPC Routing</a> in the Amazon Redshift Cluster Management Guide.</p> <p>If this option is <code>true</code>, enhanced VPC routing is enabled.</p> <p>Default: false</p><br>
25    ///   - [`maintenance_track_name(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::maintenance_track_name) / [`set_maintenance_track_name(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_maintenance_track_name):<br>required: **false**<br><p>The name for the maintenance track that you want to assign for the cluster. This name change is asynchronous. The new track name stays in the <code>PendingModifiedValues</code> for the cluster until the next maintenance window. When the maintenance track changes, the cluster is switched to the latest cluster release available for the maintenance track. At this point, the maintenance track name is applied.</p><br>
26    ///   - [`encrypted(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::encrypted) / [`set_encrypted(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_encrypted):<br>required: **false**<br><p>Indicates whether the cluster is encrypted. If the value is encrypted (true) and you provide a value for the <code>KmsKeyId</code> parameter, we encrypt the cluster with the provided <code>KmsKeyId</code>. If you don't provide a <code>KmsKeyId</code>, we encrypt with the default key.</p> <p>If the value is not encrypted (false), then the cluster is decrypted.</p><br>
27    ///   - [`kms_key_id(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::kms_key_id) / [`set_kms_key_id(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_kms_key_id):<br>required: **false**<br><p>The Key Management Service (KMS) key ID of the encryption key that you want to use to encrypt data in the cluster.</p><br>
28    ///   - [`availability_zone_relocation(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::availability_zone_relocation) / [`set_availability_zone_relocation(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_availability_zone_relocation):<br>required: **false**<br><p>The option to enable relocation for an Amazon Redshift cluster between Availability Zones after the cluster modification is complete.</p><br>
29    ///   - [`availability_zone(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::availability_zone) / [`set_availability_zone(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_availability_zone):<br>required: **false**<br><p>The option to initiate relocation for an Amazon Redshift cluster to the target Availability Zone.</p><br>
30    ///   - [`port(i32)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::port) / [`set_port(Option<i32>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_port):<br>required: **false**<br><p>The option to change the port of an Amazon Redshift cluster.</p> <p>Valid Values:</p> <ul>  <li>   <p>For clusters with ra3 nodes - Select a port within the ranges <code>5431-5455</code> or <code>8191-8215</code>. (If you have an existing cluster with ra3 nodes, it isn't required that you change the port to these ranges.)</p></li>  <li>   <p>For clusters with dc2 nodes - Select a port within the range <code>1150-65535</code>.</p></li> </ul><br>
31    ///   - [`manage_master_password(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::manage_master_password) / [`set_manage_master_password(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_manage_master_password):<br>required: **false**<br><p>If <code>true</code>, Amazon Redshift uses Secrets Manager to manage this cluster's admin credentials. You can't use <code>MasterUserPassword</code> if <code>ManageMasterPassword</code> is true. If <code>ManageMasterPassword</code> is false or not set, Amazon Redshift uses <code>MasterUserPassword</code> for the admin user account's password.</p><br>
32    ///   - [`master_password_secret_kms_key_id(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::master_password_secret_kms_key_id) / [`set_master_password_secret_kms_key_id(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_master_password_secret_kms_key_id):<br>required: **false**<br><p>The ID of the Key Management Service (KMS) key used to encrypt and store the cluster's admin credentials secret. You can only use this parameter if <code>ManageMasterPassword</code> is true.</p><br>
33    ///   - [`ip_address_type(impl Into<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::ip_address_type) / [`set_ip_address_type(Option<String>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_ip_address_type):<br>required: **false**<br><p>The IP address types that the cluster supports. Possible values are <code>ipv4</code> and <code>dualstack</code>.</p><br>
34    ///   - [`multi_az(bool)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::multi_az) / [`set_multi_az(Option<bool>)`](crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::set_multi_az):<br>required: **false**<br><p>If true and the cluster is currently only deployed in a single Availability Zone, the cluster will be modified to be deployed in two Availability Zones.</p><br>
35    /// - On success, responds with [`ModifyClusterOutput`](crate::operation::modify_cluster::ModifyClusterOutput) with field(s):
36    ///   - [`cluster(Option<Cluster>)`](crate::operation::modify_cluster::ModifyClusterOutput::cluster): <p>Describes a cluster.</p>
37    /// - On failure, responds with [`SdkError<ModifyClusterError>`](crate::operation::modify_cluster::ModifyClusterError)
38    pub fn modify_cluster(&self) -> crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder {
39        crate::operation::modify_cluster::builders::ModifyClusterFluentBuilder::new(self.handle.clone())
40    }
41}