Class: Aws::DatabaseMigrationService::Waiters::ReplicationTaskStopped

Inherits:
Object
  • Object
show all
Defined in:
lib/aws-sdk-databasemigrationservice/waiters.rb

Overview

Wait until DMS replication task is stopped.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ ReplicationTaskStopped

Returns a new instance of ReplicationTaskStopped.

Parameters:

  • options (Hash)

Options Hash (options):

  • :client (required, Client)
  • :max_attempts (Integer) — default: 60
  • :delay (Integer) — default: 15
  • :before_attempt (Proc)
  • :before_wait (Proc)


491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
# File 'lib/aws-sdk-databasemigrationservice/waiters.rb', line 491

def initialize(options)
  @client = options.fetch(:client)
  @waiter = Aws::Waiters::Waiter.new({
    max_attempts: 60,
    delay: 15,
    poller: Aws::Waiters::Poller.new(
      operation_name: :describe_replication_tasks,
      acceptors: [
        {
          "argument" => "replication_tasks[].status",
          "expected" => "stopped",
          "matcher" => "pathAll",
          "state" => "success"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "ready",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "creating",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "starting",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "failed",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "modifying",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "testing",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_tasks[].status",
          "expected" => "deleting",
          "matcher" => "pathAny",
          "state" => "failure"
        }
      ]
    )
  }.merge(options))
end

Instance Attribute Details

#waiterObject (readonly)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



559
560
561
# File 'lib/aws-sdk-databasemigrationservice/waiters.rb', line 559

def waiter
  @waiter
end

Instance Method Details

#wait(params = {}) ⇒ Types::DescribeReplicationTasksResponse

Returns a response object which responds to the following methods:

Options Hash (params):

  • :filters (Array<Types::Filter>)

    Filters applied to replication tasks.

    Valid filter names: replication-task-arn | replication-task-id | migration-type | endpoint-arn | replication-instance-arn

  • :max_records (Integer)

    The maximum number of records to include in the response. If more records exist than the specified ‘MaxRecords` value, a pagination token called a marker is included in the response so that the remaining results can be retrieved.

    Default: 100

    Constraints: Minimum 20, maximum 100.

  • :marker (String)

    An optional pagination token provided by a previous request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by ‘MaxRecords`.

  • :without_settings (Boolean)

    An option to set to avoid returning information about settings. Use this to reduce overhead when setting information is too large. To use this option, choose ‘true`; otherwise, choose `false` (the default).

Returns:



554
555
556
# File 'lib/aws-sdk-databasemigrationservice/waiters.rb', line 554

def wait(params = {})
  @waiter.wait(client: @client, params: params)
end