Class: Aws::ARCRegionswitch::Waiters::PlanExecutionCompleted

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

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ PlanExecutionCompleted

Returns a new instance of PlanExecutionCompleted.

Parameters:

  • options (Hash)

Options Hash (options):

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


135
136
137
138
139
140
141
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
# File 'gems/aws-sdk-arcregionswitch/lib/aws-sdk-arcregionswitch/waiters.rb', line 135

def initialize(options)
  @client = options.fetch(:client)
  @waiter = Aws::Waiters::Waiter.new({
    max_attempts: 5,
    delay: 30,
    poller: Aws::Waiters::Poller.new(
      operation_name: :get_plan_execution,
      acceptors: [
        {
          "matcher" => "path",
          "argument" => "execution_state",
          "state" => "success",
          "expected" => "completed"
        },
        {
          "matcher" => "path",
          "argument" => "execution_state",
          "state" => "success",
          "expected" => "completedWithExceptions"
        },
        {
          "matcher" => "path",
          "argument" => "execution_state",
          "state" => "failure",
          "expected" => "failed"
        },
        {
          "matcher" => "path",
          "argument" => "execution_state",
          "state" => "failure",
          "expected" => "canceled"
        },
        {
          "matcher" => "path",
          "argument" => "execution_state",
          "state" => "failure",
          "expected" => "planExecutionTimedOut"
        }
      ]
    )
  }.merge(options))
end

Instance Method Details

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

Returns a response object which responds to the following methods:

Parameters:

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

    a customizable set of options

Options Hash (params):

  • :plan_arn (required, String)

    The Amazon Resource Name (ARN) of the plan with the execution to retrieve.

  • :execution_id (required, String)

    The execution identifier of a plan execution.

  • :max_results (Integer)

    The number of objects that you want to return with this call.

  • :next_token (String)

    Specifies that you want to receive the next page of results. Valid only if you received a nextToken response in the previous request. If you did, it indicates that more output is available. Set this parameter to the value provided by the previous call's nextToken response to request the next page of results.

Returns:



180
181
182
# File 'gems/aws-sdk-arcregionswitch/lib/aws-sdk-arcregionswitch/waiters.rb', line 180

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