Gets the details of a migration, including its state, the reason it failed, its statistics and the location of its reports. Identify the migration by its migrationId, or specify the tableARN of a destination table to get that table's most recent migration.
- Permissions
-
Parameters:
-
migration_id
(Optional[MigrationId], default:
None
)
–
The ID of the migration to get. Specify either migrationId or tableARN, not both.
-
table_arn
(Optional[TableARN], default:
None
)
–
The Amazon Resource Name (ARN) of the destination table. Gets the table's most recent migration. Specify either tableARN or migrationId, not both.
Raises:
Source code in docs_src/capo_s3tables/_services/s3_tables.py
| def get_table_migration(
self,
*,
config_overrides: Optional[S3TablesClientConfig] = None,
migration_id: Optional["capo_s3tables.types.migration_id.MigrationId"] = None,
table_arn: Optional["capo_s3tables.types.table_arn.TableARN"] = None,
) -> "capo_s3tables.types.get_table_migration_response.GetTableMigrationResponse":
"""<p>Gets the details of a migration, including its state, the reason it failed, its statistics and the location of its reports. Identify the migration by its <code>migrationId</code>, or specify the <code>tableARN</code> of a destination table to get that table's most recent migration.</p> <dl> <dt>Permissions</dt> <dd> <ul> <li> <p>You must have the <code>s3tables:GetTableMigration</code> permission to use this operation.</p> </li> </ul> </dd> </dl>
Args:
migration_id: <p>The ID of the migration to get. Specify either <code>migrationId</code> or <code>tableARN</code>, not both.</p>
table_arn: <p>The Amazon Resource Name (ARN) of the destination table. Gets the table's most recent migration. Specify either <code>tableARN</code> or <code>migrationId</code>, not both.</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.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.
"""
def _handler(
req: "OperationRequest[capo_s3tables.types.get_table_migration_request.GetTableMigrationRequest]",
) -> OperationResponse[
"capo_s3tables.types.get_table_migration_response.GetTableMigrationResponse"
]:
import capo_s3tables._operations.s3_table_buckets.get_table_migration
output, http_response = (
capo_s3tables._operations.s3_table_buckets.get_table_migration.get_table_migration(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("GetTableMigration")
)
input_: capo_s3tables.types.get_table_migration_request.GetTableMigrationRequest = {}
if migration_id is not None:
input_["migration_id"] = migration_id
if table_arn is not None:
input_["table_arn"] = table_arn
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|