aws-sdk-dlm 1.99.0

AWS SDK for Amazon Data Lifecycle Manager
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p><b>\[Custom snapshot policies that target instances only\]</b> Information about pre and/or post scripts for a snapshot lifecycle policy that targets instances. For more information, see <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/automate-app-consistent-backups.html"> Automating application-consistent snapshots with pre and post scripts</a>.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Script {
    /// <p>Indicate which scripts Amazon Data Lifecycle Manager should run on target instances. Pre scripts run before Amazon Data Lifecycle Manager initiates snapshot creation. Post scripts run after Amazon Data Lifecycle Manager initiates snapshot creation.</p>
    /// <ul>
    /// <li>
    /// <p>To run a pre script only, specify <code>PRE</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run a post script only, specify <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run both pre and post scripts, specify both <code>PRE</code> and <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation, and then it calls the SSM document again with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// </ul>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: PRE and POST</p>
    pub stages: ::std::option::Option<::std::vec::Vec<crate::types::StageValues>>,
    /// <p>Indicates the service used to execute the pre and/or post scripts.</p>
    /// <ul>
    /// <li>
    /// <p>If you are using custom SSM documents or automating application-consistent snapshots of SAP HANA workloads, specify <code>AWS_SYSTEMS_MANAGER</code>.</p></li>
    /// <li>
    /// <p>If you are automating VSS Backups, omit this parameter.</p></li>
    /// </ul>
    /// <p>Default: AWS_SYSTEMS_MANAGER</p>
    pub execution_handler_service: ::std::option::Option<crate::types::ExecutionHandlerServiceValues>,
    /// <p>The SSM document that includes the pre and/or post scripts to run.</p>
    /// <ul>
    /// <li>
    /// <p>If you are automating VSS backups, specify <code>AWS_VSS_BACKUP</code>. In this case, Amazon Data Lifecycle Manager automatically uses the <code>AWSEC2-CreateVssSnapshot</code> SSM document.</p></li>
    /// <li>
    /// <p>If you are automating application-consistent snapshots for SAP HANA workloads, specify <code>AWSSystemsManagerSAP-CreateDLMSnapshotForSAPHANA</code>.</p></li>
    /// <li>
    /// <p>If you are using a custom SSM document that you own, specify either the name or ARN of the SSM document. If you are using a custom SSM document that is shared with you, specify the ARN of the SSM document.</p></li>
    /// </ul>
    pub execution_handler: ::std::option::Option<::std::string::String>,
    /// <p>Indicates whether Amazon Data Lifecycle Manager should default to crash-consistent snapshots if the pre script fails.</p>
    /// <ul>
    /// <li>
    /// <p>To default to crash consistent snapshot if the pre script fails, specify <code>true</code>.</p></li>
    /// <li>
    /// <p>To skip the instance for snapshot creation if the pre script fails, specify <code>false</code>.</p></li>
    /// </ul>
    /// <p>This parameter is supported only if you run a pre script. If you run a post script only, omit this parameter.</p>
    /// <p>Default: true</p>
    pub execute_operation_on_script_failure: ::std::option::Option<bool>,
    /// <p>Specifies a timeout period, in seconds, after which Amazon Data Lifecycle Manager fails the script run attempt if it has not completed. If a script does not complete within its timeout period, Amazon Data Lifecycle Manager fails the attempt. The timeout period applies to the pre and post scripts individually.</p>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: 10</p>
    pub execution_timeout: ::std::option::Option<i32>,
    /// <p>Specifies the number of times Amazon Data Lifecycle Manager should retry scripts that fail.</p>
    /// <ul>
    /// <li>
    /// <p>If the pre script fails, Amazon Data Lifecycle Manager retries the entire snapshot creation process, including running the pre and post scripts.</p></li>
    /// <li>
    /// <p>If the post script fails, Amazon Data Lifecycle Manager retries the post script only; in this case, the pre script will have completed and the snapshot might have been created.</p></li>
    /// </ul>
    /// <p>If you do not want Amazon Data Lifecycle Manager to retry failed scripts, specify <code>0</code>.</p>
    /// <p>Default: 0</p>
    pub maximum_retry_count: ::std::option::Option<i32>,
}
impl Script {
    /// <p>Indicate which scripts Amazon Data Lifecycle Manager should run on target instances. Pre scripts run before Amazon Data Lifecycle Manager initiates snapshot creation. Post scripts run after Amazon Data Lifecycle Manager initiates snapshot creation.</p>
    /// <ul>
    /// <li>
    /// <p>To run a pre script only, specify <code>PRE</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run a post script only, specify <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run both pre and post scripts, specify both <code>PRE</code> and <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation, and then it calls the SSM document again with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// </ul>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: PRE and POST</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.stages.is_none()`.
    pub fn stages(&self) -> &[crate::types::StageValues] {
        self.stages.as_deref().unwrap_or_default()
    }
    /// <p>Indicates the service used to execute the pre and/or post scripts.</p>
    /// <ul>
    /// <li>
    /// <p>If you are using custom SSM documents or automating application-consistent snapshots of SAP HANA workloads, specify <code>AWS_SYSTEMS_MANAGER</code>.</p></li>
    /// <li>
    /// <p>If you are automating VSS Backups, omit this parameter.</p></li>
    /// </ul>
    /// <p>Default: AWS_SYSTEMS_MANAGER</p>
    pub fn execution_handler_service(&self) -> ::std::option::Option<&crate::types::ExecutionHandlerServiceValues> {
        self.execution_handler_service.as_ref()
    }
    /// <p>The SSM document that includes the pre and/or post scripts to run.</p>
    /// <ul>
    /// <li>
    /// <p>If you are automating VSS backups, specify <code>AWS_VSS_BACKUP</code>. In this case, Amazon Data Lifecycle Manager automatically uses the <code>AWSEC2-CreateVssSnapshot</code> SSM document.</p></li>
    /// <li>
    /// <p>If you are automating application-consistent snapshots for SAP HANA workloads, specify <code>AWSSystemsManagerSAP-CreateDLMSnapshotForSAPHANA</code>.</p></li>
    /// <li>
    /// <p>If you are using a custom SSM document that you own, specify either the name or ARN of the SSM document. If you are using a custom SSM document that is shared with you, specify the ARN of the SSM document.</p></li>
    /// </ul>
    pub fn execution_handler(&self) -> ::std::option::Option<&str> {
        self.execution_handler.as_deref()
    }
    /// <p>Indicates whether Amazon Data Lifecycle Manager should default to crash-consistent snapshots if the pre script fails.</p>
    /// <ul>
    /// <li>
    /// <p>To default to crash consistent snapshot if the pre script fails, specify <code>true</code>.</p></li>
    /// <li>
    /// <p>To skip the instance for snapshot creation if the pre script fails, specify <code>false</code>.</p></li>
    /// </ul>
    /// <p>This parameter is supported only if you run a pre script. If you run a post script only, omit this parameter.</p>
    /// <p>Default: true</p>
    pub fn execute_operation_on_script_failure(&self) -> ::std::option::Option<bool> {
        self.execute_operation_on_script_failure
    }
    /// <p>Specifies a timeout period, in seconds, after which Amazon Data Lifecycle Manager fails the script run attempt if it has not completed. If a script does not complete within its timeout period, Amazon Data Lifecycle Manager fails the attempt. The timeout period applies to the pre and post scripts individually.</p>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: 10</p>
    pub fn execution_timeout(&self) -> ::std::option::Option<i32> {
        self.execution_timeout
    }
    /// <p>Specifies the number of times Amazon Data Lifecycle Manager should retry scripts that fail.</p>
    /// <ul>
    /// <li>
    /// <p>If the pre script fails, Amazon Data Lifecycle Manager retries the entire snapshot creation process, including running the pre and post scripts.</p></li>
    /// <li>
    /// <p>If the post script fails, Amazon Data Lifecycle Manager retries the post script only; in this case, the pre script will have completed and the snapshot might have been created.</p></li>
    /// </ul>
    /// <p>If you do not want Amazon Data Lifecycle Manager to retry failed scripts, specify <code>0</code>.</p>
    /// <p>Default: 0</p>
    pub fn maximum_retry_count(&self) -> ::std::option::Option<i32> {
        self.maximum_retry_count
    }
}
impl Script {
    /// Creates a new builder-style object to manufacture [`Script`](crate::types::Script).
    pub fn builder() -> crate::types::builders::ScriptBuilder {
        crate::types::builders::ScriptBuilder::default()
    }
}

