aws-sdk-neptune 1.31.0 → 1.32.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: 9efb7810bbe3f99aeb7dd4ec217c6a0ecb93c2c24e4878b65d9b272638910684
4
- data.tar.gz: 4b174d42488a3432222903abd89c52ae596ad5b935e3c8bdbb1b0b615dda8c40
3
+ metadata.gz: 2c3b3078224ce1c9935feb1cb501ede960fda4239af6c93d7fed8da8f5085f3b
4
+ data.tar.gz: de6545daf0075236064f43d343aa9233bb7148ff5d823f240bea6514f0e48343
5
5
  SHA512:
6
- metadata.gz: c405466678c858af0c5032c2999add4360b60f776732eeb963b929f54d98306b9cf8e180c0c051fc19023661069c00a23e3e2d6ea7a23bf94045c56ef81f43e9
7
- data.tar.gz: 65a96b099cfe4f005d86a465d2a0c3de94ed400398f7139f2538c89154f15f895a3a7b8e0479fd0b03b9767073e01808765b895d1133a099b4ba79adc665ad64
6
+ metadata.gz: 3ea8025a21f4e9e5a21a9cb9406403073fbd86db2636b121343904a5a6bc6b27cf76bbb826ff2e371e7782ac7790990c32cdd127149a4e1fc69ff889db0d6929
7
+ data.tar.gz: f08aa2a94c3cfed6c9dd0548440ae5c0a1832c23fbae5a11b9d47300c5a84236651a9b5d7105445be679feac98bc6fad78fc1c63a00bc673c61d488f119af348
@@ -49,6 +49,6 @@ require_relative 'aws-sdk-neptune/customizations'
49
49
  # @!group service
50
50
  module Aws::Neptune
51
51
 
52
- GEM_VERSION = '1.31.0'
52
+ GEM_VERSION = '1.32.0'
53
53
 
54
54
  end
@@ -29,6 +29,7 @@ require 'aws-sdk-core/plugins/transfer_encoding.rb'
29
29
  require 'aws-sdk-core/plugins/http_checksum.rb'
30
30
  require 'aws-sdk-core/plugins/signature_v4.rb'
31
31
  require 'aws-sdk-core/plugins/protocols/query.rb'
32
+ require 'aws-sdk-neptune/plugins/cross_region_copying.rb'
32
33
 
33
34
  Aws::Plugins::GlobalConfiguration.add_identifier(:neptune)
34
35
 
@@ -75,6 +76,7 @@ module Aws::Neptune
75
76
  add_plugin(Aws::Plugins::HttpChecksum)
76
77
  add_plugin(Aws::Plugins::SignatureV4)
77
78
  add_plugin(Aws::Plugins::Protocols::Query)
79
+ add_plugin(Aws::Neptune::Plugins::CrossRegionCopying)
78
80
 
79
81
  # @overload initialize(options)
80
82
  # @param [Hash] options
@@ -669,6 +671,10 @@ module Aws::Neptune
669
671
  # @option params [Array<Types::Tag>] :tags
670
672
  # The tags to assign to the new DB cluster snapshot copy.
671
673
  #
674
+ # @option params [String] :source_region
675
+ # The source region of the snapshot. This is only needed when the
676
+ # shapshot is encrypted and in a different region.
677
+ #
672
678
  # @return [Types::CopyDBClusterSnapshotResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
673
679
  #
674
680
  # * {Types::CopyDBClusterSnapshotResult#db_cluster_snapshot #db_cluster_snapshot} => Types::DBClusterSnapshot
@@ -687,6 +693,7 @@ module Aws::Neptune
687
693
  # value: "String",
688
694
  # },
689
695
  # ],
696
+ # source_region: "String",
690
697
  # })
691
698
  #
692
699
  # @example Response structure
@@ -1001,6 +1008,10 @@ module Aws::Neptune
1001
1008
  # enabled. The database can't be deleted when deletion protection is
1002
1009
  # enabled. By default, deletion protection is enabled.
1003
1010
  #
1011
+ # @option params [String] :source_region
1012
+ # The source region of the snapshot. This is only needed when the
1013
+ # shapshot is encrypted and in a different region.
1014
+ #
1004
1015
  # @return [Types::CreateDBClusterResult] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1005
1016
  #
