Skip to content

disassociate_table_replication async

disassociate_table_replication(
    table_arn: TableARN, *, config_overrides: Optional[AsyncS3TablesClientConfig] = None
) -> DisassociateTableReplicationResponse

Disassociates a replica table from replication, making it a standalone writable table. Any in-progress replication to the table stops, and in-flight commits fail without being committed to the table. Disassociating a table from replication is permanent and can't be reversed.

You can only disassociate a replica table. If you call this operation on a table that isn't a replica table, including a table that you have already disassociated, the request fails.

After you disassociate a table from replication, you can write to the table as you do any other table. GetTable no longer returns managedByService and managedTableInformation for the table, and ListTables no longer returns managedByService for it. On the source table, GetTableReplicationStatus reports a failure for this destination the next time replication to it is attempted.

Disassociating a table from replication doesn't change its maintenance configuration. Review the maintenance settings of the table, such as compaction, after you disassociate it.

Permissions

You must have the s3tables:DisassociateTableReplication permission to use this operation.

Parameters:

  • table_arn (TableARN) –

    The Amazon Resource Name (ARN) of the replica table to disassociate from replication.

Raises:

  • AccessDeniedException –

    The action cannot be performed because you do not have the required permission.

  • BadRequestException –

    The request is invalid or malformed.

  • ConflictException –

    The request conflicts with the resource's current state, such as a previous write, an existing table, or a migration that's in progress or already in the requested state. If the conflict is with a concurrent write, you can retry the request.

  • ForbiddenException –

    The caller isn't authorized to make the request.

  • InternalServerErrorException –

    The request failed due to an internal server error.

  • NotFoundException –

    The request was rejected because the specified resource could not be found.

  • TooManyRequestsException –

    The limit on the number of requests per second was exceeded.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_s3tables/_services/async_s3_tables.py
async def disassociate_table_replication(
    self,
    table_arn: "capo_s3tables.types.table_arn.TableARN",
    *,
    config_overrides: Optional[AsyncS3TablesClientConfig] = None,
) -> "capo_s3tables.types.disassociate_table_replication_response.DisassociateTableReplicationResponse":
    """<p>Disassociates a replica table from replication, making it a standalone writable table. Any in-progress replication to the table stops, and in-flight commits fail without being committed to the table. Disassociating a table from replication is permanent and can't be reversed.</p> <p>You can only disassociate a replica table. If you call this operation on a table that isn't a replica table, including a table that you have already disassociated, the request fails.</p> <p>After you disassociate a table from replication, you can write to the table as you do any other table. <code>GetTable</code> no longer returns <code>managedByService</code> and <code>managedTableInformation</code> for the table, and <code>ListTables</code> no longer returns <code>managedByService</code> for it. On the source table, <code>GetTableReplicationStatus</code> reports a failure for this destination the next time replication to it is attempted.</p> <p>Disassociating a table from replication doesn't change its maintenance configuration. Review the maintenance settings of the table, such as compaction, after you disassociate it.</p> <dl> <dt>Permissions</dt> <dd> <p>You must have the <code>s3tables:DisassociateTableReplication</code> permission to use this operation.</p> </dd> </dl>

    Args:
        table_arn: <p>The Amazon Resource Name (ARN) of the replica table to disassociate from replication.</p>

    Raises:
        capo_s3tables.errors.access_denied_exception.AccessDeniedException: <p>The action cannot be performed because you do not have the required permission.</p>
        capo_s3tables.errors.bad_request_exception.BadRequestException: <p>The request is invalid or malformed.</p>
        capo_s3tables.errors.conflict_exception.ConflictException: <p>The request conflicts with the resource's current state, such as a previous write, an existing table, or a migration that's in progress or already in the requested state. If the conflict is with a concurrent write, you can retry the request.</p>
        capo_s3tables.errors.forbidden_exception.ForbiddenException: <p>The caller isn't authorized to make the request.</p>
        capo_s3tables.errors.internal_server_error_exception.InternalServerErrorException: <p>The request failed due to an internal server error.</p>
        capo_s3tables.errors.not_found_exception.NotFoundException: <p>The request was rejected because the specified resource could not be found.</p>
        capo_s3tables.errors.too_many_requests_exception.TooManyRequestsException: <p>The limit on the number of requests per second was exceeded.</p>
        capo_s3tables.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_s3tables.types.disassociate_table_replication_request.DisassociateTableReplicationRequest]",
    ) -> AsyncOperationResponse[
        "capo_s3tables.types.disassociate_table_replication_response.DisassociateTableReplicationResponse"
    ]:
        import capo_s3tables._operations.s3_table_buckets.disassociate_table_replication

        (
            output,
            http_response,
        ) = await capo_s3tables._operations.s3_table_buckets.disassociate_table_replication.async_disassociate_table_replication(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DisassociateTableReplication")
    )
    input_: capo_s3tables.types.disassociate_table_replication_request.DisassociateTableReplicationRequest = {
        "table_arn": table_arn
    }

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