aws-sdk-mediaconnect 1.31.0 → 1.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-mediaconnect.rb +2 -1
- data/lib/aws-sdk-mediaconnect/client.rb +131 -2
- data/lib/aws-sdk-mediaconnect/client_api.rb +1 -0
- data/lib/aws-sdk-mediaconnect/types.rb +10 -0
- data/lib/aws-sdk-mediaconnect/waiters.rb +266 -0
- metadata +6 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 39c490d1bcd7ec754aaf25179fb8546eb531c5929782506541dd45a528fcef01
|
4
|
+
data.tar.gz: 1416cc4a3c334889bc2872369113f5796e3035019b84f3c5768229bc933c35d0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 15d6243c41e5adfd772ca9dc98f616cd620ede4c46433a86b651c40ab550d429480ec115f12c29820b47e6e76f07c96102fe963e0d71b180b14d086b8eee5634
|
7
|
+
data.tar.gz: 7da2bd25fd4d69a3547a450b6023810801b4a747e2ef60e5f14096227b5ef95e09d7bc7852321d4b5ca0e6df1d7e512028cb7bf805fa86a0a22205d1256a3e2b
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,11 @@
|
|
1
1
|
Unreleased Changes
|
2
2
|
------------------
|
3
3
|
|
4
|
+
1.32.0 (2021-04-14)
|
5
|
+
------------------
|
6
|
+
|
7
|
+
* Feature - For flows that use Listener protocols, you can now easily locate an output's outbound IP address for a private internet. Additionally, MediaConnect now supports the Waiters feature that makes it easier to poll for the status of a flow until it reaches its desired state.
|
8
|
+
|
4
9
|
1.31.0 (2021-03-16)
|
5
10
|
------------------
|
6
11
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.32.0
|
data/lib/aws-sdk-mediaconnect.rb
CHANGED
@@ -15,6 +15,7 @@ require_relative 'aws-sdk-mediaconnect/types'
|
|
15
15
|
require_relative 'aws-sdk-mediaconnect/client_api'
|
16
16
|
require_relative 'aws-sdk-mediaconnect/client'
|
17
17
|
require_relative 'aws-sdk-mediaconnect/errors'
|
18
|
+
require_relative 'aws-sdk-mediaconnect/waiters'
|
18
19
|
require_relative 'aws-sdk-mediaconnect/resource'
|
19
20
|
require_relative 'aws-sdk-mediaconnect/customizations'
|
20
21
|
|
@@ -48,6 +49,6 @@ require_relative 'aws-sdk-mediaconnect/customizations'
|
|
48
49
|
# @!group service
|
49
50
|
module Aws::MediaConnect
|
50
51
|
|
51
|
-
GEM_VERSION = '1.
|
52
|
+
GEM_VERSION = '1.32.0'
|
52
53
|
|
53
54
|
end
|
@@ -392,6 +392,7 @@ module Aws::MediaConnect
|
|
392
392
|
# resp.outputs[0].encryption.secret_arn #=> String
|
393
393
|
# resp.outputs[0].encryption.url #=> String
|
394
394
|
# resp.outputs[0].entitlement_arn #=> String
|
395
|
+
# resp.outputs[0].listener_address #=> String
|
395
396
|
# resp.outputs[0].media_live_input_arn #=> String
|
396
397
|
# resp.outputs[0].name #=> String
|
397
398
|
# resp.outputs[0].output_arn #=> String
|
@@ -736,6 +737,7 @@ module Aws::MediaConnect
|
|
736
737
|
# resp.flow.outputs[0].encryption.secret_arn #=> String
|
737
738
|
# resp.flow.outputs[0].encryption.url #=> String
|
738
739
|
# resp.flow.outputs[0].entitlement_arn #=> String
|
740
|
+
# resp.flow.outputs[0].listener_address #=> String
|
739
741
|
# resp.flow.outputs[0].media_live_input_arn #=> String
|
740
742
|
# resp.flow.outputs[0].name #=> String
|
741
743
|
# resp.flow.outputs[0].output_arn #=> String
|
@@ -910,6 +912,7 @@ module Aws::MediaConnect
|
|
910
912
|
# resp.flow.outputs[0].encryption.secret_arn #=> String
|
911
913
|
# resp.flow.outputs[0].encryption.url #=> String
|
912
914
|
# resp.flow.outputs[0].entitlement_arn #=> String
|
915
|
+
# resp.flow.outputs[0].listener_address #=> String
|
913
916
|
# resp.flow.outputs[0].media_live_input_arn #=> String
|
914
917
|
# resp.flow.outputs[0].name #=> String
|
915
918
|
# resp.flow.outputs[0].output_arn #=> String
|
@@ -993,6 +996,13 @@ module Aws::MediaConnect
|
|
993
996
|
# resp.messages.errors #=> Array
|
994
997
|
# resp.messages.errors[0] #=> String
|
995
998
|
#
|
999
|
+
#
|
1000
|
+
# The following waiters are defined for this operation (see {Client#wait_until} for detailed usage):
|
1001
|
+
#
|
1002
|
+
# * flow_active
|
1003
|
+
# * flow_deleted
|
1004
|
+
# * flow_standby
|
1005
|
+
#
|
996
1006
|
# @see http://docs.aws.amazon.com/goto/WebAPI/mediaconnect-2018-11-14/DescribeFlow AWS API Documentation
|
997
1007
|
#
|
998
1008
|
# @overload describe_flow(params = {})
|
@@ -1723,6 +1733,7 @@ module Aws::MediaConnect
|
|
1723
1733
|
# resp.flow.outputs[0].encryption.secret_arn #=> String
|
1724
1734
|
# resp.flow.outputs[0].encryption.url #=> String
|
1725
1735
|
# resp.flow.outputs[0].entitlement_arn #=> String
|
1736
|
+
# resp.flow.outputs[0].listener_address #=> String
|
1726
1737
|
# resp.flow.outputs[0].media_live_input_arn #=> String
|
1727
1738
|
# resp.flow.outputs[0].name #=> String
|
1728
1739
|
# resp.flow.outputs[0].output_arn #=> String
|
@@ -2001,6 +2012,7 @@ module Aws::MediaConnect
|
|
2001
2012
|
# resp.output.encryption.secret_arn #=> String
|
2002
2013
|
# resp.output.encryption.url #=> String
|
2003
2014
|
# resp.output.entitlement_arn #=> String
|
2015
|
+
# resp.output.listener_address #=> String
|
2004
2016
|
# resp.output.media_live_input_arn #=> String
|
2005
2017
|
# resp.output.name #=> String
|
2006
2018
|
# resp.output.output_arn #=> String
|
@@ -2162,14 +2174,131 @@ module Aws::MediaConnect
|
|
2162
2174
|
params: params,
|
2163
2175
|
config: config)
|
2164
2176
|
context[:gem_name] = 'aws-sdk-mediaconnect'
|
2165
|
-
context[:gem_version] = '1.
|
2177
|
+
context[:gem_version] = '1.32.0'
|
2166
2178
|
Seahorse::Client::Request.new(handlers, context)
|
2167
2179
|
end
|
2168
2180
|
|
2181
|
+
# Polls an API operation until a resource enters a desired state.
|
2182
|
+
#
|
2183
|
+
# ## Basic Usage
|
2184
|
+
#
|
2185
|
+
# A waiter will call an API operation until:
|
2186
|
+
#
|
2187
|
+
# * It is successful
|
2188
|
+
# * It enters a terminal state
|
2189
|
+
# * It makes the maximum number of attempts
|
2190
|
+
#
|
2191
|
+
# In between attempts, the waiter will sleep.
|
2192
|
+
#
|
2193
|
+
# # polls in a loop, sleeping between attempts
|
2194
|
+
# client.wait_until(waiter_name, params)
|
2195
|
+
#
|
2196
|
+
# ## Configuration
|
2197
|
+
#
|
2198
|
+
# You can configure the maximum number of polling attempts, and the
|
2199
|
+
# delay (in seconds) between each polling attempt. You can pass
|
2200
|
+
# configuration as the final arguments hash.
|
2201
|
+
#
|
2202
|
+
# # poll for ~25 seconds
|
2203
|
+
# client.wait_until(waiter_name, params, {
|
2204
|
+
# max_attempts: 5,
|
2205
|
+
# delay: 5,
|
2206
|
+
# })
|
2207
|
+
#
|
2208
|
+
# ## Callbacks
|
2209
|
+
#
|
2210
|
+
# You can be notified before each polling attempt and before each
|
2211
|
+
# delay. If you throw `:success` or `:failure` from these callbacks,
|
2212
|
+
# it will terminate the waiter.
|
2213
|
+
#
|
2214
|
+
# started_at = Time.now
|
2215
|
+
# client.wait_until(waiter_name, params, {
|
2216
|
+
#
|
2217
|
+
# # disable max attempts
|
2218
|
+
# max_attempts: nil,
|
2219
|
+
#
|
2220
|
+
# # poll for 1 hour, instead of a number of attempts
|
2221
|
+
# before_wait: -> (attempts, response) do
|
2222
|
+
# throw :failure if Time.now - started_at > 3600
|
2223
|
+
# end
|
2224
|
+
# })
|
2225
|
+
#
|
2226
|
+
# ## Handling Errors
|
2227
|
+
#
|
2228
|
+
# When a waiter is unsuccessful, it will raise an error.
|
2229
|
+
# All of the failure errors extend from
|
2230
|
+
# {Aws::Waiters::Errors::WaiterFailed}.
|
2231
|
+
#
|
2232
|
+
# begin
|
2233
|
+
# client.wait_until(...)
|
2234
|
+
# rescue Aws::Waiters::Errors::WaiterFailed
|
2235
|
+
# # resource did not enter the desired state in time
|
2236
|
+
# end
|
2237
|
+
#
|
2238
|
+
# ## Valid Waiters
|
2239
|
+
#
|
2240
|
+
# The following table lists the valid waiter names, the operations they call,
|
2241
|
+
# and the default `:delay` and `:max_attempts` values.
|
2242
|
+
#
|
2243
|
+
# | waiter_name | params | :delay | :max_attempts |
|
2244
|
+
# | ------------ | ---------------------- | -------- | ------------- |
|
2245
|
+
# | flow_active | {Client#describe_flow} | 3 | 40 |
|
2246
|
+
# | flow_deleted | {Client#describe_flow} | 3 | 40 |
|
2247
|
+
# | flow_standby | {Client#describe_flow} | 3 | 40 |
|
2248
|
+
#
|
2249
|
+
# @raise [Errors::FailureStateError] Raised when the waiter terminates
|
2250
|
+
# because the waiter has entered a state that it will not transition
|
2251
|
+
# out of, preventing success.
|
2252
|
+
#
|
2253
|
+
# @raise [Errors::TooManyAttemptsError] Raised when the configured
|
2254
|
+
# maximum number of attempts have been made, and the waiter is not
|
2255
|
+
# yet successful.
|
2256
|
+
#
|
2257
|
+
# @raise [Errors::UnexpectedError] Raised when an error is encounted
|
2258
|
+
# while polling for a resource that is not expected.
|
2259
|
+
#
|
2260
|
+
# @raise [Errors::NoSuchWaiterError] Raised when you request to wait
|
2261
|
+
# for an unknown state.
|
2262
|
+
#
|
2263
|
+
# @return [Boolean] Returns `true` if the waiter was successful.
|
2264
|
+
# @param [Symbol] waiter_name
|
2265
|
+
# @param [Hash] params ({})
|
2266
|
+
# @param [Hash] options ({})
|
2267
|
+
# @option options [Integer] :max_attempts
|
2268
|
+
# @option options [Integer] :delay
|
2269
|
+
# @option options [Proc] :before_attempt
|
2270
|
+
# @option options [Proc] :before_wait
|
2271
|
+
def wait_until(waiter_name, params = {}, options = {})
|
2272
|
+
w = waiter(waiter_name, options)
|
2273
|
+
yield(w.waiter) if block_given? # deprecated
|
2274
|
+
w.wait(params)
|
2275
|
+
end
|
2276
|
+
|
2169
2277
|
# @api private
|
2170
2278
|
# @deprecated
|
2171
2279
|
def waiter_names
|
2172
|
-
|
2280
|
+
waiters.keys
|
2281
|
+
end
|
2282
|
+
|
2283
|
+
private
|
2284
|
+
|
2285
|
+
# @param [Symbol] waiter_name
|
2286
|
+
# @param [Hash] options ({})
|
2287
|
+
def waiter(waiter_name, options = {})
|
2288
|
+
waiter_class = waiters[waiter_name]
|
2289
|
+
if waiter_class
|
2290
|
+
waiter_class.new(options.merge(client: self))
|
2291
|
+
else
|
2292
|
+
raise Aws::Waiters::Errors::NoSuchWaiterError.new(waiter_name, waiters.keys)
|
2293
|
+
end
|
2294
|
+
end
|
2295
|
+
|
2296
|
+
def waiters
|
2297
|
+
{
|
2298
|
+
flow_active: Waiters::FlowActive,
|
2299
|
+
flow_deleted: Waiters::FlowDeleted,
|
2300
|
+
flow_standby: Waiters::FlowStandby
|
2301
|
+
}
|
2173
2302
|
end
|
2174
2303
|
|
2175
2304
|
class << self
|
@@ -353,6 +353,7 @@ module Aws::MediaConnect
|
|
353
353
|
Output.add_member(:destination, Shapes::ShapeRef.new(shape: __string, location_name: "destination"))
|
354
354
|
Output.add_member(:encryption, Shapes::ShapeRef.new(shape: Encryption, location_name: "encryption"))
|
355
355
|
Output.add_member(:entitlement_arn, Shapes::ShapeRef.new(shape: __string, location_name: "entitlementArn"))
|
356
|
+
Output.add_member(:listener_address, Shapes::ShapeRef.new(shape: __string, location_name: "listenerAddress"))
|
356
357
|
Output.add_member(:media_live_input_arn, Shapes::ShapeRef.new(shape: __string, location_name: "mediaLiveInputArn"))
|
357
358
|
Output.add_member(:name, Shapes::ShapeRef.new(shape: __string, required: true, location_name: "name"))
|
358
359
|
Output.add_member(:output_arn, Shapes::ShapeRef.new(shape: __string, required: true, location_name: "outputArn"))
|
@@ -1533,6 +1533,15 @@ module Aws::MediaConnect
|
|
1533
1533
|
# is relevant only on entitled flows.
|
1534
1534
|
# @return [String]
|
1535
1535
|
#
|
1536
|
+
# @!attribute [rw] listener_address
|
1537
|
+
# The IP address that the receiver requires in order to establish a
|
1538
|
+
# connection with the flow. For public networking, the ListenerAddress
|
1539
|
+
# is represented by the elastic IP address of the flow. For private
|
1540
|
+
# networking, the ListenerAddress is represented by the elastic
|
1541
|
+
# network interface IP address of the VPC. This field applies only to
|
1542
|
+
# outputs that use the Zixi pull or SRT listener protocol.
|
1543
|
+
# @return [String]
|
1544
|
+
#
|
1536
1545
|
# @!attribute [rw] media_live_input_arn
|
1537
1546
|
# The input ARN of the AWS Elemental MediaLive channel. This parameter
|
1538
1547
|
# is relevant only for outputs that were added by creating a MediaLive
|
@@ -1569,6 +1578,7 @@ module Aws::MediaConnect
|
|
1569
1578
|
:destination,
|
1570
1579
|
:encryption,
|
1571
1580
|
:entitlement_arn,
|
1581
|
+
:listener_address,
|
1572
1582
|
:media_live_input_arn,
|
1573
1583
|
:name,
|
1574
1584
|
:output_arn,
|
@@ -0,0 +1,266 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
4
|
+
#
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
7
|
+
#
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
9
|
+
|
10
|
+
require 'aws-sdk-core/waiters'
|
11
|
+
|
12
|
+
module Aws::MediaConnect
|
13
|
+
# Waiters are utility methods that poll for a particular state to occur
|
14
|
+
# on a client. Waiters can fail after a number of attempts at a polling
|
15
|
+
# interval defined for the service client.
|
16
|
+
#
|
17
|
+
# For a list of operations that can be waited for and the
|
18
|
+
# client methods called for each operation, see the table below or the
|
19
|
+
# {Client#wait_until} field documentation for the {Client}.
|
20
|
+
#
|
21
|
+
# # Invoking a Waiter
|
22
|
+
# To invoke a waiter, call #wait_until on a {Client}. The first parameter
|
23
|
+
# is the waiter name, which is specific to the service client and indicates
|
24
|
+
# which operation is being waited for. The second parameter is a hash of
|
25
|
+
# parameters that are passed to the client method called by the waiter,
|
26
|
+
# which varies according to the waiter name.
|
27
|
+
#
|
28
|
+
# # Wait Failures
|
29
|
+
# To catch errors in a waiter, use WaiterFailed,
|
30
|
+
# as shown in the following example.
|
31
|
+
#
|
32
|
+
# rescue rescue Aws::Waiters::Errors::WaiterFailed => error
|
33
|
+
# puts "failed waiting for instance running: #{error.message}
|
34
|
+
# end
|
35
|
+
#
|
36
|
+
# # Configuring a Waiter
|
37
|
+
# Each waiter has a default polling interval and a maximum number of
|
38
|
+
# attempts it will make before returning control to your program.
|
39
|
+
# To set these values, use the `max_attempts` and `delay` parameters
|
40
|
+
# in your `#wait_until` call.
|
41
|
+
# The following example waits for up to 25 seconds, polling every five seconds.
|
42
|
+
#
|
43
|
+
# client.wait_until(...) do |w|
|
44
|
+
# w.max_attempts = 5
|
45
|
+
# w.delay = 5
|
46
|
+
# end
|
47
|
+
#
|
48
|
+
# To disable wait failures, set the value of either of these parameters
|
49
|
+
# to `nil`.
|
50
|
+
#
|
51
|
+
# # Extending a Waiter
|
52
|
+
# To modify the behavior of waiters, you can register callbacks that are
|
53
|
+
# triggered before each polling attempt and before waiting.
|
54
|
+
#
|
55
|
+
# The following example implements an exponential backoff in a waiter
|
56
|
+
# by doubling the amount of time to wait on every attempt.
|
57
|
+
#
|
58
|
+
# client.wait_until(...) do |w|
|
59
|
+
# w.interval = 0 # disable normal sleep
|
60
|
+
# w.before_wait do |n, resp|
|
61
|
+
# sleep(n ** 2)
|
62
|
+
# end
|
63
|
+
# end
|
64
|
+
#
|
65
|
+
# # Available Waiters
|
66
|
+
#
|
67
|
+
# The following table lists the valid waiter names, the operations they call,
|
68
|
+
# and the default `:delay` and `:max_attempts` values.
|
69
|
+
#
|
70
|
+
# | waiter_name | params | :delay | :max_attempts |
|
71
|
+
# | ------------ | ---------------------- | -------- | ------------- |
|
72
|
+
# | flow_active | {Client#describe_flow} | 3 | 40 |
|
73
|
+
# | flow_deleted | {Client#describe_flow} | 3 | 40 |
|
74
|
+
# | flow_standby | {Client#describe_flow} | 3 | 40 |
|
75
|
+
#
|
76
|
+
module Waiters
|
77
|
+
|
78
|
+
# Wait until a flow is active
|
79
|
+
class FlowActive
|
80
|
+
|
81
|
+
# @param [Hash] options
|
82
|
+
# @option options [required, Client] :client
|
83
|
+
# @option options [Integer] :max_attempts (40)
|
84
|
+
# @option options [Integer] :delay (3)
|
85
|
+
# @option options [Proc] :before_attempt
|
86
|
+
# @option options [Proc] :before_wait
|
87
|
+
def initialize(options)
|
88
|
+
@client = options.fetch(:client)
|
89
|
+
@waiter = Aws::Waiters::Waiter.new({
|
90
|
+
max_attempts: 40,
|
91
|
+
delay: 3,
|
92
|
+
poller: Aws::Waiters::Poller.new(
|
93
|
+
operation_name: :describe_flow,
|
94
|
+
acceptors: [
|
95
|
+
{
|
96
|
+
"state" => "success",
|
97
|
+
"matcher" => "path",
|
98
|
+
"argument" => "flow.status",
|
99
|
+
"expected" => "ACTIVE"
|
100
|
+
},
|
101
|
+
{
|
102
|
+
"state" => "retry",
|
103
|
+
"matcher" => "path",
|
104
|
+
"argument" => "flow.status",
|
105
|
+
"expected" => "STARTING"
|
106
|
+
},
|
107
|
+
{
|
108
|
+
"state" => "retry",
|
109
|
+
"matcher" => "path",
|
110
|
+
"argument" => "flow.status",
|
111
|
+
"expected" => "UPDATING"
|
112
|
+
},
|
113
|
+
{
|
114
|
+
"state" => "retry",
|
115
|
+
"matcher" => "status",
|
116
|
+
"expected" => 500
|
117
|
+
},
|
118
|
+
{
|
119
|
+
"state" => "retry",
|
120
|
+
"matcher" => "status",
|
121
|
+
"expected" => 503
|
122
|
+
},
|
123
|
+
{
|
124
|
+
"state" => "failure",
|
125
|
+
"matcher" => "path",
|
126
|
+
"argument" => "flow.status",
|
127
|
+
"expected" => "ERROR"
|
128
|
+
}
|
129
|
+
]
|
130
|
+
)
|
131
|
+
}.merge(options))
|
132
|
+
end
|
133
|
+
|
134
|
+
# @option (see Client#describe_flow)
|
135
|
+
# @return (see Client#describe_flow)
|
136
|
+
def wait(params = {})
|
137
|
+
@waiter.wait(client: @client, params: params)
|
138
|
+
end
|
139
|
+
|
140
|
+
# @api private
|
141
|
+
attr_reader :waiter
|
142
|
+
|
143
|
+
end
|
144
|
+
|
145
|
+
# Wait until a flow is deleted
|
146
|
+
class FlowDeleted
|
147
|
+
|
148
|
+
# @param [Hash] options
|
149
|
+
# @option options [required, Client] :client
|
150
|
+
# @option options [Integer] :max_attempts (40)
|
151
|
+
# @option options [Integer] :delay (3)
|
152
|
+
# @option options [Proc] :before_attempt
|
153
|
+
# @option options [Proc] :before_wait
|
154
|
+
def initialize(options)
|
155
|
+
@client = options.fetch(:client)
|
156
|
+
@waiter = Aws::Waiters::Waiter.new({
|
157
|
+
max_attempts: 40,
|
158
|
+
delay: 3,
|
159
|
+
poller: Aws::Waiters::Poller.new(
|
160
|
+
operation_name: :describe_flow,
|
161
|
+
acceptors: [
|
162
|
+
{
|
163
|
+
"state" => "success",
|
164
|
+
"matcher" => "status",
|
165
|
+
"expected" => 404
|
166
|
+
},
|
167
|
+
{
|
168
|
+
"state" => "retry",
|
169
|
+
"matcher" => "path",
|
170
|
+
"argument" => "flow.status",
|
171
|
+
"expected" => "DELETING"
|
172
|
+
},
|
173
|
+
{
|
174
|
+
"state" => "retry",
|
175
|
+
"matcher" => "status",
|
176
|
+
"expected" => 500
|
177
|
+
},
|
178
|
+
{
|
179
|
+
"state" => "retry",
|
180
|
+
"matcher" => "status",
|
181
|
+
"expected" => 503
|
182
|
+
},
|
183
|
+
{
|
184
|
+
"state" => "failure",
|
185
|
+
"matcher" => "path",
|
186
|
+
"argument" => "flow.status",
|
187
|
+
"expected" => "ERROR"
|
188
|
+
}
|
189
|
+
]
|
190
|
+
)
|
191
|
+
}.merge(options))
|
192
|
+
end
|
193
|
+
|
194
|
+
# @option (see Client#describe_flow)
|
195
|
+
# @return (see Client#describe_flow)
|
196
|
+
def wait(params = {})
|
197
|
+
@waiter.wait(client: @client, params: params)
|
198
|
+
end
|
199
|
+
|
200
|
+
# @api private
|
201
|
+
attr_reader :waiter
|
202
|
+
|
203
|
+
end
|
204
|
+
|
205
|
+
# Wait until a flow is in standby mode
|
206
|
+
class FlowStandby
|
207
|
+
|
208
|
+
# @param [Hash] options
|
209
|
+
# @option options [required, Client] :client
|
210
|
+
# @option options [Integer] :max_attempts (40)
|
211
|
+
# @option options [Integer] :delay (3)
|
212
|
+
# @option options [Proc] :before_attempt
|
213
|
+
# @option options [Proc] :before_wait
|
214
|
+
def initialize(options)
|
215
|
+
@client = options.fetch(:client)
|
216
|
+
@waiter = Aws::Waiters::Waiter.new({
|
217
|
+
max_attempts: 40,
|
218
|
+
delay: 3,
|
219
|
+
poller: Aws::Waiters::Poller.new(
|
220
|
+
operation_name: :describe_flow,
|
221
|
+
acceptors: [
|
222
|
+
{
|
223
|
+
"state" => "success",
|
224
|
+
"matcher" => "path",
|
225
|
+
"argument" => "flow.status",
|
226
|
+
"expected" => "STANDBY"
|
227
|
+
},
|
228
|
+
{
|
229
|
+
"state" => "retry",
|
230
|
+
"matcher" => "path",
|
231
|
+
"argument" => "flow.status",
|
232
|
+
"expected" => "STOPPING"
|
233
|
+
},
|
234
|
+
{
|
235
|
+
"state" => "retry",
|
236
|
+
"matcher" => "status",
|
237
|
+
"expected" => 500
|
238
|
+
},
|
239
|
+
{
|
240
|
+
"state" => "retry",
|
241
|
+
"matcher" => "status",
|
242
|
+
"expected" => 503
|
243
|
+
},
|
244
|
+
{
|
245
|
+
"state" => "failure",
|
246
|
+
"matcher" => "path",
|
247
|
+
"argument" => "flow.status",
|
248
|
+
"expected" => "ERROR"
|
249
|
+
}
|
250
|
+
]
|
251
|
+
)
|
252
|
+
}.merge(options))
|
253
|
+
end
|
254
|
+
|
255
|
+
# @option (see Client#describe_flow)
|
256
|
+
# @return (see Client#describe_flow)
|
257
|
+
def wait(params = {})
|
258
|
+
@waiter.wait(client: @client, params: params)
|
259
|
+
end
|
260
|
+
|
261
|
+
# @api private
|
262
|
+
attr_reader :waiter
|
263
|
+
|
264
|
+
end
|
265
|
+
end
|
266
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aws-sdk-mediaconnect
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.32.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Amazon Web Services
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-core
|
@@ -62,12 +62,13 @@ files:
|
|
62
62
|
- lib/aws-sdk-mediaconnect/errors.rb
|
63
63
|
- lib/aws-sdk-mediaconnect/resource.rb
|
64
64
|
- lib/aws-sdk-mediaconnect/types.rb
|
65
|
+
- lib/aws-sdk-mediaconnect/waiters.rb
|
65
66
|
homepage: https://github.com/aws/aws-sdk-ruby
|
66
67
|
licenses:
|
67
68
|
- Apache-2.0
|
68
69
|
metadata:
|
69
|
-
source_code_uri: https://github.com/aws/aws-sdk-ruby/tree/
|
70
|
-
changelog_uri: https://github.com/aws/aws-sdk-ruby/tree/
|
70
|
+
source_code_uri: https://github.com/aws/aws-sdk-ruby/tree/version-3/gems/aws-sdk-mediaconnect
|
71
|
+
changelog_uri: https://github.com/aws/aws-sdk-ruby/tree/version-3/gems/aws-sdk-mediaconnect/CHANGELOG.md
|
71
72
|
post_install_message:
|
72
73
|
rdoc_options: []
|
73
74
|
require_paths:
|
@@ -84,7 +85,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
84
85
|
version: '0'
|
85
86
|
requirements: []
|
86
87
|
rubyforge_project:
|
87
|
-
rubygems_version: 2.7.6.
|
88
|
+
rubygems_version: 2.7.6.3
|
88
89
|
signing_key:
|
89
90
|
specification_version: 4
|
90
91
|
summary: AWS SDK for Ruby - AWS MediaConnect
|