1006
1017
  # * {Types::CreateDBClusterResult#db_cluster #db_cluster} => Types::DBCluster
@@ -1037,6 +1048,7 @@ module Aws::Neptune
1037
1048
  # enable_iam_database_authentication: false,
1038
1049
  # enable_cloudwatch_logs_exports: ["String"],
1039
1050
  # deletion_protection: false,
1051
+ # source_region: "String",
1040
1052
  # })
1041
1053
  #
1042
1054
  # @example Response structure
@@ -6730,7 +6742,7 @@ module Aws::Neptune
6730
6742
  params: params,
6731
6743
  config: config)
6732
6744
  context[:gem_name] = 'aws-sdk-neptune'
6733
- context[:gem_version] = '1.31.0'
6745
+ context[:gem_version] = '1.32.0'
6734
6746
  Seahorse::Client::Request.new(handlers, context)
6735
6747
  end
6736
6748
 
@@ -355,6 +355,7 @@ module Aws::Neptune
355
355
  CopyDBClusterSnapshotMessage.add_member(:pre_signed_url, Shapes::ShapeRef.new(shape: String, location_name: "PreSignedUrl"))
356
356
  CopyDBClusterSnapshotMessage.add_member(:copy_tags, Shapes::ShapeRef.new(shape: BooleanOptional, location_name: "CopyTags"))
357
357
  CopyDBClusterSnapshotMessage.add_member(:tags, Shapes::ShapeRef.new(shape: TagList, location_name: "Tags"))
358
+ CopyDBClusterSnapshotMessage.add_member(:source_region, Shapes::ShapeRef.new(shape: String, location_name: "SourceRegion"))
358
359
  CopyDBClusterSnapshotMessage.struct_class = Types::CopyDBClusterSnapshotMessage
359
360
 
360
361
  CopyDBClusterSnapshotResult.add_member(:db_cluster_snapshot, Shapes::ShapeRef.new(shape: DBClusterSnapshot, location_name: "DBClusterSnapshot"))
@@ -413,6 +414,7 @@ module Aws::Neptune
413
414
  CreateDBClusterMessage.add_member(:enable_iam_database_authentication, Shapes::ShapeRef.new(shape: BooleanOptional, location_name: "EnableIAMDatabaseAuthentication"))
414
415
  CreateDBClusterMessage.add_member(:enable_cloudwatch_logs_exports, Shapes::ShapeRef.new(shape: LogTypeList, location_name: "EnableCloudwatchLogsExports"))
415
416
  CreateDBClusterMessage.add_member(:deletion_protection, Shapes::ShapeRef.new(shape: BooleanOptional, location_name: "DeletionProtection"))
417
+ CreateDBClusterMessage.add_member(:source_region, Shapes::ShapeRef.new(shape: String, location_name: "SourceRegion"))
416
418
  CreateDBClusterMessage.struct_class = Types::CreateDBClusterMessage
417
419
 
418
420
  CreateDBClusterParameterGroupMessage.add_member(:db_cluster_parameter_group_name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "DBClusterParameterGroupName"))
@@ -0,0 +1,67 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'aws-sigv4'
4
+
5
+ module Aws
6
+ module Neptune
7
+ module Plugins
8
+ # This plugin populates the `:pre_signed_url` request param for APIs
9
+ # that support cross region copying.
10
+ #
11
+ # This parameter is required by RDS when copying an encrypted snapshot
12
+ # across regions. This plugin will be skipped if the `:pre_signed_url`
13
+ # parameter is provided by the user.
14
+ class CrossRegionCopying < Seahorse::Client::Plugin
15
+ # @api private
16
+ class Handler < Seahorse::Client::Handler
17
+ def call(context)
18
+ params = context.params
19
+ if params.is_a?(Hash) &&
20
+ params[:source_region] && !params[:pre_signed_url]
21
+ params[:pre_signed_url] = presigned_url(context, params)
22
+ end
23
+ @handler.call(context)
24
+ end
25
+
26
+ private
27
+
28
+ def presigned_url(context, params)
29
+ # :source_region is not modeled in the api
30
+ source_region = params.delete(:source_region)
31
+ param_list = Aws::Query::ParamList.new
32
+ param_list.set('Action', context.operation.name)
33
+ param_list.set('DestinationRegion', context.config.region)
34
+ param_list.set('Version', context.config.api.version)
35
+ Aws::Query::ParamBuilder.new(param_list).apply(
36
+ context.operation.input,
37
+ params
38
+ )
39
+ signer = Aws::Sigv4::Signer.new(
40
+ service: 'rds',
41
+ region: source_region,
42
+ credentials_provider: context.config.credentials
43
+ )
44
+ url = Aws::Partitions::EndpointProvider.resolve(
45
+ signer.region, 'rds'
46
+ )
47
+ url += "?#{param_list}"
48
+ signer.presign_url(
49
+ http_method: 'GET',
50
+ url: url,
51
+ expires_in: 3600
52
+ ).to_s
53
+ end
54
+ end
55
+
56
+ handler(
57
+ Handler,
58
+ step: :initialize,
59
+ operations: [
60
+ :copy_db_cluster_snapshot,
61
+ :create_db_cluster
62
+ ]
63
+ )
64
+ end
65
+ end
66
+ end
67
+ end
@@ -381,6 +381,7 @@ module Aws::Neptune
381
381
  # value: "String",
