Skip to content

update_region_settings

update_region_settings(
    *,
    config_overrides: Optional[BackupClientConfig] = None,
    resource_type_opt_in_preference: Optional[ResourceTypeOptInPreference] = None,
    resource_type_management_preference: Optional[
        ResourceTypeManagementPreference
    ] = None,
    resource_type_opt_in_incremental: Optional[ResourceTypeOptInIncremental] = None,
) -> None

Updates the current service opt-in settings for the Region.

Use the DescribeRegionSettings API to determine the resource types that are supported.

Parameters:

  • resource_type_opt_in_preference (Optional[ResourceTypeOptInPreference], default: None ) –

    Updates the list of services along with the opt-in preferences for the Region.

    If resource assignments are only based on tags, then service opt-in settings are applied. If a resource type is explicitly assigned to a backup plan, such as Amazon S3, Amazon EC2, or Amazon RDS, it will be included in the backup even if the opt-in is not enabled for that particular service. If both a resource type and tags are specified in a resource assignment, the resource type specified in the backup plan takes priority over the tag condition. Service opt-in settings are disregarded in this situation.

  • resource_type_management_preference (Optional[ResourceTypeManagementPreference], default: None ) –

    Enables or disables full Backup management of backups for a resource type. To enable full Backup management for DynamoDB along with Backup's advanced DynamoDB backup features, follow the procedure to enable advanced DynamoDB backup programmatically.

  • resource_type_opt_in_incremental (Optional[ResourceTypeOptInIncremental], default: None ) –

    Specifies whether you opt in to incremental backups for each resource type in the Region. Opt in when you want to reduce backup storage and backup time for large resources that change infrequently. Incremental backup opt-in is currently available for Amazon DynamoDB.

    To view your current incremental backup settings, use the DescribeRegionSettings API. For the resource types that each Backup feature supports, see the Feature availability by resource table.

Raises:

Source code in docs_src/capo_backup/_services/backup.py
def update_region_settings(
    self,
    *,
    config_overrides: Optional[BackupClientConfig] = None,
    resource_type_opt_in_preference: Optional[
        "capo_backup.types.resource_type_opt_in_preference.ResourceTypeOptInPreference"
    ] = None,
    resource_type_management_preference: Optional[
        "capo_backup.types.resource_type_management_preference.ResourceTypeManagementPreference"
    ] = None,
    resource_type_opt_in_incremental: Optional[
        "capo_backup.types.resource_type_opt_in_incremental.ResourceTypeOptInIncremental"
    ] = None,
) -> None:
    """<p>Updates the current service opt-in settings for the Region.</p> <p>Use the <code>DescribeRegionSettings</code> API to determine the resource types that are supported.</p>

    Args:
        resource_type_opt_in_preference: <p>Updates the list of services along with the opt-in preferences for the Region.</p> <p>If resource assignments are only based on tags, then service opt-in settings are applied. If a resource type is explicitly assigned to a backup plan, such as Amazon S3, Amazon EC2, or Amazon RDS, it will be included in the backup even if the opt-in is not enabled for that particular service. If both a resource type and tags are specified in a resource assignment, the resource type specified in the backup plan takes priority over the tag condition. Service opt-in settings are disregarded in this situation.</p>
        resource_type_management_preference: <p>Enables or disables full Backup management of backups for a resource type. To enable full Backup management for DynamoDB along with <a href="https://docs.aws.amazon.com/aws-backup/latest/devguide/advanced-ddb-backup.html"> Backup's advanced DynamoDB backup features</a>, follow the procedure to <a href="https://docs.aws.amazon.com/aws-backup/latest/devguide/advanced-ddb-backup.html#advanced-ddb-backup-enable-cli"> enable advanced DynamoDB backup programmatically</a>.</p>
        resource_type_opt_in_incremental: <p>Specifies whether you opt in to incremental backups for each resource type in the Region. Opt in when you want to reduce backup storage and backup time for large resources that change infrequently. Incremental backup opt-in is currently available for Amazon DynamoDB.</p> <p>To view your current incremental backup settings, use the <code>DescribeRegionSettings</code> API. For the resource types that each Backup feature supports, see the <a href="https://docs.aws.amazon.com/aws-backup/latest/devguide/backup-feature-availability.html#features-by-resource">Feature availability by resource</a> table.</p>

    Raises:
        capo_backup.errors.invalid_parameter_value_exception.InvalidParameterValueException: <p>Indicates that something is wrong with a parameter's value. For example, the value is out of range.</p>
        capo_backup.errors.missing_parameter_value_exception.MissingParameterValueException: <p>Indicates that a required parameter is missing.</p>
        capo_backup.errors.service_unavailable_exception.ServiceUnavailableException: <p>The request failed due to a temporary failure of the server.</p>
        capo_backup.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_backup.types.update_region_settings_input.UpdateRegionSettingsInput]",
    ) -> OperationResponse[None]:
        import capo_backup._operations.cryo_controller_user_manager.update_region_settings

        output, http_response = (
            capo_backup._operations.cryo_controller_user_manager.update_region_settings.update_region_settings(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UpdateRegionSettings")
    )
    input_: capo_backup.types.update_region_settings_input.UpdateRegionSettingsInput = {}
    if resource_type_opt_in_preference is not None:
        input_["resource_type_opt_in_preference"] = resource_type_opt_in_preference
    if resource_type_management_preference is not None:
        input_["resource_type_management_preference"] = (
            resource_type_management_preference
        )
    if resource_type_opt_in_incremental is not None:
        input_["resource_type_opt_in_incremental"] = (
            resource_type_opt_in_incremental
        )

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output