/// A builder for [`Script`](crate::types::Script).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ScriptBuilder {
    pub(crate) stages: ::std::option::Option<::std::vec::Vec<crate::types::StageValues>>,
    pub(crate) execution_handler_service: ::std::option::Option<crate::types::ExecutionHandlerServiceValues>,
    pub(crate) execution_handler: ::std::option::Option<::std::string::String>,
    pub(crate) execute_operation_on_script_failure: ::std::option::Option<bool>,
    pub(crate) execution_timeout: ::std::option::Option<i32>,
    pub(crate) maximum_retry_count: ::std::option::Option<i32>,
}
impl ScriptBuilder {
    /// Appends an item to `stages`.
    ///
    /// To override the contents of this collection use [`set_stages`](Self::set_stages).
    ///
    /// <p>Indicate which scripts Amazon Data Lifecycle Manager should run on target instances. Pre scripts run before Amazon Data Lifecycle Manager initiates snapshot creation. Post scripts run after Amazon Data Lifecycle Manager initiates snapshot creation.</p>
    /// <ul>
    /// <li>
    /// <p>To run a pre script only, specify <code>PRE</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run a post script only, specify <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run both pre and post scripts, specify both <code>PRE</code> and <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation, and then it calls the SSM document again with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// </ul>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: PRE and POST</p>
    pub fn stages(mut self, input: crate::types::StageValues) -> Self {
        let mut v = self.stages.unwrap_or_default();
        v.push(input);
        self.stages = ::std::option::Option::Some(v);
        self
    }
    /// <p>Indicate which scripts Amazon Data Lifecycle Manager should run on target instances. Pre scripts run before Amazon Data Lifecycle Manager initiates snapshot creation. Post scripts run after Amazon Data Lifecycle Manager initiates snapshot creation.</p>
    /// <ul>
    /// <li>
    /// <p>To run a pre script only, specify <code>PRE</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run a post script only, specify <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run both pre and post scripts, specify both <code>PRE</code> and <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation, and then it calls the SSM document again with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// </ul>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: PRE and POST</p>
    pub fn set_stages(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::StageValues>>) -> Self {
        self.stages = input;
        self
    }
    /// <p>Indicate which scripts Amazon Data Lifecycle Manager should run on target instances. Pre scripts run before Amazon Data Lifecycle Manager initiates snapshot creation. Post scripts run after Amazon Data Lifecycle Manager initiates snapshot creation.</p>
    /// <ul>
    /// <li>
    /// <p>To run a pre script only, specify <code>PRE</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run a post script only, specify <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// <li>
    /// <p>To run both pre and post scripts, specify both <code>PRE</code> and <code>POST</code>. In this case, Amazon Data Lifecycle Manager calls the SSM document with the <code>pre-script</code> parameter before initiating snapshot creation, and then it calls the SSM document again with the <code>post-script</code> parameter after initiating snapshot creation.</p></li>
    /// </ul>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: PRE and POST</p>
    pub fn get_stages(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::StageValues>> {
        &self.stages
    }
    /// <p>Indicates the service used to execute the pre and/or post scripts.</p>
    /// <ul>
    /// <li>
    /// <p>If you are using custom SSM documents or automating application-consistent snapshots of SAP HANA workloads, specify <code>AWS_SYSTEMS_MANAGER</code>.</p></li>
    /// <li>
    /// <p>If you are automating VSS Backups, omit this parameter.</p></li>
    /// </ul>
    /// <p>Default: AWS_SYSTEMS_MANAGER</p>
    pub fn execution_handler_service(mut self, input: crate::types::ExecutionHandlerServiceValues) -> Self {
        self.execution_handler_service = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates the service used to execute the pre and/or post scripts.</p>
    /// <ul>
    /// <li>
    /// <p>If you are using custom SSM documents or automating application-consistent snapshots of SAP HANA workloads, specify <code>AWS_SYSTEMS_MANAGER</code>.</p></li>
    /// <li>
    /// <p>If you are automating VSS Backups, omit this parameter.</p></li>
    /// </ul>
    /// <p>Default: AWS_SYSTEMS_MANAGER</p>
    pub fn set_execution_handler_service(mut self, input: ::std::option::Option<crate::types::ExecutionHandlerServiceValues>) -> Self {
        self.execution_handler_service = input;
        self
    }
    /// <p>Indicates the service used to execute the pre and/or post scripts.</p>
    /// <ul>
    /// <li>
    /// <p>If you are using custom SSM documents or automating application-consistent snapshots of SAP HANA workloads, specify <code>AWS_SYSTEMS_MANAGER</code>.</p></li>
    /// <li>
    /// <p>If you are automating VSS Backups, omit this parameter.</p></li>
    /// </ul>
    /// <p>Default: AWS_SYSTEMS_MANAGER</p>
    pub fn get_execution_handler_service(&self) -> &::std::option::Option<crate::types::ExecutionHandlerServiceValues> {
        &self.execution_handler_service
    }
    /// <p>The SSM document that includes the pre and/or post scripts to run.</p>
    /// <ul>
    /// <li>
    /// <p>If you are automating VSS backups, specify <code>AWS_VSS_BACKUP</code>. In this case, Amazon Data Lifecycle Manager automatically uses the <code>AWSEC2-CreateVssSnapshot</code> SSM document.</p></li>
    /// <li>
    /// <p>If you are automating application-consistent snapshots for SAP HANA workloads, specify <code>AWSSystemsManagerSAP-CreateDLMSnapshotForSAPHANA</code>.</p></li>
    /// <li>
    /// <p>If you are using a custom SSM document that you own, specify either the name or ARN of the SSM document. If you are using a custom SSM document that is shared with you, specify the ARN of the SSM document.</p></li>
    /// </ul>
    /// This field is required.
    pub fn execution_handler(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.execution_handler = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The SSM document that includes the pre and/or post scripts to run.</p>
    /// <ul>
    /// <li>
    /// <p>If you are automating VSS backups, specify <code>AWS_VSS_BACKUP</code>. In this case, Amazon Data Lifecycle Manager automatically uses the <code>AWSEC2-CreateVssSnapshot</code> SSM document.</p></li>
    /// <li>
    /// <p>If you are automating application-consistent snapshots for SAP HANA workloads, specify <code>AWSSystemsManagerSAP-CreateDLMSnapshotForSAPHANA</code>.</p></li>
    /// <li>
    /// <p>If you are using a custom SSM document that you own, specify either the name or ARN of the SSM document. If you are using a custom SSM document that is shared with you, specify the ARN of the SSM document.</p></li>
    /// </ul>
    pub fn set_execution_handler(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.execution_handler = input;
        self
    }
    /// <p>The SSM document that includes the pre and/or post scripts to run.</p>
    /// <ul>
    /// <li>
    /// <p>If you are automating VSS backups, specify <code>AWS_VSS_BACKUP</code>. In this case, Amazon Data Lifecycle Manager automatically uses the <code>AWSEC2-CreateVssSnapshot</code> SSM document.</p></li>
    /// <li>
    /// <p>If you are automating application-consistent snapshots for SAP HANA workloads, specify <code>AWSSystemsManagerSAP-CreateDLMSnapshotForSAPHANA</code>.</p></li>
    /// <li>
    /// <p>If you are using a custom SSM document that you own, specify either the name or ARN of the SSM document. If you are using a custom SSM document that is shared with you, specify the ARN of the SSM document.</p></li>
    /// </ul>
    pub fn get_execution_handler(&self) -> &::std::option::Option<::std::string::String> {
        &self.execution_handler
    }
    /// <p>Indicates whether Amazon Data Lifecycle Manager should default to crash-consistent snapshots if the pre script fails.</p>
    /// <ul>
    /// <li>
    /// <p>To default to crash consistent snapshot if the pre script fails, specify <code>true</code>.</p></li>
    /// <li>
    /// <p>To skip the instance for snapshot creation if the pre script fails, specify <code>false</code>.</p></li>
    /// </ul>
    /// <p>This parameter is supported only if you run a pre script. If you run a post script only, omit this parameter.</p>
    /// <p>Default: true</p>
    pub fn execute_operation_on_script_failure(mut self, input: bool) -> Self {
        self.execute_operation_on_script_failure = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether Amazon Data Lifecycle Manager should default to crash-consistent snapshots if the pre script fails.</p>
    /// <ul>
    /// <li>
    /// <p>To default to crash consistent snapshot if the pre script fails, specify <code>true</code>.</p></li>
    /// <li>
    /// <p>To skip the instance for snapshot creation if the pre script fails, specify <code>false</code>.</p></li>
    /// </ul>
    /// <p>This parameter is supported only if you run a pre script. If you run a post script only, omit this parameter.</p>
    /// <p>Default: true</p>
    pub fn set_execute_operation_on_script_failure(mut self, input: ::std::option::Option<bool>) -> Self {
        self.execute_operation_on_script_failure = input;
        self
    }
    /// <p>Indicates whether Amazon Data Lifecycle Manager should default to crash-consistent snapshots if the pre script fails.</p>
    /// <ul>
    /// <li>
    /// <p>To default to crash consistent snapshot if the pre script fails, specify <code>true</code>.</p></li>
    /// <li>
    /// <p>To skip the instance for snapshot creation if the pre script fails, specify <code>false</code>.</p></li>
    /// </ul>
    /// <p>This parameter is supported only if you run a pre script. If you run a post script only, omit this parameter.</p>
    /// <p>Default: true</p>
    pub fn get_execute_operation_on_script_failure(&self) -> &::std::option::Option<bool> {
        &self.execute_operation_on_script_failure
    }
    /// <p>Specifies a timeout period, in seconds, after which Amazon Data Lifecycle Manager fails the script run attempt if it has not completed. If a script does not complete within its timeout period, Amazon Data Lifecycle Manager fails the attempt. The timeout period applies to the pre and post scripts individually.</p>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: 10</p>
    pub fn execution_timeout(mut self, input: i32) -> Self {
        self.execution_timeout = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies a timeout period, in seconds, after which Amazon Data Lifecycle Manager fails the script run attempt if it has not completed. If a script does not complete within its timeout period, Amazon Data Lifecycle Manager fails the attempt. The timeout period applies to the pre and post scripts individually.</p>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: 10</p>
    pub fn set_execution_timeout(mut self, input: ::std::option::Option<i32>) -> Self {
        self.execution_timeout = input;
        self
    }
    /// <p>Specifies a timeout period, in seconds, after which Amazon Data Lifecycle Manager fails the script run attempt if it has not completed. If a script does not complete within its timeout period, Amazon Data Lifecycle Manager fails the attempt. The timeout period applies to the pre and post scripts individually.</p>
    /// <p>If you are automating VSS Backups, omit this parameter.</p>
    /// <p>Default: 10</p>
    pub fn get_execution_timeout(&self) -> &::std::option::Option<i32> {
        &self.execution_timeout
    }
    /// <p>Specifies the number of times Amazon Data Lifecycle Manager should retry scripts that fail.</p>
    /// <ul>
    /// <li>
    /// <p>If the pre script fails, Amazon Data Lifecycle Manager retries the entire snapshot creation process, including running the pre and post scripts.</p></li>
    /// <li>
    /// <p>If the post script fails, Amazon Data Lifecycle Manager retries the post script only; in this case, the pre script will have completed and the snapshot might have been created.</p></li>
    /// </ul>
    /// <p>If you do not want Amazon Data Lifecycle Manager to retry failed scripts, specify <code>0</code>.</p>
    /// <p>Default: 0</p>
    pub fn maximum_retry_count(mut self, input: i32) -> Self {
        self.maximum_retry_count = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies the number of times Amazon Data Lifecycle Manager should retry scripts that fail.</p>
    /// <ul>
    /// <li>
    /// <p>If the pre script fails, Amazon Data Lifecycle Manager retries the entire snapshot creation process, including running the pre and post scripts.</p></li>
    /// <li>
    /// <p>If the post script fails, Amazon Data Lifecycle Manager retries the post script only; in this case, the pre script will have completed and the snapshot might have been created.</p></li>
    /// </ul>
    /// <p>If you do not want Amazon Data Lifecycle Manager to retry failed scripts, specify <code>0</code>.</p>
    /// <p>Default: 0</p>
    pub fn set_maximum_retry_count(mut self, input: ::std::option::Option<i32>) -> Self {
        self.maximum_retry_count = input;
        self
    }
    /// <p>Specifies the number of times Amazon Data Lifecycle Manager should retry scripts that fail.</p>
    /// <ul>
    /// <li>
    /// <p>If the pre script fails, Amazon Data Lifecycle Manager retries the entire snapshot creation process, including running the pre and post scripts.</p></li>
    /// <li>
    /// <p>If the post script fails, Amazon Data Lifecycle Manager retries the post script only; in this case, the pre script will have completed and the snapshot might have been created.</p></li>
    /// </ul>
    /// <p>If you do not want Amazon Data Lifecycle Manager to retry failed scripts, specify <code>0</code>.</p>
    /// <p>Default: 0</p>
    pub fn get_maximum_retry_count(&self) -> &::std::option::Option<i32> {
        &self.maximum_retry_count
    }
    /// Consumes the builder and constructs a [`Script`](crate::types::Script).
    pub fn build(self) -> crate::types::Script {
        crate::types::Script {
            stages: self.stages,
            execution_handler_service: self.execution_handler_service,
            execution_handler: self.execution_handler,
            execute_operation_on_script_failure: self.execute_operation_on_script_failure,
            execution_timeout: self.execution_timeout,
            maximum_retry_count: self.maximum_retry_count,
        }
    }
}