pub struct Builder { /* private fields */ }
Expand description

A builder for ModifyVolumeInput.

Implementations§

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Examples found in repository?
src/client.rs (line 68909)
68908
68909
68910
68911
        pub fn dry_run(mut self, input: bool) -> Self {
            self.inner = self.inner.dry_run(input);
            self
        }

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Examples found in repository?
src/client.rs (line 68914)
68913
68914
68915
68916
        pub fn set_dry_run(mut self, input: std::option::Option<bool>) -> Self {
            self.inner = self.inner.set_dry_run(input);
            self
        }

The ID of the volume.

Examples found in repository?
src/client.rs (line 68919)
68918
68919
68920
68921
        pub fn volume_id(mut self, input: impl Into<std::string::String>) -> Self {
            self.inner = self.inner.volume_id(input.into());
            self
        }

The ID of the volume.

Examples found in repository?
src/client.rs (line 68924)
68923
68924
68925
68926
        pub fn set_volume_id(mut self, input: std::option::Option<std::string::String>) -> Self {
            self.inner = self.inner.set_volume_id(input);
            self
        }

The target size of the volume, in GiB. The target volume size must be greater than or equal to the existing size of the volume.

The following are the supported volumes sizes for each volume type:

  • gp2 and gp3: 1-16,384

  • io1 and io2: 4-16,384

  • st1 and sc1: 125-16,384

  • standard: 1-1,024

Default: The existing size is retained.

Examples found in repository?
src/client.rs (line 68937)
68936
68937
68938
68939
        pub fn size(mut self, input: i32) -> Self {
            self.inner = self.inner.size(input);
            self
        }

The target size of the volume, in GiB. The target volume size must be greater than or equal to the existing size of the volume.

The following are the supported volumes sizes for each volume type:

  • gp2 and gp3: 1-16,384

  • io1 and io2: 4-16,384

  • st1 and sc1: 125-16,384

  • standard: 1-1,024

Default: The existing size is retained.

Examples found in repository?
src/client.rs (line 68950)
68949
68950
68951
68952
        pub fn set_size(mut self, input: std::option::Option<i32>) -> Self {
            self.inner = self.inner.set_size(input);
            self
        }

The target EBS volume type of the volume. For more information, see Amazon EBS volume types in the Amazon Elastic Compute Cloud User Guide.

Default: The existing type is retained.

Examples found in repository?
src/client.rs (line 68956)
68955
68956
68957
68958
        pub fn volume_type(mut self, input: crate::model::VolumeType) -> Self {
            self.inner = self.inner.volume_type(input);
            self
        }

The target EBS volume type of the volume. For more information, see Amazon EBS volume types in the Amazon Elastic Compute Cloud User Guide.

Default: The existing type is retained.

Examples found in repository?
src/client.rs (line 68965)
68961
68962
68963
68964
68965
68966
68967
        pub fn set_volume_type(
            mut self,
            input: std::option::Option<crate::model::VolumeType>,
        ) -> Self {
            self.inner = self.inner.set_volume_type(input);
            self
        }

The target IOPS rate of the volume. This parameter is valid only for gp3, io1, and io2 volumes.

The following are the supported values for each volume type:

  • gp3: 3,000-16,000 IOPS

  • io1: 100-64,000 IOPS

  • io2: 100-64,000 IOPS

Default: The existing value is retained if you keep the same volume type. If you change the volume type to io1, io2, or gp3, the default is 3,000.

Examples found in repository?
src/client.rs (line 68977)
68976
68977
68978
68979
        pub fn iops(mut self, input: i32) -> Self {
            self.inner = self.inner.iops(input);
            self
        }

The target IOPS rate of the volume. This parameter is valid only for gp3, io1, and io2 volumes.

The following are the supported values for each volume type:

  • gp3: 3,000-16,000 IOPS

  • io1: 100-64,000 IOPS

  • io2: 100-64,000 IOPS

Default: The existing value is retained if you keep the same volume type. If you change the volume type to io1, io2, or gp3, the default is 3,000.