382
382
  # },
383
383
  # ],
384
+ # source_region: "String",
384
385
  # }
385
386
  #
386
387
  # @!attribute [rw] source_db_cluster_snapshot_identifier
@@ -450,6 +451,11 @@ module Aws::Neptune
450
451
  # The tags to assign to the new DB cluster snapshot copy.
451
452
  # @return [Array<Types::Tag>]
452
453
  #
454
+ # @!attribute [rw] source_region
455
+ # The source region of the snapshot. This is only needed when the
456
+ # shapshot is encrypted and in a different region.
457
+ # @return [String]
458
+ #
453
459
  # @see http://docs.aws.amazon.com/goto/WebAPI/neptune-2014-10-31/CopyDBClusterSnapshotMessage AWS API Documentation
454
460
  #
455
461
  class CopyDBClusterSnapshotMessage < Struct.new(
@@ -458,7 +464,8 @@ module Aws::Neptune
458
464
  :kms_key_id,
459
465
  :pre_signed_url,
460
466
  :copy_tags,
461
- :tags)
467
+ :tags,
468
+ :source_region)
462
469
  SENSITIVE = []
463
470
  include Aws::Structure
464
471
  end
@@ -737,6 +744,7 @@ module Aws::Neptune
737
744
  # enable_iam_database_authentication: false,
738
745
  # enable_cloudwatch_logs_exports: ["String"],
739
746
  # deletion_protection: false,
747
+ # source_region: "String",
740
748
  # }
741
749
  #
742
750
  # @!attribute [rw] availability_zones
@@ -957,6 +965,11 @@ module Aws::Neptune
957
965
  # protection is enabled. By default, deletion protection is enabled.
958
966
  # @return [Boolean]
959
967
  #
968
+ # @!attribute [rw] source_region
969
+ # The source region of the snapshot. This is only needed when the
970
+ # shapshot is encrypted and in a different region.
971
+ # @return [String]
972
+ #
960
973
  # @see http://docs.aws.amazon.com/goto/WebAPI/neptune-2014-10-31/CreateDBClusterMessage AWS API Documentation
961
974
  #
962
975
  class CreateDBClusterMessage < Struct.new(
@@ -983,7 +996,8 @@ module Aws::Neptune
983
996
  :pre_signed_url,
984
997
  :enable_iam_database_authentication,
985
998
  :enable_cloudwatch_logs_exports,
986
- :deletion_protection)
999
+ :deletion_protection,
1000
+ :source_region)
987
1001
  SENSITIVE = []
988
1002
  include Aws::Structure
989
1003
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-neptune
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.31.0
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: 2020-10-26 00:00:00.000000000 Z
11
+ date: 2020-12-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -57,6 +57,7 @@ files:
57
57
  - lib/aws-sdk-neptune/client_api.rb
58
58
  - lib/aws-sdk-neptune/customizations.rb
59
59
  - lib/aws-sdk-neptune/errors.rb
60
+ - lib/aws-sdk-neptune/plugins/cross_region_copying.rb
60
61
  - lib/aws-sdk-neptune/resource.rb
61
62
  - lib/aws-sdk-neptune/types.rb
62
63
  - lib/aws-sdk-neptune/waiters.rb