Class: Aws::DatabaseMigrationService::Waiters::ReplicationInstanceAvailable

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

Overview

Wait until DMS replication instance is available.

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ ReplicationInstanceAvailable

Returns a new instance of ReplicationInstanceAvailable.

Parameters:

  • options (Hash)

Options Hash (options):

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


142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
# File 'gems/aws-sdk-databasemigrationservice/lib/aws-sdk-databasemigrationservice/waiters.rb', line 142

def initialize(options)
  @client = options.fetch(:client)
  @waiter = Aws::Waiters::Waiter.new({
    max_attempts: 60,
    delay: 60,
    poller: Aws::Waiters::Poller.new(
      operation_name: :describe_replication_instances,
      acceptors: [
        {
          "argument" => "replication_instances[].replication_instance_status",
          "expected" => "available",
          "matcher" => "pathAll",
          "state" => "success"
        },
        {
          "argument" => "replication_instances[].replication_instance_status",
          "expected" => "deleting",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_instances[].replication_instance_status",
          "expected" => "incompatible-credentials",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_instances[].replication_instance_status",
          "expected" => "incompatible-network",
          "matcher" => "pathAny",
          "state" => "failure"
        },
        {
          "argument" => "replication_instances[].replication_instance_status",
          "expected" => "inaccessible-encryption-credentials",
          "matcher" => "pathAny",
          "state" => "failure"
        }
      ]
    )
  }.merge(options))
end

Instance Method Details

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

Returns a response object which responds to the following methods:

Parameters:

  • params (Hash) (defaults to: {})

    a customizable set of options

Options Hash (params):

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

    Filters applied to replication instances.

    Valid filter names: replication-instance-arn | replication-instance-id | replication-instance-class | engine-version

  • :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.

Returns:



187
188
189
# File 'gems/aws-sdk-databasemigrationservice/lib/aws-sdk-databasemigrationservice/waiters.rb', line 187

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