Examples found in repository?
src/client.rs (line 68989)
68988
68989
68990
68991
        pub fn set_iops(mut self, input: std::option::Option<i32>) -> Self {
            self.inner = self.inner.set_iops(input);
            self
        }

The target throughput of the volume, in MiB/s. This parameter is valid only for gp3 volumes. The maximum value is 1,000.

Default: The existing value is retained if the source and target volume type is gp3. Otherwise, the default value is 125.

Valid Range: Minimum value of 125. Maximum value of 1000.

Examples found in repository?
src/client.rs (line 68996)
68995
68996
68997
68998
        pub fn throughput(mut self, input: i32) -> Self {
            self.inner = self.inner.throughput(input);
            self
        }

The target throughput of the volume, in MiB/s. This parameter is valid only for gp3 volumes. The maximum value is 1,000.

Default: The existing value is retained if the source and target volume type is gp3. Otherwise, the default value is 125.

Valid Range: Minimum value of 125. Maximum value of 1000.

Examples found in repository?
src/client.rs (line 69003)
69002
69003
69004
69005
        pub fn set_throughput(mut self, input: std::option::Option<i32>) -> Self {
            self.inner = self.inner.set_throughput(input);
            self
        }

Specifies whether to enable Amazon EBS Multi-Attach. If you enable Multi-Attach, you can attach the volume to up to 16 Nitro-based instances in the same Availability Zone. This parameter is supported with io1 and io2 volumes only. For more information, see Amazon EBS Multi-Attach in the Amazon Elastic Compute Cloud User Guide.

Examples found in repository?
src/client.rs (line 69008)
69007
69008
69009
69010
        pub fn multi_attach_enabled(mut self, input: bool) -> Self {
            self.inner = self.inner.multi_attach_enabled(input);
            self
        }

Specifies whether to enable Amazon EBS Multi-Attach. If you enable Multi-Attach, you can attach the volume to up to 16 Nitro-based instances in the same Availability Zone. This parameter is supported with io1 and io2 volumes only. For more information, see Amazon EBS Multi-Attach in the Amazon Elastic Compute Cloud User Guide.

Examples found in repository?
src/client.rs (line 69013)
69012
69013
69014
69015
        pub fn set_multi_attach_enabled(mut self, input: std::option::Option<bool>) -> Self {
            self.inner = self.inner.set_multi_attach_enabled(input);
            self
        }

Consumes the builder and constructs a ModifyVolumeInput.

Examples found in repository?
src/client.rs (line 68876)
68864
68865
68866
68867
68868
68869
68870
68871
68872
68873
68874
68875
68876
68877
68878
68879
68880
68881
68882
68883
68884
68885
68886
68887
68888
68889
68890
68891
68892
68893
68894
68895
68896
68897
68898
68899
68900
68901
68902
68903
68904
68905
68906
        pub async fn customize(
            self,
        ) -> std::result::Result<
            crate::operation::customize::CustomizableOperation<
                crate::operation::ModifyVolume,
                aws_http::retry::AwsResponseRetryClassifier,
            >,
            aws_smithy_http::result::SdkError<crate::error::ModifyVolumeError>,
        > {
            let handle = self.handle.clone();
            let operation = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            Ok(crate::operation::customize::CustomizableOperation { handle, operation })
        }

        /// Sends the request and returns the response.
        ///
        /// If an error occurs, an `SdkError` will be returned with additional details that
        /// can be matched against.
        ///
        /// By default, any retryable failures will be retried twice. Retry behavior
        /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
        /// set when configuring the client.
        pub async fn send(
            self,
        ) -> std::result::Result<
            crate::output::ModifyVolumeOutput,
            aws_smithy_http::result::SdkError<crate::error::ModifyVolumeError>,
        > {
            let op = self
                .inner
                .build()
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?
                .make_operation(&self.handle.conf)
                .await
                .map_err(aws_smithy_http::result::SdkError::construction_failure)?;
            self.handle.client.call(op).await
        }

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
This method tests for self and other values to be equal, and is used by ==. Read more
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more