Skip to content

DatabaseMigrationServiceClient#

Index > DatabaseMigrationService > DatabaseMigrationServiceClient

Auto-generated documentation for DatabaseMigrationService type annotations stubs module mypy-boto3-dms.

DatabaseMigrationServiceClient#

Type annotations and code completion for boto3.client("dms"). boto3 documentation

# DatabaseMigrationServiceClient usage example

from boto3.session import Session
from mypy_boto3_dms.client import DatabaseMigrationServiceClient

def get_dms_client() -> DatabaseMigrationServiceClient:
    return Session().client("dms")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("dms").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("dms")

try:
    do_something(client)
except (
    client.exceptions.AccessDeniedFault,
    client.exceptions.ClientError,
    client.exceptions.CollectorNotFoundFault,
    client.exceptions.InsufficientResourceCapacityFault,
    client.exceptions.InvalidCertificateFault,
    client.exceptions.InvalidOperationFault,
    client.exceptions.InvalidResourceStateFault,
    client.exceptions.InvalidSubnet,
    client.exceptions.KMSAccessDeniedFault,
    client.exceptions.KMSDisabledFault,
    client.exceptions.KMSFault,
    client.exceptions.KMSInvalidStateFault,
    client.exceptions.KMSKeyNotAccessibleFault,
    client.exceptions.KMSNotFoundFault,
    client.exceptions.KMSThrottlingFault,
    client.exceptions.ReplicationSubnetGroupDoesNotCoverEnoughAZs,
    client.exceptions.ResourceAlreadyExistsFault,
    client.exceptions.ResourceNotFoundFault,
    client.exceptions.ResourceQuotaExceededFault,
    client.exceptions.S3AccessDeniedFault,
    client.exceptions.S3ResourceNotFoundFault,
    client.exceptions.SNSInvalidTopicFault,
    client.exceptions.SNSNoAuthorizationFault,
    client.exceptions.StorageQuotaExceededFault,
    client.exceptions.SubnetAlreadyInUse,
    client.exceptions.UpgradeDependencyFailureFault,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_dms.client import Exceptions

def handle_error(exc: Exceptions.AccessDeniedFault) -> None:
    ...

Methods#

add_tags_to_resource#

Adds metadata tags to an DMS resource, including replication instance, endpoint, subnet group, and migration task.

Type annotations and code completion for boto3.client("dms").add_tags_to_resource method. boto3 documentation

# add_tags_to_resource method definition

def add_tags_to_resource(
    self,
    *,
    ResourceArn: str,
    Tags: Sequence[TagTypeDef],  # (1)
) -> Dict[str, Any]:
    ...
  1. See TagTypeDef
# add_tags_to_resource method usage example with argument unpacking

kwargs: AddTagsToResourceMessageRequestTypeDef = {  # (1)
    "ResourceArn": ...,
    "Tags": ...,
}

parent.add_tags_to_resource(**kwargs)
  1. See AddTagsToResourceMessageRequestTypeDef

apply_pending_maintenance_action#

Applies a pending maintenance action to a resource (for example, to a replication instance).

Type annotations and code completion for boto3.client("dms").apply_pending_maintenance_action method. boto3 documentation

# apply_pending_maintenance_action method definition

def apply_pending_maintenance_action(
    self,
    *,
    ReplicationInstanceArn: str,
    ApplyAction: str,
    OptInType: str,
) -> ApplyPendingMaintenanceActionResponseTypeDef:  # (1)
    ...
  1. See ApplyPendingMaintenanceActionResponseTypeDef
# apply_pending_maintenance_action method usage example with argument unpacking

kwargs: ApplyPendingMaintenanceActionMessageRequestTypeDef = {  # (1)
    "ReplicationInstanceArn": ...,
    "ApplyAction": ...,
    "OptInType": ...,
}

parent.apply_pending_maintenance_action(**kwargs)
  1. See ApplyPendingMaintenanceActionMessageRequestTypeDef

batch_start_recommendations#

Starts the analysis of up to 20 source databases to recommend target engines for each source database.

Type annotations and code completion for boto3.client("dms").batch_start_recommendations method. boto3 documentation

# batch_start_recommendations method definition

def batch_start_recommendations(
    self,
    *,
    Data: Sequence[StartRecommendationsRequestEntryTypeDef] = ...,  # (1)
) -> BatchStartRecommendationsResponseTypeDef:  # (2)
    ...
  1. See StartRecommendationsRequestEntryTypeDef
  2. See BatchStartRecommendationsResponseTypeDef
# batch_start_recommendations method usage example with argument unpacking

kwargs: BatchStartRecommendationsRequestRequestTypeDef = {  # (1)
    "Data": ...,
}

parent.batch_start_recommendations(**kwargs)
  1. See BatchStartRecommendationsRequestRequestTypeDef

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for boto3.client("dms").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

cancel_replication_task_assessment_run#

Cancels a single premigration assessment run.

Type annotations and code completion for boto3.client("dms").cancel_replication_task_assessment_run method. boto3 documentation

# cancel_replication_task_assessment_run method definition

def cancel_replication_task_assessment_run(
    self,
    *,
    ReplicationTaskAssessmentRunArn: str,
) -> CancelReplicationTaskAssessmentRunResponseTypeDef:  # (1)
    ...
  1. See CancelReplicationTaskAssessmentRunResponseTypeDef
# cancel_replication_task_assessment_run method usage example with argument unpacking

kwargs: CancelReplicationTaskAssessmentRunMessageRequestTypeDef = {  # (1)
    "ReplicationTaskAssessmentRunArn": ...,
}

parent.cancel_replication_task_assessment_run(**kwargs)
  1. See CancelReplicationTaskAssessmentRunMessageRequestTypeDef

close#

Closes underlying endpoint connections.

Type annotations and code completion for boto3.client("dms").close method. boto3 documentation

# close method definition

def close(
    self,
) -> None:
    ...

create_data_provider#

Creates a data provider using the provided settings.

Type annotations and code completion for boto3.client("dms").create_data_provider method.