blob: 210626110a9cf982524eea5ed7017c85e9eb2eda [file] [log] [blame]
:py:mod:`airflow.providers.amazon.aws.hooks.dms`
================================================
.. py:module:: airflow.providers.amazon.aws.hooks.dms
Module Contents
---------------
Classes
~~~~~~~
.. autoapisummary::
airflow.providers.amazon.aws.hooks.dms.DmsTaskWaiterStatus
airflow.providers.amazon.aws.hooks.dms.DmsHook
.. py:class:: DmsTaskWaiterStatus
Bases: :py:obj:`str`, :py:obj:`enum.Enum`
Available AWS DMS Task Waiter statuses.
.. py:attribute:: DELETED
:annotation: = deleted
.. py:attribute:: READY
:annotation: = ready
.. py:attribute:: RUNNING
:annotation: = running
.. py:attribute:: STOPPED
:annotation: = stopped
.. py:class:: DmsHook(*args, **kwargs)
Bases: :py:obj:`airflow.providers.amazon.aws.hooks.base_aws.AwsBaseHook`
Interact with AWS Database Migration Service.
.. py:method:: describe_replication_tasks(self, **kwargs)
Describe replication tasks
:return: Marker and list of replication tasks
:rtype: (Optional[str], list)
.. py:method:: find_replication_tasks_by_arn(self, replication_task_arn, without_settings = False)
Find and describe replication tasks by task ARN
:param replication_task_arn: Replication task arn
:param without_settings: Indicates whether to return task information with settings.
:return: list of replication tasks that match the ARN
.. py:method:: get_task_status(self, replication_task_arn)
Retrieve task status.
:param replication_task_arn: Replication task ARN
:return: Current task status
.. py:method:: create_replication_task(self, replication_task_id, source_endpoint_arn, target_endpoint_arn, replication_instance_arn, migration_type, table_mappings, **kwargs)
Create DMS replication task
:param replication_task_id: Replication task id
:param source_endpoint_arn: Source endpoint ARN
:param target_endpoint_arn: Target endpoint ARN
:param replication_instance_arn: Replication instance ARN
:param table_mappings: Table mappings
:param migration_type: Migration type ('full-load'|'cdc'|'full-load-and-cdc'), full-load by default.
:return: Replication task ARN
.. py:method:: start_replication_task(self, replication_task_arn, start_replication_task_type, **kwargs)
Starts replication task.
:param replication_task_arn: Replication task ARN
:param start_replication_task_type: Replication task start type (default='start-replication')
('start-replication'|'resume-processing'|'reload-target')
.. py:method:: stop_replication_task(self, replication_task_arn)
Stops replication task.
:param replication_task_arn: Replication task ARN
.. py:method:: delete_replication_task(self, replication_task_arn)
Starts replication task deletion and waits for it to be deleted
:param replication_task_arn: Replication task ARN
.. py:method:: wait_for_task_status(self, replication_task_arn, status)
Waits for replication task to reach status.
Supported statuses: deleted, ready, running, stopped.
:param status: Status to wait for
:param replication_task_arn: Replication task ARN