1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
    /// Constructs a fluent builder for the [`DetachVolume`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder) operation.
    ///
    /// - The fluent builder is configurable:
    ///   - [`device(impl Into<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::device) / [`set_device(Option<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::set_device): <p>The device name.</p>
    ///   - [`force(bool)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::force) / [`set_force(Option<bool>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::set_force): <p>Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.</p>
    ///   - [`instance_id(impl Into<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::instance_id) / [`set_instance_id(Option<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::set_instance_id): <p>The ID of the instance. If you are detaching a Multi-Attach enabled volume, you must specify an instance ID.</p>
    ///   - [`volume_id(impl Into<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::volume_id) / [`set_volume_id(Option<String>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::set_volume_id): <p>The ID of the volume.</p>
    ///   - [`dry_run(bool)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::dry_run) / [`set_dry_run(Option<bool>)`](crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::set_dry_run): <p>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 <code>DryRunOperation</code>. Otherwise, it is <code>UnauthorizedOperation</code>.</p>
    /// - On success, responds with [`DetachVolumeOutput`](crate::operation::detach_volume::DetachVolumeOutput) with field(s):
    ///   - [`attach_time(Option<DateTime>)`](crate::operation::detach_volume::DetachVolumeOutput::attach_time): <p>The time stamp when the attachment initiated.</p>
    ///   - [`device(Option<String>)`](crate::operation::detach_volume::DetachVolumeOutput::device): <p>The device name.</p>
    ///   - [`instance_id(Option<String>)`](crate::operation::detach_volume::DetachVolumeOutput::instance_id): <p>The ID of the instance.</p>
    ///   - [`state(Option<VolumeAttachmentState>)`](crate::operation::detach_volume::DetachVolumeOutput::state): <p>The attachment state of the volume.</p>
    ///   - [`volume_id(Option<String>)`](crate::operation::detach_volume::DetachVolumeOutput::volume_id): <p>The ID of the volume.</p>
    ///   - [`delete_on_termination(Option<bool>)`](crate::operation::detach_volume::DetachVolumeOutput::delete_on_termination): <p>Indicates whether the EBS volume is deleted on instance termination.</p>
    /// - On failure, responds with [`SdkError<DetachVolumeError>`](crate::operation::detach_volume::DetachVolumeError)
    pub fn detach_volume(&self) -> crate::operation::detach_volume::builders::DetachVolumeFluentBuilder {
        crate::operation::detach_volume::builders::DetachVolumeFluentBuilder::new(self.handle.clone())
    }
}