Class: Aws::OpenSearchMemory::Waiters::SpaceDeleted

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

Overview

Waits until the space is deleted.

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ SpaceDeleted

Returns a new instance of SpaceDeleted.

Parameters:

  • options (Hash)

Options Hash (options):

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


160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
# File 'gems/aws-sdk-opensearchmemory/lib/aws-sdk-opensearchmemory/waiters.rb', line 160

def initialize(options)
  @client = options.fetch(:client)
  @waiter = Aws::Waiters::Waiter.new({
    max_attempts: 60,
    delay: 10,
    poller: Aws::Waiters::Poller.new(
      operation_name: :get_space,
      acceptors: [
        {
          "matcher" => "error",
          "state" => "success",
          "expected" => "ResourceNotFoundException"
        },
        {
          "matcher" => "path",
          "argument" => "status",
          "state" => "success",
          "expected" => "DELETED"
        },
        {
          "matcher" => "path",
          "argument" => "status",
          "state" => "retry",
          "expected" => "DELETING"
        },
        {
          "matcher" => "path",
          "argument" => "status",
          "state" => "failure",
          "expected" => "FAILED"
        }
      ]
    )
  }.merge(options))
end

Instance Method Details

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

Returns a response object which responds to the following methods:

Parameters:

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

    a customizable set of options

Options Hash (params):

  • :space_id (required, String) —

    The ID of the space.

Returns:



198
199
200
# File 'gems/aws-sdk-opensearchmemory/lib/aws-sdk-opensearchmemory/waiters.rb', line 198

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