aws-sdk-continuum 1.0.0

AWS SDK for AWS Continuum
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub use crate::operation::update_integration::_update_integration_input::UpdateIntegrationInputBuilder;

pub use crate::operation::update_integration::_update_integration_output::UpdateIntegrationOutputBuilder;

impl crate::operation::update_integration::builders::UpdateIntegrationInputBuilder {
    /// Sends a request with this input using the given client.
    pub async fn send_with(
        self,
        client: &crate::Client,
    ) -> ::std::result::Result<
        crate::operation::update_integration::UpdateIntegrationOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::update_integration::UpdateIntegrationError,
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
        >,
    > {
        let mut fluent_builder = client.update_integration();
        fluent_builder.inner = self;
        fluent_builder.send().await
    }
}
/// Fluent builder constructing a request to `UpdateIntegration`.
///
/// Rotates the credentials used by an Amazon S3 integration. Only S3 integrations can be updated; GitHub integrations cannot be modified. The integration's name, provider type, and bucket remain fixed. The caller must have iam:PassRole permission for the supplied role, including when only the external ID changes. Continuum verifies that the role can be assumed with the requested external ID and can access the existing bucket before saving both credentials atomically. Omitting externalId preserves its current value. Repeating both current credentials leaves updatedAt unchanged, but still requires authorization and access validation.
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
pub struct UpdateIntegrationFluentBuilder {
    handle: ::std::sync::Arc<crate::client::Handle>,
    inner: crate::operation::update_integration::builders::UpdateIntegrationInputBuilder,
    config_override: ::std::option::Option<crate::config::Builder>,
}
impl
    crate::client::customize::internal::CustomizableSend<
        crate::operation::update_integration::UpdateIntegrationOutput,
        crate::operation::update_integration::UpdateIntegrationError,
    > for UpdateIntegrationFluentBuilder
{
    fn send(
        self,
        config_override: crate::config::Builder,
    ) -> crate::client::customize::internal::BoxFuture<
        crate::client::customize::internal::SendResult<
            crate::operation::update_integration::UpdateIntegrationOutput,
            crate::operation::update_integration::UpdateIntegrationError,
        >,
    > {
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
    }
}
impl UpdateIntegrationFluentBuilder {
    /// Creates a new `UpdateIntegrationFluentBuilder`.
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
        Self {
            handle,
            inner: ::std::default::Default::default(),
            config_override: ::std::option::Option::None,
        }
    }
    /// Access the UpdateIntegration as a reference.
    pub fn as_input(&self) -> &crate::operation::update_integration::builders::UpdateIntegrationInputBuilder {
        &self.inner
    }
    /// 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::operation::update_integration::UpdateIntegrationOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::update_integration::UpdateIntegrationError,
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
        >,
    > {
        let input = self
            .inner
            .build()
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
        let runtime_plugins = crate::operation::update_integration::UpdateIntegration::operation_runtime_plugins(
            self.handle.runtime_plugins.clone(),
            &self.handle.conf,
            self.config_override,
        );
        crate::operation::update_integration::UpdateIntegration::orchestrate(&runtime_plugins, input).await
    }

    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
    pub fn customize(
        self,
    ) -> crate::client::customize::CustomizableOperation<
        crate::operation::update_integration::UpdateIntegrationOutput,
        crate::operation::update_integration::UpdateIntegrationError,
        Self,
    > {
        crate::client::customize::CustomizableOperation::new(self)
    }
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
        self.set_config_override(::std::option::Option::Some(config_override.into()));
        self
    }

    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
        self.config_override = config_override;
        self
    }
    /// The unique identifier of the S3 integration to update.
    pub fn integration_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.inner = self.inner.integration_id(input.into());
        self
    }
    /// The unique identifier of the S3 integration to update.
    pub fn set_integration_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.inner = self.inner.set_integration_id(input);
        self
    }
    /// The unique identifier of the S3 integration to update.
    pub fn get_integration_id(&self) -> &::std::option::Option<::std::string::String> {
        self.inner.get_integration_id()
    }
    /// The provider-specific changes to apply. The member must match the integration's provider type, and only S3 integrations can be updated.
    pub fn provider_configuration(mut self, input: crate::types::UpdateProviderConfiguration) -> Self {
        self.inner = self.inner.provider_configuration(input);
        self
    }
    /// The provider-specific changes to apply. The member must match the integration's provider type, and only S3 integrations can be updated.
    pub fn set_provider_configuration(mut self, input: ::std::option::Option<crate::types::UpdateProviderConfiguration>) -> Self {
        self.inner = self.inner.set_provider_configuration(input);
        self
    }
    /// The provider-specific changes to apply. The member must match the integration's provider type, and only S3 integrations can be updated.
    pub fn get_provider_configuration(&self) -> &::std::option::Option<crate::types::UpdateProviderConfiguration> {
        self.inner.get_provider_configuration()
    }
}