Skip to content

update_resource_set async

update_resource_set(
    resource_set_name: __string,
    *,
    config_overrides: Optional[AsyncRoute53RecoveryReadinessClientConfig] = None,
    resource_set_type: Optional[__stringPatternAWSAZaZ09AZaZ09] = None,
    resources: Optional[__listOfResource] = None,
) -> UpdateResourceSetResponse

Updates a resource set.

Parameters:

  • resource_set_name (__string) –

    Name of a resource set.

  • resource_set_type (Optional[__stringPatternAWSAZaZ09AZaZ09], default: None ) –

    The resource type of the resources in the resource set. Enter one of the following values for resource type:

    AWS::ApiGateway::Stage, AWS::ApiGatewayV2::Stage, AWS::AutoScaling::AutoScalingGroup, AWS::CloudWatch::Alarm, AWS::EC2::CustomerGateway, AWS::DynamoDB::Table, AWS::EC2::Volume, AWS::ElasticLoadBalancing::LoadBalancer, AWS::ElasticLoadBalancingV2::LoadBalancer, AWS::Lambda::Function, AWS::MSK::Cluster, AWS::RDS::DBCluster, AWS::Route53::HealthCheck, AWS::SQS::Queue, AWS::SNS::Topic, AWS::SNS::Subscription, AWS::EC2::VPC, AWS::EC2::VPNConnection, AWS::EC2::VPNGateway, AWS::Route53RecoveryReadiness::DNSTargetResource

  • resources (Optional[__listOfResource], default: None ) –

    A list of resource objects.

Raises:

Source code in docs_src/capo_route53_recovery_readiness/_services/async_route53_recovery_readiness.py
async def update_resource_set(
    self,
    resource_set_name: "capo_route53_recovery_readiness.types.__string.__string",
    *,
    config_overrides: Optional[AsyncRoute53RecoveryReadinessClientConfig] = None,
    resource_set_type: Optional[
        "capo_route53_recovery_readiness.types.__string_pattern_awsa_za_z09_a_za_z09.__stringPatternAWSAZaZ09AZaZ09"
    ] = None,
    resources: Optional[
        "capo_route53_recovery_readiness.types.__list_of_resource.__listOfResource"
    ] = None,
) -> "capo_route53_recovery_readiness.types.update_resource_set_response.UpdateResourceSetResponse":
    """<p>Updates a resource set.</p>

    Args:
        resource_set_name: <p>Name of a resource set.</p>
        resource_set_type: <p>The resource type of the resources in the resource set. Enter one of the following values for resource type:</p> <p>AWS::ApiGateway::Stage, AWS::ApiGatewayV2::Stage, AWS::AutoScaling::AutoScalingGroup, AWS::CloudWatch::Alarm, AWS::EC2::CustomerGateway, AWS::DynamoDB::Table, AWS::EC2::Volume, AWS::ElasticLoadBalancing::LoadBalancer, AWS::ElasticLoadBalancingV2::LoadBalancer, AWS::Lambda::Function, AWS::MSK::Cluster, AWS::RDS::DBCluster, AWS::Route53::HealthCheck, AWS::SQS::Queue, AWS::SNS::Topic, AWS::SNS::Subscription, AWS::EC2::VPC, AWS::EC2::VPNConnection, AWS::EC2::VPNGateway, AWS::Route53RecoveryReadiness::DNSTargetResource</p>
        resources: <p>A list of resource objects.</p>

    Raises:
        capo_route53_recovery_readiness.errors.access_denied_exception.AccessDeniedException: User does not have sufficient access to perform this action.
        capo_route53_recovery_readiness.errors.internal_server_exception.InternalServerException: An unexpected error occurred.
        capo_route53_recovery_readiness.errors.resource_not_found_exception.ResourceNotFoundException: The requested resource does not exist.
        capo_route53_recovery_readiness.errors.throttling_exception.ThrottlingException: Request was denied due to request throttling.
        capo_route53_recovery_readiness.errors.validation_exception.ValidationException: The input fails to satisfy the constraints specified by an AWS service.
        capo_route53_recovery_readiness.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_route53_recovery_readiness.types.update_resource_set_request.UpdateResourceSetRequest]",
    ) -> AsyncOperationResponse[
        "capo_route53_recovery_readiness.types.update_resource_set_response.UpdateResourceSetResponse"
    ]:
        import capo_route53_recovery_readiness._operations.route53_recovery_readiness.update_resource_set

        (
            output,
            http_response,
        ) = await capo_route53_recovery_readiness._operations.route53_recovery_readiness.update_resource_set.async_update_resource_set(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdateResourceSet")
    )
    input_: capo_route53_recovery_readiness.types.update_resource_set_request.UpdateResourceSetRequest = {
        "resource_set_name": resource_set_name
    }
    if resource_set_type is not None:
        input_["resource_set_type"] = resource_set_type
    if resources is not None:
        input_["resources"] = resources

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output