aws_sdk_docdb/operation/modify_db_cluster/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::modify_db_cluster::_modify_db_cluster_output::ModifyDbClusterOutputBuilder;
3
4pub use crate::operation::modify_db_cluster::_modify_db_cluster_input::ModifyDbClusterInputBuilder;
5
6impl crate::operation::modify_db_cluster::builders::ModifyDbClusterInputBuilder {
7    /// Sends a request with this input using the given client.
8    pub async fn send_with(
9        self,
10        client: &crate::Client,
11    ) -> ::std::result::Result<
12        crate::operation::modify_db_cluster::ModifyDbClusterOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::modify_db_cluster::ModifyDBClusterError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.modify_db_cluster();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `ModifyDBCluster`.
24///
25/// <p>Modifies a setting for an Amazon DocumentDB cluster. You can change one or more database configuration parameters by specifying these parameters and the new values in the request.</p>
26#[derive(::std::clone::Clone, ::std::fmt::Debug)]
27pub struct ModifyDBClusterFluentBuilder {
28    handle: ::std::sync::Arc<crate::client::Handle>,
29    inner: crate::operation::modify_db_cluster::builders::ModifyDbClusterInputBuilder,
30    config_override: ::std::option::Option<crate::config::Builder>,
31}
32impl
33    crate::client::customize::internal::CustomizableSend<
34        crate::operation::modify_db_cluster::ModifyDbClusterOutput,
35        crate::operation::modify_db_cluster::ModifyDBClusterError,
36    > for ModifyDBClusterFluentBuilder
37{
38    fn send(
39        self,
40        config_override: crate::config::Builder,
41    ) -> crate::client::customize::internal::BoxFuture<
42        crate::client::customize::internal::SendResult<
43            crate::operation::modify_db_cluster::ModifyDbClusterOutput,
44            crate::operation::modify_db_cluster::ModifyDBClusterError,
45        >,
46    > {
47        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
48    }
49}
50impl ModifyDBClusterFluentBuilder {
51    /// Creates a new `ModifyDBClusterFluentBuilder`.
52    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
53        Self {
54            handle,
55            inner: ::std::default::Default::default(),
56            config_override: ::std::option::Option::None,
57        }
58    }
59    /// Access the ModifyDBCluster as a reference.
60    pub fn as_input(&self) -> &crate::operation::modify_db_cluster::builders::ModifyDbClusterInputBuilder {
61        &self.inner
62    }
63    /// Sends the request and returns the response.
64    ///
65    /// If an error occurs, an `SdkError` will be returned with additional details that
66    /// can be matched against.
67    ///
68    /// By default, any retryable failures will be retried twice. Retry behavior
69    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
70    /// set when configuring the client.
71    pub async fn send(
72        self,
73    ) -> ::std::result::Result<
74        crate::operation::modify_db_cluster::ModifyDbClusterOutput,
75        ::aws_smithy_runtime_api::client::result::SdkError<
76            crate::operation::modify_db_cluster::ModifyDBClusterError,
77            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
78        >,
79    > {
80        let input = self
81            .inner
82            .build()
83            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
84        let runtime_plugins = crate::operation::modify_db_cluster::ModifyDBCluster::operation_runtime_plugins(
85            self.handle.runtime_plugins.clone(),
86            &self.handle.conf,
87            self.config_override,
88        );
89        crate::operation::modify_db_cluster::ModifyDBCluster::orchestrate(&runtime_plugins, input).await
90    }
91
92    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
93    pub fn customize(
94        self,
95    ) -> crate::client::customize::CustomizableOperation<
96        crate::operation::modify_db_cluster::ModifyDbClusterOutput,
97        crate::operation::modify_db_cluster::ModifyDBClusterError,
98        Self,
99    > {
100        crate::client::customize::CustomizableOperation::new(self)
101    }
102    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
103        self.set_config_override(::std::option::Option::Some(config_override.into()));
104        self
105    }
106
107    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
108        self.config_override = config_override;
109        self
110    }
111    /// <p>The cluster identifier for the cluster that is being modified. This parameter is not case sensitive.</p>
112    /// <p>Constraints:</p>
113    /// <ul>
114    /// <li>
115    /// <p>Must match the identifier of an existing <code>DBCluster</code>.</p></li>
116    /// </ul>
117    pub fn db_cluster_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
118        self.inner = self.inner.db_cluster_identifier(input.into());
119        self
120    }
121    /// <p>The cluster identifier for the cluster that is being modified. This parameter is not case sensitive.</p>
122    /// <p>Constraints:</p>
123    /// <ul>
124    /// <li>
125    /// <p>Must match the identifier of an existing <code>DBCluster</code>.</p></li>
126    /// </ul>
127    pub fn set_db_cluster_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
128        self.inner = self.inner.set_db_cluster_identifier(input);
129        self
130    }
131    /// <p>The cluster identifier for the cluster that is being modified. This parameter is not case sensitive.</p>
132    /// <p>Constraints:</p>
133    /// <ul>
134    /// <li>
135    /// <p>Must match the identifier of an existing <code>DBCluster</code>.</p></li>
136    /// </ul>
137    pub fn get_db_cluster_identifier(&self) -> &::std::option::Option<::std::string::String> {
138        self.inner.get_db_cluster_identifier()
139    }
140    /// <p>The new cluster identifier for the cluster when renaming a cluster. This value is stored as a lowercase string.</p>
141    /// <p>Constraints:</p>
142    /// <ul>
143    /// <li>
144    /// <p>Must contain from 1 to 63 letters, numbers, or hyphens.</p></li>
145    /// <li>
146    /// <p>The first character must be a letter.</p></li>
147    /// <li>
148    /// <p>Cannot end with a hyphen or contain two consecutive hyphens.</p></li>
149    /// </ul>
150    /// <p>Example: <code>my-cluster2</code></p>
151    pub fn new_db_cluster_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
152        self.inner = self.inner.new_db_cluster_identifier(input.into());
153        self
154    }
155    /// <p>The new cluster identifier for the cluster when renaming a cluster. This value is stored as a lowercase string.</p>
156    /// <p>Constraints:</p>
157    /// <ul>
158    /// <li>
159    /// <p>Must contain from 1 to 63 letters, numbers, or hyphens.</p></li>
160    /// <li>
161    /// <p>The first character must be a letter.</p></li>
162    /// <li>
163    /// <p>Cannot end with a hyphen or contain two consecutive hyphens.</p></li>
164    /// </ul>
165    /// <p>Example: <code>my-cluster2</code></p>
166    pub fn set_new_db_cluster_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
167        self.inner = self.inner.set_new_db_cluster_identifier(input);
168        self
169    }
170    /// <p>The new cluster identifier for the cluster when renaming a cluster. This value is stored as a lowercase string.</p>
171    /// <p>Constraints:</p>
172    /// <ul>
173    /// <li>
174    /// <p>Must contain from 1 to 63 letters, numbers, or hyphens.</p></li>
175    /// <li>
176    /// <p>The first character must be a letter.</p></li>
177    /// <li>
178    /// <p>Cannot end with a hyphen or contain two consecutive hyphens.</p></li>
179    /// </ul>
180    /// <p>Example: <code>my-cluster2</code></p>
181    pub fn get_new_db_cluster_identifier(&self) -> &::std::option::Option<::std::string::String> {
182        self.inner.get_new_db_cluster_identifier()
183    }
184    /// <p>A value that specifies whether the changes in this request and any pending changes are asynchronously applied as soon as possible, regardless of the <code>PreferredMaintenanceWindow</code> setting for the cluster. If this parameter is set to <code>false</code>, changes to the cluster are applied during the next maintenance window.</p>
185    /// <p>The <code>ApplyImmediately</code> parameter affects only the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values. If you set this parameter value to <code>false</code>, the changes to the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values are applied during the next maintenance window. All other changes are applied immediately, regardless of the value of the <code>ApplyImmediately</code> parameter.</p>
186    /// <p>Default: <code>false</code></p>
187    pub fn apply_immediately(mut self, input: bool) -> Self {
188        self.inner = self.inner.apply_immediately(input);
189        self
190    }
191    /// <p>A value that specifies whether the changes in this request and any pending changes are asynchronously applied as soon as possible, regardless of the <code>PreferredMaintenanceWindow</code> setting for the cluster. If this parameter is set to <code>false</code>, changes to the cluster are applied during the next maintenance window.</p>
192    /// <p>The <code>ApplyImmediately</code> parameter affects only the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values. If you set this parameter value to <code>false</code>, the changes to the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values are applied during the next maintenance window. All other changes are applied immediately, regardless of the value of the <code>ApplyImmediately</code> parameter.</p>
193    /// <p>Default: <code>false</code></p>
194    pub fn set_apply_immediately(mut self, input: ::std::option::Option<bool>) -> Self {
195        self.inner = self.inner.set_apply_immediately(input);
196        self
197    }
198    /// <p>A value that specifies whether the changes in this request and any pending changes are asynchronously applied as soon as possible, regardless of the <code>PreferredMaintenanceWindow</code> setting for the cluster. If this parameter is set to <code>false</code>, changes to the cluster are applied during the next maintenance window.</p>
199    /// <p>The <code>ApplyImmediately</code> parameter affects only the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values. If you set this parameter value to <code>false</code>, the changes to the <code>NewDBClusterIdentifier</code> and <code>MasterUserPassword</code> values are applied during the next maintenance window. All other changes are applied immediately, regardless of the value of the <code>ApplyImmediately</code> parameter.</p>
200    /// <p>Default: <code>false</code></p>
201    pub fn get_apply_immediately(&self) -> &::std::option::Option<bool> {
202        self.inner.get_apply_immediately()
203    }
204    /// <p>The number of days for which automated backups are retained. You must specify a minimum value of 1.</p>
205    /// <p>Default: 1</p>
206    /// <p>Constraints:</p>
207    /// <ul>
208    /// <li>
209    /// <p>Must be a value from 1 to 35.</p></li>
210    /// </ul>
211    pub fn backup_retention_period(mut self, input: i32) -> Self {
212        self.inner = self.inner.backup_retention_period(input);
213        self
214    }
215    /// <p>The number of days for which automated backups are retained. You must specify a minimum value of 1.</p>
216    /// <p>Default: 1</p>
217    /// <p>Constraints:</p>
218    /// <ul>
219    /// <li>
220    /// <p>Must be a value from 1 to 35.</p></li>
221    /// </ul>
222    pub fn set_backup_retention_period(mut self, input: ::std::option::Option<i32>) -> Self {
223        self.inner = self.inner.set_backup_retention_period(input);
224        self
225    }
226    /// <p>The number of days for which automated backups are retained. You must specify a minimum value of 1.</p>
227    /// <p>Default: 1</p>
228    /// <p>Constraints:</p>
229    /// <ul>
230    /// <li>
231    /// <p>Must be a value from 1 to 35.</p></li>
232    /// </ul>
233    pub fn get_backup_retention_period(&self) -> &::std::option::Option<i32> {
234        self.inner.get_backup_retention_period()
235    }
236    /// <p>The name of the cluster parameter group to use for the cluster.</p>
237    pub fn db_cluster_parameter_group_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
238        self.inner = self.inner.db_cluster_parameter_group_name(input.into());
239        self
240    }
241    /// <p>The name of the cluster parameter group to use for the cluster.</p>
242    pub fn set_db_cluster_parameter_group_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
243        self.inner = self.inner.set_db_cluster_parameter_group_name(input);
244        self
245    }
246    /// <p>The name of the cluster parameter group to use for the cluster.</p>
247    pub fn get_db_cluster_parameter_group_name(&self) -> &::std::option::Option<::std::string::String> {
248        self.inner.get_db_cluster_parameter_group_name()
249    }
250    ///
251    /// Appends an item to `VpcSecurityGroupIds`.
252    ///
253    /// To override the contents of this collection use [`set_vpc_security_group_ids`](Self::set_vpc_security_group_ids).
254    ///
255    /// <p>A list of virtual private cloud (VPC) security groups that the cluster will belong to.</p>
256    pub fn vpc_security_group_ids(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
257        self.inner = self.inner.vpc_security_group_ids(input.into());
258        self
259    }
260    /// <p>A list of virtual private cloud (VPC) security groups that the cluster will belong to.</p>
261    pub fn set_vpc_security_group_ids(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
262        self.inner = self.inner.set_vpc_security_group_ids(input);
263        self
264    }
265    /// <p>A list of virtual private cloud (VPC) security groups that the cluster will belong to.</p>
266    pub fn get_vpc_security_group_ids(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
267        self.inner.get_vpc_security_group_ids()
268    }
269    /// <p>The port number on which the cluster accepts connections.</p>
270    /// <p>Constraints: Must be a value from <code>1150</code> to <code>65535</code>.</p>
271    /// <p>Default: The same port as the original cluster.</p>
272    pub fn port(mut self, input: i32) -> Self {
273        self.inner = self.inner.port(input);
274        self
275    }
276    /// <p>The port number on which the cluster accepts connections.</p>
277    /// <p>Constraints: Must be a value from <code>1150</code> to <code>65535</code>.</p>
278    /// <p>Default: The same port as the original cluster.</p>
279    pub fn set_port(mut self, input: ::std::option::Option<i32>) -> Self {
280        self.inner = self.inner.set_port(input);
281        self
282    }
283    /// <p>The port number on which the cluster accepts connections.</p>
284    /// <p>Constraints: Must be a value from <code>1150</code> to <code>65535</code>.</p>
285    /// <p>Default: The same port as the original cluster.</p>
286    pub fn get_port(&self) -> &::std::option::Option<i32> {
287        self.inner.get_port()
288    }
289    /// <p>The password for the master database user. This password can contain any printable ASCII character except forward slash (/), double quote ("), or the "at" symbol (@).</p>
290    /// <p>Constraints: Must contain from 8 to 100 characters.</p>
291    pub fn master_user_password(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
292        self.inner = self.inner.master_user_password(input.into());
293        self
294    }
295    /// <p>The password for the master database user. This password can contain any printable ASCII character except forward slash (/), double quote ("), or the "at" symbol (@).</p>
296    /// <p>Constraints: Must contain from 8 to 100 characters.</p>
297    pub fn set_master_user_password(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
298        self.inner = self.inner.set_master_user_password(input);
299        self
300    }
301    /// <p>The password for the master database user. This password can contain any printable ASCII character except forward slash (/), double quote ("), or the "at" symbol (@).</p>
302    /// <p>Constraints: Must contain from 8 to 100 characters.</p>
303    pub fn get_master_user_password(&self) -> &::std::option::Option<::std::string::String> {
304        self.inner.get_master_user_password()
305    }
306    /// <p>The daily time range during which automated backups are created if automated backups are enabled, using the <code>BackupRetentionPeriod</code> parameter.</p>
307    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region.</p>
308    /// <p>Constraints:</p>
309    /// <ul>
310    /// <li>
311    /// <p>Must be in the format <code>hh24:mi-hh24:mi</code>.</p></li>
312    /// <li>
313    /// <p>Must be in Universal Coordinated Time (UTC).</p></li>
314    /// <li>
315    /// <p>Must not conflict with the preferred maintenance window.</p></li>
316    /// <li>
317    /// <p>Must be at least 30 minutes.</p></li>
318    /// </ul>
319    pub fn preferred_backup_window(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
320        self.inner = self.inner.preferred_backup_window(input.into());
321        self
322    }
323    /// <p>The daily time range during which automated backups are created if automated backups are enabled, using the <code>BackupRetentionPeriod</code> parameter.</p>
324    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region.</p>
325    /// <p>Constraints:</p>
326    /// <ul>
327    /// <li>
328    /// <p>Must be in the format <code>hh24:mi-hh24:mi</code>.</p></li>
329    /// <li>
330    /// <p>Must be in Universal Coordinated Time (UTC).</p></li>
331    /// <li>
332    /// <p>Must not conflict with the preferred maintenance window.</p></li>
333    /// <li>
334    /// <p>Must be at least 30 minutes.</p></li>
335    /// </ul>
336    pub fn set_preferred_backup_window(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
337        self.inner = self.inner.set_preferred_backup_window(input);
338        self
339    }
340    /// <p>The daily time range during which automated backups are created if automated backups are enabled, using the <code>BackupRetentionPeriod</code> parameter.</p>
341    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region.</p>
342    /// <p>Constraints:</p>
343    /// <ul>
344    /// <li>
345    /// <p>Must be in the format <code>hh24:mi-hh24:mi</code>.</p></li>
346    /// <li>
347    /// <p>Must be in Universal Coordinated Time (UTC).</p></li>
348    /// <li>
349    /// <p>Must not conflict with the preferred maintenance window.</p></li>
350    /// <li>
351    /// <p>Must be at least 30 minutes.</p></li>
352    /// </ul>
353    pub fn get_preferred_backup_window(&self) -> &::std::option::Option<::std::string::String> {
354        self.inner.get_preferred_backup_window()
355    }
356    /// <p>The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).</p>
357    /// <p>Format: <code>ddd:hh24:mi-ddd:hh24:mi</code></p>
358    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region, occurring on a random day of the week.</p>
359    /// <p>Valid days: Mon, Tue, Wed, Thu, Fri, Sat, Sun</p>
360    /// <p>Constraints: Minimum 30-minute window.</p>
361    pub fn preferred_maintenance_window(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
362        self.inner = self.inner.preferred_maintenance_window(input.into());
363        self
364    }
365    /// <p>The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).</p>
366    /// <p>Format: <code>ddd:hh24:mi-ddd:hh24:mi</code></p>
367    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region, occurring on a random day of the week.</p>
368    /// <p>Valid days: Mon, Tue, Wed, Thu, Fri, Sat, Sun</p>
369    /// <p>Constraints: Minimum 30-minute window.</p>
370    pub fn set_preferred_maintenance_window(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
371        self.inner = self.inner.set_preferred_maintenance_window(input);
372        self
373    }
374    /// <p>The weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).</p>
375    /// <p>Format: <code>ddd:hh24:mi-ddd:hh24:mi</code></p>
376    /// <p>The default is a 30-minute window selected at random from an 8-hour block of time for each Amazon Web Services Region, occurring on a random day of the week.</p>
377    /// <p>Valid days: Mon, Tue, Wed, Thu, Fri, Sat, Sun</p>
378    /// <p>Constraints: Minimum 30-minute window.</p>
379    pub fn get_preferred_maintenance_window(&self) -> &::std::option::Option<::std::string::String> {
380        self.inner.get_preferred_maintenance_window()
381    }
382    /// <p>The configuration setting for the log types to be enabled for export to Amazon CloudWatch Logs for a specific instance or cluster. The <code>EnableLogTypes</code> and <code>DisableLogTypes</code> arrays determine which logs are exported (or not exported) to CloudWatch Logs.</p>
383    pub fn cloudwatch_logs_export_configuration(mut self, input: crate::types::CloudwatchLogsExportConfiguration) -> Self {
384        self.inner = self.inner.cloudwatch_logs_export_configuration(input);
385        self
386    }
387    /// <p>The configuration setting for the log types to be enabled for export to Amazon CloudWatch Logs for a specific instance or cluster. The <code>EnableLogTypes</code> and <code>DisableLogTypes</code> arrays determine which logs are exported (or not exported) to CloudWatch Logs.</p>
388    pub fn set_cloudwatch_logs_export_configuration(mut self, input: ::std::option::Option<crate::types::CloudwatchLogsExportConfiguration>) -> Self {
389        self.inner = self.inner.set_cloudwatch_logs_export_configuration(input);
390        self
391    }
392    /// <p>The configuration setting for the log types to be enabled for export to Amazon CloudWatch Logs for a specific instance or cluster. The <code>EnableLogTypes</code> and <code>DisableLogTypes</code> arrays determine which logs are exported (or not exported) to CloudWatch Logs.</p>
393    pub fn get_cloudwatch_logs_export_configuration(&self) -> &::std::option::Option<crate::types::CloudwatchLogsExportConfiguration> {
394        self.inner.get_cloudwatch_logs_export_configuration()
395    }
396    /// <p>The version number of the database engine to which you want to upgrade. Changing this parameter results in an outage. The change is applied during the next maintenance window unless <code>ApplyImmediately</code> is enabled.</p>
397    /// <p>To list all of the available engine versions for Amazon DocumentDB use the following command:</p>
398    /// <p><code>aws docdb describe-db-engine-versions --engine docdb --query "DBEngineVersions\[\].EngineVersion"</code></p>
399    pub fn engine_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
400        self.inner = self.inner.engine_version(input.into());
401        self
402    }
403    /// <p>The version number of the database engine to which you want to upgrade. Changing this parameter results in an outage. The change is applied during the next maintenance window unless <code>ApplyImmediately</code> is enabled.</p>
404    /// <p>To list all of the available engine versions for Amazon DocumentDB use the following command:</p>
405    /// <p><code>aws docdb describe-db-engine-versions --engine docdb --query "DBEngineVersions\[\].EngineVersion"</code></p>
406    pub fn set_engine_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
407        self.inner = self.inner.set_engine_version(input);
408        self
409    }
410    /// <p>The version number of the database engine to which you want to upgrade. Changing this parameter results in an outage. The change is applied during the next maintenance window unless <code>ApplyImmediately</code> is enabled.</p>
411    /// <p>To list all of the available engine versions for Amazon DocumentDB use the following command:</p>
412    /// <p><code>aws docdb describe-db-engine-versions --engine docdb --query "DBEngineVersions\[\].EngineVersion"</code></p>
413    pub fn get_engine_version(&self) -> &::std::option::Option<::std::string::String> {
414        self.inner.get_engine_version()
415    }
416    /// <p>A value that indicates whether major version upgrades are allowed.</p>
417    /// <p>Constraints:</p>
418    /// <ul>
419    /// <li>
420    /// <p>You must allow major version upgrades when specifying a value for the <code>EngineVersion</code> parameter that is a different major version than the cluster's current version.</p></li>
421    /// <li>
422    /// <p>Since some parameters are version specific, changing them requires executing a new <code>ModifyDBCluster</code> API call after the in-place MVU completes.</p></li>
423    /// </ul><note>
424    /// <p>Performing an MVU directly impacts the following parameters:</p>
425    /// <ul>
426    /// <li>
427    /// <p><code>MasterUserPassword</code></p></li>
428    /// <li>
429    /// <p><code>NewDBClusterIdentifier</code></p></li>
430    /// <li>
431    /// <p><code>VpcSecurityGroupIds</code></p></li>
432    /// <li>
433    /// <p><code>Port</code></p></li>
434    /// </ul>
435    /// </note>
436    pub fn allow_major_version_upgrade(mut self, input: bool) -> Self {
437        self.inner = self.inner.allow_major_version_upgrade(input);
438        self
439    }
440    /// <p>A value that indicates whether major version upgrades are allowed.</p>
441    /// <p>Constraints:</p>
442    /// <ul>
443    /// <li>
444    /// <p>You must allow major version upgrades when specifying a value for the <code>EngineVersion</code> parameter that is a different major version than the cluster's current version.</p></li>
445    /// <li>
446    /// <p>Since some parameters are version specific, changing them requires executing a new <code>ModifyDBCluster</code> API call after the in-place MVU completes.</p></li>
447    /// </ul><note>
448    /// <p>Performing an MVU directly impacts the following parameters:</p>
449    /// <ul>
450    /// <li>
451    /// <p><code>MasterUserPassword</code></p></li>
452    /// <li>
453    /// <p><code>NewDBClusterIdentifier</code></p></li>
454    /// <li>
455    /// <p><code>VpcSecurityGroupIds</code></p></li>
456    /// <li>
457    /// <p><code>Port</code></p></li>
458    /// </ul>
459    /// </note>
460    pub fn set_allow_major_version_upgrade(mut self, input: ::std::option::Option<bool>) -> Self {
461        self.inner = self.inner.set_allow_major_version_upgrade(input);
462        self
463    }
464    /// <p>A value that indicates whether major version upgrades are allowed.</p>
465    /// <p>Constraints:</p>
466    /// <ul>
467    /// <li>
468    /// <p>You must allow major version upgrades when specifying a value for the <code>EngineVersion</code> parameter that is a different major version than the cluster's current version.</p></li>
469    /// <li>
470    /// <p>Since some parameters are version specific, changing them requires executing a new <code>ModifyDBCluster</code> API call after the in-place MVU completes.</p></li>
471    /// </ul><note>
472    /// <p>Performing an MVU directly impacts the following parameters:</p>
473    /// <ul>
474    /// <li>
475    /// <p><code>MasterUserPassword</code></p></li>
476    /// <li>
477    /// <p><code>NewDBClusterIdentifier</code></p></li>
478    /// <li>
479    /// <p><code>VpcSecurityGroupIds</code></p></li>
480    /// <li>
481    /// <p><code>Port</code></p></li>
482    /// </ul>
483    /// </note>
484    pub fn get_allow_major_version_upgrade(&self) -> &::std::option::Option<bool> {
485        self.inner.get_allow_major_version_upgrade()
486    }
487    /// <p>Specifies whether this cluster can be deleted. If <code>DeletionProtection</code> is enabled, the cluster cannot be deleted unless it is modified and <code>DeletionProtection</code> is disabled. <code>DeletionProtection</code> protects clusters from being accidentally deleted.</p>
488    pub fn deletion_protection(mut self, input: bool) -> Self {
489        self.inner = self.inner.deletion_protection(input);
490        self
491    }
492    /// <p>Specifies whether this cluster can be deleted. If <code>DeletionProtection</code> is enabled, the cluster cannot be deleted unless it is modified and <code>DeletionProtection</code> is disabled. <code>DeletionProtection</code> protects clusters from being accidentally deleted.</p>
493    pub fn set_deletion_protection(mut self, input: ::std::option::Option<bool>) -> Self {
494        self.inner = self.inner.set_deletion_protection(input);
495        self
496    }
497    /// <p>Specifies whether this cluster can be deleted. If <code>DeletionProtection</code> is enabled, the cluster cannot be deleted unless it is modified and <code>DeletionProtection</code> is disabled. <code>DeletionProtection</code> protects clusters from being accidentally deleted.</p>
498    pub fn get_deletion_protection(&self) -> &::std::option::Option<bool> {
499        self.inner.get_deletion_protection()
500    }
501    /// <p>The storage type to associate with the DB cluster.</p>
502    /// <p>For information on storage types for Amazon DocumentDB clusters, see Cluster storage configurations in the <i>Amazon DocumentDB Developer Guide</i>.</p>
503    /// <p>Valid values for storage type - <code>standard | iopt1</code></p>
504    /// <p>Default value is <code>standard </code></p>
505    pub fn storage_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
506        self.inner = self.inner.storage_type(input.into());
507        self
508    }
509    /// <p>The storage type to associate with the DB cluster.</p>
510    /// <p>For information on storage types for Amazon DocumentDB clusters, see Cluster storage configurations in the <i>Amazon DocumentDB Developer Guide</i>.</p>
511    /// <p>Valid values for storage type - <code>standard | iopt1</code></p>
512    /// <p>Default value is <code>standard </code></p>
513    pub fn set_storage_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
514        self.inner = self.inner.set_storage_type(input);
515        self
516    }
517    /// <p>The storage type to associate with the DB cluster.</p>
518    /// <p>For information on storage types for Amazon DocumentDB clusters, see Cluster storage configurations in the <i>Amazon DocumentDB Developer Guide</i>.</p>
519    /// <p>Valid values for storage type - <code>standard | iopt1</code></p>
520    /// <p>Default value is <code>standard </code></p>
521    pub fn get_storage_type(&self) -> &::std::option::Option<::std::string::String> {
522        self.inner.get_storage_type()
523    }
524    /// <p>Contains the scaling configuration of an Amazon DocumentDB Serverless cluster.</p>
525    pub fn serverless_v2_scaling_configuration(mut self, input: crate::types::ServerlessV2ScalingConfiguration) -> Self {
526        self.inner = self.inner.serverless_v2_scaling_configuration(input);
527        self
528    }
529    /// <p>Contains the scaling configuration of an Amazon DocumentDB Serverless cluster.</p>
530    pub fn set_serverless_v2_scaling_configuration(mut self, input: ::std::option::Option<crate::types::ServerlessV2ScalingConfiguration>) -> Self {
531        self.inner = self.inner.set_serverless_v2_scaling_configuration(input);
532        self
533    }
534    /// <p>Contains the scaling configuration of an Amazon DocumentDB Serverless cluster.</p>
535    pub fn get_serverless_v2_scaling_configuration(&self) -> &::std::option::Option<crate::types::ServerlessV2ScalingConfiguration> {
536        self.inner.get_serverless_v2_scaling_configuration()
537    }
538    /// <p>Specifies whether to manage the master user password with Amazon Web Services Secrets Manager. If the cluster doesn't manage the master user password with Amazon Web Services Secrets Manager, you can turn on this management. In this case, you can't specify <code>MasterUserPassword</code>. If the cluster already manages the master user password with Amazon Web Services Secrets Manager, and you specify that the master user password is not managed with Amazon Web Services Secrets Manager, then you must specify <code>MasterUserPassword</code>. In this case, Amazon DocumentDB deletes the secret and uses the new password for the master user specified by <code>MasterUserPassword</code>.</p>
539    pub fn manage_master_user_password(mut self, input: bool) -> Self {
540        self.inner = self.inner.manage_master_user_password(input);
541        self
542    }
543    /// <p>Specifies whether to manage the master user password with Amazon Web Services Secrets Manager. If the cluster doesn't manage the master user password with Amazon Web Services Secrets Manager, you can turn on this management. In this case, you can't specify <code>MasterUserPassword</code>. If the cluster already manages the master user password with Amazon Web Services Secrets Manager, and you specify that the master user password is not managed with Amazon Web Services Secrets Manager, then you must specify <code>MasterUserPassword</code>. In this case, Amazon DocumentDB deletes the secret and uses the new password for the master user specified by <code>MasterUserPassword</code>.</p>
544    pub fn set_manage_master_user_password(mut self, input: ::std::option::Option<bool>) -> Self {
545        self.inner = self.inner.set_manage_master_user_password(input);
546        self
547    }
548    /// <p>Specifies whether to manage the master user password with Amazon Web Services Secrets Manager. If the cluster doesn't manage the master user password with Amazon Web Services Secrets Manager, you can turn on this management. In this case, you can't specify <code>MasterUserPassword</code>. If the cluster already manages the master user password with Amazon Web Services Secrets Manager, and you specify that the master user password is not managed with Amazon Web Services Secrets Manager, then you must specify <code>MasterUserPassword</code>. In this case, Amazon DocumentDB deletes the secret and uses the new password for the master user specified by <code>MasterUserPassword</code>.</p>
549    pub fn get_manage_master_user_password(&self) -> &::std::option::Option<bool> {
550        self.inner.get_manage_master_user_password()
551    }
552    /// <p>The Amazon Web Services KMS key identifier to encrypt a secret that is automatically generated and managed in Amazon Web Services Secrets Manager.</p>
553    /// <p>This setting is valid only if both of the following conditions are met:</p>
554    /// <ul>
555    /// <li>
556    /// <p>The cluster doesn't manage the master user password in Amazon Web Services Secrets Manager. If the cluster already manages the master user password in Amazon Web Services Secrets Manager, you can't change the KMS key that is used to encrypt the secret.</p></li>
557    /// <li>
558    /// <p>You are enabling <code>ManageMasterUserPassword</code> to manage the master user password in Amazon Web Services Secrets Manager. If you are turning on <code>ManageMasterUserPassword</code> and don't specify <code>MasterUserSecretKmsKeyId</code>, then the <code>aws/secretsmanager</code> KMS key is used to encrypt the secret. If the secret is in a different Amazon Web Services account, then you can't use the <code>aws/secretsmanager</code> KMS key to encrypt the secret, and you must use a customer managed KMS key.</p></li>
559    /// </ul>
560    /// <p>The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. To use a KMS key in a different Amazon Web Services account, specify the key ARN or alias ARN.</p>
561    /// <p>There is a default KMS key for your Amazon Web Services account. Your Amazon Web Services account has a different default KMS key for each Amazon Web Services Region.</p>
562    pub fn master_user_secret_kms_key_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
563        self.inner = self.inner.master_user_secret_kms_key_id(input.into());
564        self
565    }
566    /// <p>The Amazon Web Services KMS key identifier to encrypt a secret that is automatically generated and managed in Amazon Web Services Secrets Manager.</p>
567    /// <p>This setting is valid only if both of the following conditions are met:</p>
568    /// <ul>
569    /// <li>
570    /// <p>The cluster doesn't manage the master user password in Amazon Web Services Secrets Manager. If the cluster already manages the master user password in Amazon Web Services Secrets Manager, you can't change the KMS key that is used to encrypt the secret.</p></li>
571    /// <li>
572    /// <p>You are enabling <code>ManageMasterUserPassword</code> to manage the master user password in Amazon Web Services Secrets Manager. If you are turning on <code>ManageMasterUserPassword</code> and don't specify <code>MasterUserSecretKmsKeyId</code>, then the <code>aws/secretsmanager</code> KMS key is used to encrypt the secret. If the secret is in a different Amazon Web Services account, then you can't use the <code>aws/secretsmanager</code> KMS key to encrypt the secret, and you must use a customer managed KMS key.</p></li>
573    /// </ul>
574    /// <p>The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. To use a KMS key in a different Amazon Web Services account, specify the key ARN or alias ARN.</p>
575    /// <p>There is a default KMS key for your Amazon Web Services account. Your Amazon Web Services account has a different default KMS key for each Amazon Web Services Region.</p>
576    pub fn set_master_user_secret_kms_key_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
577        self.inner = self.inner.set_master_user_secret_kms_key_id(input);
578        self
579    }
580    /// <p>The Amazon Web Services KMS key identifier to encrypt a secret that is automatically generated and managed in Amazon Web Services Secrets Manager.</p>
581    /// <p>This setting is valid only if both of the following conditions are met:</p>
582    /// <ul>
583    /// <li>
584    /// <p>The cluster doesn't manage the master user password in Amazon Web Services Secrets Manager. If the cluster already manages the master user password in Amazon Web Services Secrets Manager, you can't change the KMS key that is used to encrypt the secret.</p></li>
585    /// <li>
586    /// <p>You are enabling <code>ManageMasterUserPassword</code> to manage the master user password in Amazon Web Services Secrets Manager. If you are turning on <code>ManageMasterUserPassword</code> and don't specify <code>MasterUserSecretKmsKeyId</code>, then the <code>aws/secretsmanager</code> KMS key is used to encrypt the secret. If the secret is in a different Amazon Web Services account, then you can't use the <code>aws/secretsmanager</code> KMS key to encrypt the secret, and you must use a customer managed KMS key.</p></li>
587    /// </ul>
588    /// <p>The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key. To use a KMS key in a different Amazon Web Services account, specify the key ARN or alias ARN.</p>
589    /// <p>There is a default KMS key for your Amazon Web Services account. Your Amazon Web Services account has a different default KMS key for each Amazon Web Services Region.</p>
590    pub fn get_master_user_secret_kms_key_id(&self) -> &::std::option::Option<::std::string::String> {
591        self.inner.get_master_user_secret_kms_key_id()
592    }
593    /// <p>Specifies whether to rotate the secret managed by Amazon Web Services Secrets Manager for the master user password.</p>
594    /// <p>This setting is valid only if the master user password is managed by Amazon DocumentDB in Amazon Web Services Secrets Manager for the cluster. The secret value contains the updated password.</p>
595    /// <p>Constraint: You must apply the change immediately when rotating the master user password.</p>
596    pub fn rotate_master_user_password(mut self, input: bool) -> Self {
597        self.inner = self.inner.rotate_master_user_password(input);
598        self
599    }
600    /// <p>Specifies whether to rotate the secret managed by Amazon Web Services Secrets Manager for the master user password.</p>
601    /// <p>This setting is valid only if the master user password is managed by Amazon DocumentDB in Amazon Web Services Secrets Manager for the cluster. The secret value contains the updated password.</p>
602    /// <p>Constraint: You must apply the change immediately when rotating the master user password.</p>
603    pub fn set_rotate_master_user_password(mut self, input: ::std::option::Option<bool>) -> Self {
604        self.inner = self.inner.set_rotate_master_user_password(input);
605        self
606    }
607    /// <p>Specifies whether to rotate the secret managed by Amazon Web Services Secrets Manager for the master user password.</p>
608    /// <p>This setting is valid only if the master user password is managed by Amazon DocumentDB in Amazon Web Services Secrets Manager for the cluster. The secret value contains the updated password.</p>
609    /// <p>Constraint: You must apply the change immediately when rotating the master user password.</p>
610    pub fn get_rotate_master_user_password(&self) -> &::std::option::Option<bool> {
611        self.inner.get_rotate_master_user_password()
612    }
613    /// <p>The network type of the cluster.</p>
614    /// <p>The network type is determined by the <code>DBSubnetGroup</code> specified for the cluster. A <code>DBSubnetGroup</code> can support only the IPv4 protocol or the IPv4 and the IPv6 protocols (<code>DUAL</code>).</p>
615    /// <p>For more information, see <a href="https://docs.aws.amazon.com/documentdb/latest/developerguide/vpc-clusters.html">DocumentDB clusters in a VPC</a> in the Amazon DocumentDB Developer Guide.</p>
616    /// <p>Valid Values: <code>IPV4</code> | <code>DUAL</code></p>
617    pub fn network_type(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
618        self.inner = self.inner.network_type(input.into());
619        self
620    }
621    /// <p>The network type of the cluster.</p>
622    /// <p>The network type is determined by the <code>DBSubnetGroup</code> specified for the cluster. A <code>DBSubnetGroup</code> can support only the IPv4 protocol or the IPv4 and the IPv6 protocols (<code>DUAL</code>).</p>
623    /// <p>For more information, see <a href="https://docs.aws.amazon.com/documentdb/latest/developerguide/vpc-clusters.html">DocumentDB clusters in a VPC</a> in the Amazon DocumentDB Developer Guide.</p>
624    /// <p>Valid Values: <code>IPV4</code> | <code>DUAL</code></p>
625    pub fn set_network_type(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
626        self.inner = self.inner.set_network_type(input);
627        self
628    }
629    /// <p>The network type of the cluster.</p>
630    /// <p>The network type is determined by the <code>DBSubnetGroup</code> specified for the cluster. A <code>DBSubnetGroup</code> can support only the IPv4 protocol or the IPv4 and the IPv6 protocols (<code>DUAL</code>).</p>
631    /// <p>For more information, see <a href="https://docs.aws.amazon.com/documentdb/latest/developerguide/vpc-clusters.html">DocumentDB clusters in a VPC</a> in the Amazon DocumentDB Developer Guide.</p>
632    /// <p>Valid Values: <code>IPV4</code> | <code>DUAL</code></p>
633    pub fn get_network_type(&self) -> &::std::option::Option<::std::string::String> {
634        self.inner.get_network_type()
635    }
636}