aws-sdk-polly 1.46.0 → 1.50.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 85e2a51d1b532ebca166ded32dc097a117605a594ae5d3c20edac2d0bc0f3b7f
4
- data.tar.gz: b3c719fe03aae01254e0984708c2b0d14d5330de49e73df662a9d1eea6127418
3
+ metadata.gz: c94a39ba6901a56ea2f26dec7ed612c3ec890d56750658aaf9b2a2f07f66e8b0
4
+ data.tar.gz: 59439a6ac29581e9516cb1079766897e41d8b0a31298b073222b001457443f20
5
5
  SHA512:
6
- metadata.gz: eff945ecd0a7955d74fb0a7601b77c24dd5ea39d3e981d22dc3baae6fa72c8ed30c1ce94a8398014758a1f231be2cc6ae4ca9cd74b41c2136e5c9e00bdce7a4c
7
- data.tar.gz: 261a73d502e18e3831f94f745b8a52cafb68ad44f1be00a0d3b1e1339b566f36b09a1fd0586ba87b2a92a0b0fabc71096bb0ac0ab112fe0b169baa3492f73757
6
+ metadata.gz: 19965e9d37e74214743dbab32cd9f204af177d9208ee1d0b866a882b6678677410db38223dc001bc062c549ee3ad11514aeca32cd0bb3513f748a6dc44dc1a2e
7
+ data.tar.gz: 39f1f7d114f9c3b7504b50882a082874ccaf645c878f18bd8ebd999ed88eca0530238397217e46a4f3445af49a3c74997e6d3eadb08a63ebdf40332e4df62461
data/CHANGELOG.md CHANGED
@@ -1,6 +1,26 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.50.0 (2021-11-30)
5
+ ------------------
6
+
7
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
8
+
9
+ 1.49.0 (2021-11-18)
10
+ ------------------
11
+
12
+ * Feature - Allow `Aws::Polly::Presigner` to take a `:client` with FIPS or Dualstack configuration.
13
+
14
+ 1.48.0 (2021-11-04)
15
+ ------------------
16
+
17
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
18
+
19
+ 1.47.0 (2021-10-18)
20
+ ------------------
21
+
22
+ * Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
23
+
4
24
  1.46.0 (2021-09-01)
5
25
  ------------------
6
26
 
@@ -305,4 +325,4 @@ Unreleased Changes
305
325
  1.0.0.rc2 (2016-12-09)
306
326
  ------------------
307
327
 
308
- * Feature - Initial release of `aws-sdk-polly`.
328
+ * Feature - Initial release of `aws-sdk-polly`.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.46.0
1
+ 1.50.0
@@ -119,7 +119,9 @@ module Aws::Polly
119
119
  # * EC2/ECS IMDS instance profile - When used by default, the timeouts
120
120
  # are very aggressive. Construct and pass an instance of
121
121
  # `Aws::InstanceProfileCredentails` or `Aws::ECSCredentials` to
122
- # enable retries and extended timeouts.
122
+ # enable retries and extended timeouts. Instance profile credential
123
+ # fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED']
124
+ # to true.
123
125
  #
124
126
  # @option options [required, String] :region
125
127
  # The AWS region to connect to. The configured `:region` is
@@ -275,6 +277,15 @@ module Aws::Polly
275
277
  # ** Please note ** When response stubbing is enabled, no HTTP
276
278
  # requests are made, and retries are disabled.
277
279
  #
280
+ # @option options [Boolean] :use_dualstack_endpoint
281
+ # When set to `true`, dualstack enabled endpoints (with `.aws` TLD)
282
+ # will be used if available.
283
+ #
284
+ # @option options [Boolean] :use_fips_endpoint
285
+ # When set to `true`, fips compatible endpoints will be used if available.
286
+ # When a `fips` region is used, the region is normalized and this config
287
+ # is set to `true`.
288
+ #
278
289
  # @option options [Boolean] :validate_params (true)
279
290
  # When `true`, request parameters are validated before
280
291
  # sending the request.
@@ -1088,7 +1099,7 @@ module Aws::Polly
1088
1099
  params: params,
1089
1100
  config: config)
1090
1101
  context[:gem_name] = 'aws-sdk-polly'
1091
- context[:gem_version] = '1.46.0'
1102
+ context[:gem_version] = '1.50.0'
1092
1103
  Seahorse::Client::Request.new(handlers, context)
1093
1104
  end
1094
1105
 
@@ -18,10 +18,13 @@ module Aws
18
18
  #
19
19
  class Presigner
20
20
 
21
- # @option options [required, Credentials] :credentials
22
- # You need provide an object that responds to `#credentials`
23
- # returning another object that responds to `#access_key_id`, `#secret_access_key`,
24
- # and `#session_token`.
21
+ # @option options [Client] :client Optionally provide an existing Polly
22
+ # client.
23
+ #
24
+ # @option options [Credentials] :credentials This option is deprecated,
25
+ # please use :client instead. Provide an object that responds to
26
+ # `#credentials` that returns another object that responds to
27
+ # `#access_key_id`, `#secret_access_key`, and `#session_token`.
25
28
  #
26
29
  # For example, you could provide an instance of following classes:
27
30
  # * `Aws::Credentials`
@@ -30,34 +33,42 @@ module Aws
30
33
  # * `Aws::AssumeRoleCredentials`
31
34
  # * `Aws::ECSCredentials`
32
35
  #
33
- # @option options [required, string] :region
34
- # The region name, e.g. 'us-west-2'
36
+ # @option options [String] :region This option is deprecated, please use
37
+ # :client instead. The region name, e.g. 'us-west-2'.
38
+ #
35
39
  def initialize(options = {})
36
- @credentials = options.fetch(:credentials)
37
- @region = options.fetch(:region)
40
+ if !(options.keys - [:credentials, :region, :client]).empty?
41
+ raise ArgumentError,
42
+ ':options may only contain :client, :region, :credentials '\
43
+ 'keys. Please use the :client option instead.'
44
+ end
45
+ @client = options[:client] || Aws::Polly::Client.new(options)
38
46
  end
39
47
 
40
- # @param [Hash] params parameter inputs for synthesize_speech operation
48
+ # @param [Hash] params Parameter inputs for {Client#synthesize_speech}
49
+ # operation.
41
50
  def synthesize_speech_presigned_url(params = {})
42
- input_shape = Client.api.operation(:synthesize_speech).input.shape
43
- sign_but_dont_send(input_shape, params)
44
- end
51
+ req = @client.build_request(:synthesize_speech, params)
45
52
 
46
- private
47
-
48
- def sign_but_dont_send(input_shape, params)
49
53
  parts = []
50
- input_shape.members.each do |name, ref|
54
+ req.context.operation.input.shape.members.each do |name, ref|
51
55
  parts << [ ref, params[name] ] unless params[name].nil?
52
56
  end
53
57
  query = Aws::Rest::Request::QuerystringBuilder.new.build(parts)
54
58
 
55
59
  signer = Aws::Sigv4::Signer.new(
56
60
  service: 'polly',
57
- region: @region,
58
- credentials_provider: @credentials
61
+ region: req.context.config.region,
62
+ credentials_provider: req.context.config.credentials
63
+ )
64
+
65
+ url = Aws::Partitions::EndpointProvider.resolve(
66
+ signer.region, 'polly', 'regional',
67
+ {
68
+ dualstack: req.context.config.use_dualstack_endpoint,
69
+ fips: req.context.config.use_fips_endpoint
70
+ }
59
71
  )
60
- url = Aws::Partitions::EndpointProvider.resolve(signer.region, 'polly')
61
72
  url += "/v1/speech?#{query}"
62
73
  pre_signed_url = signer.presign_url(
63
74
  http_method: 'GET',
data/lib/aws-sdk-polly.rb CHANGED
@@ -48,6 +48,6 @@ require_relative 'aws-sdk-polly/customizations'
48
48
  # @!group service
49
49
  module Aws::Polly
50
50
 
51
- GEM_VERSION = '1.46.0'
51
+ GEM_VERSION = '1.50.0'
52
52
 
53
53
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-polly
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.46.0
4
+ version: 1.50.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-09-01 00:00:00.000000000 Z
11
+ date: 2021-11-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '3'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 3.120.0
22
+ version: 3.122.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: '3'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 3.120.0
32
+ version: 3.122.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement