aws-sdk-rds 1.0.0.rc2 → 1.0.0.rc3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/lib/aws-sdk-rds.rb +2 -2
  3. data/lib/aws-sdk-rds/account_quota.rb +79 -81
  4. data/lib/aws-sdk-rds/certificate.rb +99 -101
  5. data/lib/aws-sdk-rds/client.rb +10575 -9119
  6. data/lib/aws-sdk-rds/client_api.rb +3049 -3023
  7. data/lib/aws-sdk-rds/db_cluster.rb +1005 -1007
  8. data/lib/aws-sdk-rds/db_cluster_parameter_group.rb +204 -206
  9. data/lib/aws-sdk-rds/db_cluster_snapshot.rb +430 -432
  10. data/lib/aws-sdk-rds/db_engine.rb +208 -210
  11. data/lib/aws-sdk-rds/db_engine_version.rb +218 -219
  12. data/lib/aws-sdk-rds/db_instance.rb +2747 -2567
  13. data/lib/aws-sdk-rds/db_log_file.rb +145 -147
  14. data/lib/aws-sdk-rds/db_parameter_group.rb +411 -413
  15. data/lib/aws-sdk-rds/db_parameter_group_family.rb +135 -137
  16. data/lib/aws-sdk-rds/db_security_group.rb +316 -318
  17. data/lib/aws-sdk-rds/db_snapshot.rb +705 -650
  18. data/lib/aws-sdk-rds/db_snapshot_attribute.rb +137 -139
  19. data/lib/aws-sdk-rds/db_subnet_group.rb +161 -163
  20. data/lib/aws-sdk-rds/errors.rb +4 -13
  21. data/lib/aws-sdk-rds/event.rb +108 -110
  22. data/lib/aws-sdk-rds/event_category_map.rb +73 -75
  23. data/lib/aws-sdk-rds/event_subscription.rb +313 -315
  24. data/lib/aws-sdk-rds/option_group.rb +247 -249
  25. data/lib/aws-sdk-rds/option_group_option.rb +135 -137
  26. data/lib/aws-sdk-rds/parameter.rb +116 -118
  27. data/lib/aws-sdk-rds/pending_maintenance_action.rb +182 -184
  28. data/lib/aws-sdk-rds/plugins/cross_region_copying.rb +64 -0
  29. data/lib/aws-sdk-rds/reserved_db_instance.rb +156 -158
  30. data/lib/aws-sdk-rds/reserved_db_instances_offering.rb +154 -156
  31. data/lib/aws-sdk-rds/resource.rb +2395 -2288
  32. data/lib/aws-sdk-rds/resource_pending_maintenance_action_list.rb +89 -91
  33. data/lib/aws-sdk-rds/types.rb +12091 -10977
  34. data/lib/aws-sdk-rds/waiters.rb +127 -128
  35. metadata +3 -2
@@ -1,23 +1,14 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module RDS
10
- module Errors
8
+ module Aws::RDS
9
+ module Errors
11
10
 
12
- extend Aws::Errors::DynamicErrors
11
+ extend Aws::Errors::DynamicErrors
13
12
 
14
- # Raised when calling #load or #data on a resource class that can not be
15
- # loaded. This can happen when:
16
- #
17
- # * A resource class has identifiers, but no data attributes.
18
- # * Resource data is only available when making an API call that
19
- # enumerates all resources of that type.
20
- class ResourceNotLoadable < RuntimeError; end
21
- end
22
13
  end
23
14
  end
@@ -1,134 +1,132 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module RDS
10
- class Event
11
-
12
- extend Aws::Deprecations
13
-
14
- # @overload def initialize(source_id, date, options = {})
15
- # @param [String] source_id
16
- # @param [String] date
17
- # @option options [Client] :client
18
- # @overload def initialize(options = {})
19
- # @option options [required, String] :source_id
20
- # @option options [required, String] :date
21
- # @option options [Client] :client
22
- def initialize(*args)
23
- options = Hash === args.last ? args.pop.dup : {}
24
- @source_id = extract_source_id(args, options)
25
- @date = extract_date(args, options)
26
- @data = options.delete(:data)
27
- @client = options.delete(:client) || Client.new(options)
28
- end
8
+ module Aws::RDS
9
+ class Event
10
+
11
+ extend Aws::Deprecations
12
+
13
+ # @overload def initialize(source_id, date, options = {})
14
+ # @param [String] source_id
15
+ # @param [String] date
16
+ # @option options [Client] :client
17
+ # @overload def initialize(options = {})
18
+ # @option options [required, String] :source_id
19
+ # @option options [required, String] :date
20
+ # @option options [Client] :client
21
+ def initialize(*args)
22
+ options = Hash === args.last ? args.pop.dup : {}
23
+ @source_id = extract_source_id(args, options)
24
+ @date = extract_date(args, options)
25
+ @data = options.delete(:data)
26
+ @client = options.delete(:client) || Client.new(options)
27
+ end
29
28
 
30
- # @!group Read-Only Attributes
29
+ # @!group Read-Only Attributes
31
30
 
32
- # @return [String]
33
- def source_id
34
- @source_id
35
- end
36
- alias :source_identifier :source_id
31
+ # @return [String]
32
+ def source_id
33
+ @source_id
34
+ end
35
+ alias :source_identifier :source_id
37
36
 
38
- # @return [String]
39
- def date
40
- @date
41
- end
37
+ # @return [String]
38
+ def date
39
+ @date
40
+ end
42
41
 
43
- # Specifies the source type for this event.
44
- # @return [String]
45
- def source_type
46
- data.source_type
47
- end
42
+ # Specifies the source type for this event.
43
+ # @return [String]
44
+ def source_type
45
+ data.source_type
46
+ end
48
47
 
49
- # Provides the text of this event.
50
- # @return [String]
51
- def message
52
- data.message
53
- end
48
+ # Provides the text of this event.
49
+ # @return [String]
50
+ def message
51
+ data.message
52
+ end
54
53
 
55
- # Specifies the category for the event.
56
- # @return [Array<String>]
57
- def event_categories
58
- data.event_categories
59
- end
54
+ # Specifies the category for the event.
55
+ # @return [Array<String>]
56
+ def event_categories
57
+ data.event_categories
58
+ end
60
59
 
61
- # The Amazon Resource Name (ARN) for the event.
62
- # @return [String]
63
- def source_arn
64
- data.source_arn
65
- end
60
+ # The Amazon Resource Name (ARN) for the event.
61
+ # @return [String]
62
+ def source_arn
63
+ data.source_arn
64
+ end
66
65
 
67
- # @!endgroup
66
+ # @!endgroup
68
67
 
69
- # @return [Client]
70
- def client
71
- @client
72
- end
68
+ # @return [Client]
69
+ def client
70
+ @client
71
+ end
73
72
 
74
- # @raise [Errors::ResourceNotLoadable]
75
- # @api private
76
- def load
77
- msg = "#load is not implemented, data only available via enumeration"
78
- raise Errors::ResourceNotLoadable, msg
79
- end
80
- alias :reload :load
81
-
82
- # @raise [Errors::ResourceNotLoadableError] Raises when {#data_loaded?} is `false`.
83
- # @return [Types::Event]
84
- # Returns the data for this {Event}.
85
- def data
86
- load unless @data
87
- @data
88
- end
73
+ # @raise [NotImplementedError]
74
+ # @api private
75
+ def load
76
+ msg = "#load is not implemented, data only available via enumeration"
77
+ raise NotImplementedError, msg
78
+ end
79
+ alias :reload :load
80
+
81
+ # @raise [NotImplementedError] Raises when {#data_loaded?} is `false`.
82
+ # @return [Types::Event]
83
+ # Returns the data for this {Event}.
84
+ def data
85
+ load unless @data
86
+ @data
87
+ end
89
88
 
90
- # @return [Boolean]
91
- # Returns `true` if this resource is loaded. Accessing attributes or
92
- # {#data} on an unloaded resource will trigger a call to {#load}.
93
- def data_loaded?
94
- !!@data
95
- end
89
+ # @return [Boolean]
90
+ # Returns `true` if this resource is loaded. Accessing attributes or
91
+ # {#data} on an unloaded resource will trigger a call to {#load}.
92
+ def data_loaded?
93
+ !!@data
94
+ end
96
95
 
97
- # @deprecated
98
- # @api private
99
- def identifiers
100
- {
101
- source_id: @source_id,
102
- date: @date
103
- }
104
- end
105
- deprecated(:identifiers)
106
-
107
- private
108
-
109
- def extract_source_id(args, options)
110
- value = args[0] || options.delete(:source_id)
111
- case value
112
- when String then value
113
- when nil then raise ArgumentError, "missing required option :source_id"
114
- else
115
- msg = "expected :source_id to be a String, got #{value.class}"
116
- raise ArgumentError, msg
117
- end
96
+ # @deprecated
97
+ # @api private
98
+ def identifiers
99
+ {
100
+ source_id: @source_id,
101
+ date: @date
102
+ }
103
+ end
104
+ deprecated(:identifiers)
105
+
106
+ private
107
+
108
+ def extract_source_id(args, options)
109
+ value = args[0] || options.delete(:source_id)
110
+ case value
111
+ when String then value
112
+ when nil then raise ArgumentError, "missing required option :source_id"
113
+ else
114
+ msg = "expected :source_id to be a String, got #{value.class}"
115
+ raise ArgumentError, msg
118
116
  end
117
+ end
119
118
 
120
- def extract_date(args, options)
121
- value = args[1] || options.delete(:date)
122
- case value
123
- when String then value
124
- when nil then raise ArgumentError, "missing required option :date"
125
- else
126
- msg = "expected :date to be a String, got #{value.class}"
127
- raise ArgumentError, msg
128
- end
119
+ def extract_date(args, options)
120
+ value = args[1] || options.delete(:date)
121
+ case value
122
+ when String then value
123
+ when nil then raise ArgumentError, "missing required option :date"
124
+ else
125
+ msg = "expected :date to be a String, got #{value.class}"
126
+ raise ArgumentError, msg
129
127
  end
130
-
131
- class Collection < Aws::Resources::Collection; end
132
128
  end
129
+
130
+ class Collection < Aws::Resources::Collection; end
133
131
  end
134
132
  end
@@ -1,98 +1,96 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module RDS
10
- class EventCategoryMap
8
+ module Aws::RDS
9
+ class EventCategoryMap
11
10
 
12
- extend Aws::Deprecations
11
+ extend Aws::Deprecations
13
12
 
14
- # @overload def initialize(source_type, options = {})
15
- # @param [String] source_type
16
- # @option options [Client] :client
17
- # @overload def initialize(options = {})
18
- # @option options [required, String] :source_type
19
- # @option options [Client] :client
20
- def initialize(*args)
21
- options = Hash === args.last ? args.pop.dup : {}
22
- @source_type = extract_source_type(args, options)
23
- @data = options.delete(:data)
24
- @client = options.delete(:client) || Client.new(options)
25
- end
13
+ # @overload def initialize(source_type, options = {})
14
+ # @param [String] source_type
15
+ # @option options [Client] :client
16
+ # @overload def initialize(options = {})
17
+ # @option options [required, String] :source_type
18
+ # @option options [Client] :client
19
+ def initialize(*args)
20
+ options = Hash === args.last ? args.pop.dup : {}
21
+ @source_type = extract_source_type(args, options)
22
+ @data = options.delete(:data)
23
+ @client = options.delete(:client) || Client.new(options)
24
+ end
26
25
 
27
- # @!group Read-Only Attributes
26
+ # @!group Read-Only Attributes
28
27
 
29
- # @return [String]
30
- def source_type
31
- @source_type
32
- end
28
+ # @return [String]
29
+ def source_type
30
+ @source_type
31
+ end
33
32
 
34
- # The event categories for the specified source type
35
- # @return [Array<String>]
36
- def event_categories
37
- data.event_categories
38
- end
33
+ # The event categories for the specified source type
34
+ # @return [Array<String>]
35
+ def event_categories
36
+ data.event_categories
37
+ end
39
38
 
40
- # @!endgroup
39
+ # @!endgroup
41
40
 
42
- # @return [Client]
43
- def client
44
- @client
45
- end
41
+ # @return [Client]
42
+ def client
43
+ @client
44
+ end
46
45
 
47
- # Loads, or reloads {#data} for the current {EventCategoryMap}.
48
- # Returns `self` making it possible to chain methods.
49
- #
50
- # event_category_map.reload.data
51
- #
52
- # @return [self]
53
- def load
54
- resp = @client.describe_event_categories(source_type: @name)
55
- @data = resp.eventcategoriesmaplist[0]
56
- self
57
- end
58
- alias :reload :load
46
+ # Loads, or reloads {#data} for the current {EventCategoryMap}.
47
+ # Returns `self` making it possible to chain methods.
48
+ #
49
+ # event_category_map.reload.data
50
+ #
51
+ # @return [self]
52
+ def load
53
+ resp = @client.describe_event_categories(source_type: @name)
54
+ @data = resp.eventcategoriesmaplist[0]
55
+ self
56
+ end
57
+ alias :reload :load
59
58
 
60
- # @return [Types::EventCategoriesMap]
61
- # Returns the data for this {EventCategoryMap}. Calls
62
- # {Client#describe_event_categories} if {#data_loaded?} is `false`.
63
- def data
64
- load unless @data
65
- @data
66
- end
59
+ # @return [Types::EventCategoriesMap]
60
+ # Returns the data for this {EventCategoryMap}. Calls
61
+ # {Client#describe_event_categories} if {#data_loaded?} is `false`.
62
+ def data
63
+ load unless @data
64
+ @data
65
+ end
67
66
 
68
- # @return [Boolean]
69
- # Returns `true` if this resource is loaded. Accessing attributes or
70
- # {#data} on an unloaded resource will trigger a call to {#load}.
71
- def data_loaded?
72
- !!@data
73
- end
67
+ # @return [Boolean]
68
+ # Returns `true` if this resource is loaded. Accessing attributes or
69
+ # {#data} on an unloaded resource will trigger a call to {#load}.
70
+ def data_loaded?
71
+ !!@data
72
+ end
74
73
 
75
- # @deprecated
76
- # @api private
77
- def identifiers
78
- { source_type: @source_type }
79
- end
80
- deprecated(:identifiers)
74
+ # @deprecated
75
+ # @api private
76
+ def identifiers
77
+ { source_type: @source_type }
78
+ end
79
+ deprecated(:identifiers)
81
80
 
82
- private
81
+ private
83
82
 
84
- def extract_source_type(args, options)
85
- value = args[0] || options.delete(:source_type)
86
- case value
87
- when String then value
88
- when nil then raise ArgumentError, "missing required option :source_type"
89
- else
90
- msg = "expected :source_type to be a String, got #{value.class}"
91
- raise ArgumentError, msg
92
- end
83
+ def extract_source_type(args, options)
84
+ value = args[0] || options.delete(:source_type)
85
+ case value
86
+ when String then value
87
+ when nil then raise ArgumentError, "missing required option :source_type"
88
+ else
89
+ msg = "expected :source_type to be a String, got #{value.class}"
90
+ raise ArgumentError, msg
93
91
  end
94
-
95
- class Collection < Aws::Resources::Collection; end
96
92
  end
93
+
94
+ class Collection < Aws::Resources::Collection; end
97
95
  end
98
96
  end
@@ -1,352 +1,350 @@
1
1
  # WARNING ABOUT GENERATED CODE
2
2
  #
3
- # This file is generated. See the contributing for info on making contributions:
3
+ # This file is generated. See the contributing guide for more information:
4
4
  # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
5
  #
6
6
  # WARNING ABOUT GENERATED CODE
7
7
 
8
- module Aws
9
- module RDS
10
- class EventSubscription
8
+ module Aws::RDS
9
+ class EventSubscription
11
10
 
12
- extend Aws::Deprecations
11
+ extend Aws::Deprecations
13
12
 
14
- # @overload def initialize(name, options = {})
15
- # @param [String] name
16
- # @option options [Client] :client
17
- # @overload def initialize(options = {})
18
- # @option options [required, String] :name
19
- # @option options [Client] :client
20
- def initialize(*args)
21
- options = Hash === args.last ? args.pop.dup : {}
22
- @name = extract_name(args, options)
23
- @data = options.delete(:data)
24
- @client = options.delete(:client) || Client.new(options)
25
- end
13
+ # @overload def initialize(name, options = {})
14
+ # @param [String] name
15
+ # @option options [Client] :client
16
+ # @overload def initialize(options = {})
17
+ # @option options [required, String] :name
18
+ # @option options [Client] :client
19
+ def initialize(*args)
20
+ options = Hash === args.last ? args.pop.dup : {}
21
+ @name = extract_name(args, options)
22
+ @data = options.delete(:data)
23
+ @client = options.delete(:client) || Client.new(options)
24
+ end
26
25
 
27
- # @!group Read-Only Attributes
26
+ # @!group Read-Only Attributes
28
27
 
29
- # @return [String]
30
- def name
31
- @name
32
- end
33
- alias :cust_subscription_id :name
28
+ # @return [String]
29
+ def name
30
+ @name
31
+ end
32
+ alias :cust_subscription_id :name
34
33
 
35
- # The AWS customer account associated with the RDS event notification
36
- # subscription.
37
- # @return [String]
38
- def customer_aws_id
39
- data.customer_aws_id
40
- end
34
+ # The AWS customer account associated with the RDS event notification
35
+ # subscription.
36
+ # @return [String]
37
+ def customer_aws_id
38
+ data.customer_aws_id
39
+ end
41
40
 
42
- # The topic ARN of the RDS event notification subscription.
43
- # @return [String]
44
- def sns_topic_arn
45
- data.sns_topic_arn
46
- end
41
+ # The topic ARN of the RDS event notification subscription.
42
+ # @return [String]
43
+ def sns_topic_arn
44
+ data.sns_topic_arn
45
+ end
47
46
 
48
- # The status of the RDS event notification subscription.
49
- #
50
- # Constraints:
51
- #
52
- # Can be one of the following: creating \| modifying \| deleting \|
53
- # active \| no-permission \| topic-not-exist
54
- #
55
- # The status "no-permission" indicates that RDS no longer has
56
- # permission to post to the SNS topic. The status "topic-not-exist"
57
- # indicates that the topic was deleted after the subscription was
58
- # created.
59
- # @return [String]
60
- def status
61
- data.status
62
- end
47
+ # The status of the RDS event notification subscription.
48
+ #
49
+ # Constraints:
50
+ #
51
+ # Can be one of the following: creating \| modifying \| deleting \|
52
+ # active \| no-permission \| topic-not-exist
53
+ #
54
+ # The status "no-permission" indicates that RDS no longer has
55
+ # permission to post to the SNS topic. The status "topic-not-exist"
56
+ # indicates that the topic was deleted after the subscription was
57
+ # created.
58
+ # @return [String]
59
+ def status
60
+ data.status
61
+ end
63
62
 
64
- # The time the RDS event notification subscription was created.
65
- # @return [String]
66
- def subscription_creation_time
67
- data.subscription_creation_time
68
- end
63
+ # The time the RDS event notification subscription was created.
64
+ # @return [String]
65
+ def subscription_creation_time
66
+ data.subscription_creation_time
67
+ end
69
68
 
70
- # The source type for the RDS event notification subscription.
71
- # @return [String]
72
- def source_type
73
- data.source_type
74
- end
69
+ # The source type for the RDS event notification subscription.
70
+ # @return [String]
71
+ def source_type
72
+ data.source_type
73
+ end
75
74
 
76
- # A list of source IDs for the RDS event notification subscription.
77
- # @return [Array<String>]
78
- def source_ids_list
79
- data.source_ids_list
80
- end
75
+ # A list of source IDs for the RDS event notification subscription.
76
+ # @return [Array<String>]
77
+ def source_ids_list
78
+ data.source_ids_list
79
+ end
81
80
 
82
- # A list of event categories for the RDS event notification
83
- # subscription.
84
- # @return [Array<String>]
85
- def event_categories_list
86
- data.event_categories_list
87
- end
81
+ # A list of event categories for the RDS event notification
82
+ # subscription.
83
+ # @return [Array<String>]
84
+ def event_categories_list
85
+ data.event_categories_list
86
+ end
88
87
 
89
- # A Boolean value indicating if the subscription is enabled. True
90
- # indicates the subscription is enabled.
91
- # @return [Boolean]
92
- def enabled
93
- data.enabled
94
- end
88
+ # A Boolean value indicating if the subscription is enabled. True
89
+ # indicates the subscription is enabled.
90
+ # @return [Boolean]
91
+ def enabled
92
+ data.enabled
93
+ end
95
94
 
96
- # The Amazon Resource Name (ARN) for the event subscription.
97
- # @return [String]
98
- def event_subscription_arn
99
- data.event_subscription_arn
100
- end
95
+ # The Amazon Resource Name (ARN) for the event subscription.
96
+ # @return [String]
97
+ def event_subscription_arn
98
+ data.event_subscription_arn
99
+ end
101
100
 
102
- # @!endgroup
101
+ # @!endgroup
103
102
 
104
- # @return [Client]
105
- def client
106
- @client
107
- end
103
+ # @return [Client]
104
+ def client
105
+ @client
106
+ end
108
107
 
109
- # Loads, or reloads {#data} for the current {EventSubscription}.
110
- # Returns `self` making it possible to chain methods.
111
- #
112
- # event_subscription.reload.data
113
- #
114
- # @return [self]
115
- def load
116
- resp = @client.describe_event_subscriptions(subscription_name: @name)
117
- @data = resp.eventsubscriptionslist[0]
118
- self
119
- end
120
- alias :reload :load
108
+ # Loads, or reloads {#data} for the current {EventSubscription}.
109
+ # Returns `self` making it possible to chain methods.
110
+ #
111
+ # event_subscription.reload.data
112
+ #
113
+ # @return [self]
114
+ def load
115
+ resp = @client.describe_event_subscriptions(subscription_name: @name)
116
+ @data = resp.eventsubscriptionslist[0]
117
+ self
118
+ end
119
+ alias :reload :load
121
120
 
122
- # @return [Types::EventSubscription]
123
- # Returns the data for this {EventSubscription}. Calls
124
- # {Client#describe_event_subscriptions} if {#data_loaded?} is `false`.
125
- def data
126
- load unless @data
127
- @data
128
- end
121
+ # @return [Types::EventSubscription]
122
+ # Returns the data for this {EventSubscription}. Calls
123
+ # {Client#describe_event_subscriptions} if {#data_loaded?} is `false`.
124
+ def data
125
+ load unless @data
126
+ @data
127
+ end
129
128
 
130
- # @return [Boolean]
131
- # Returns `true` if this resource is loaded. Accessing attributes or
132
- # {#data} on an unloaded resource will trigger a call to {#load}.
133
- def data_loaded?
134
- !!@data
135
- end
129
+ # @return [Boolean]
130
+ # Returns `true` if this resource is loaded. Accessing attributes or
131
+ # {#data} on an unloaded resource will trigger a call to {#load}.
132
+ def data_loaded?
133
+ !!@data
134
+ end
136
135
 
137
- # @!group Actions
136
+ # @!group Actions
138
137
 
139
- # @example Request syntax with placeholder values
140
- #
141
- # eventsubscription = event_subscription.add_subscriber({
142
- # source_identifier: "String", # required
143
- # })
144
- # @param [Hash] options ({})
145
- # @option options [required, String] :source_identifier
146
- # The identifier of the event source to be added. An identifier must
147
- # begin with a letter and must contain only ASCII letters, digits, and
148
- # hyphens; it cannot end with a hyphen or contain two consecutive
149
- # hyphens.
150
- #
151
- # Constraints:
152
- #
153
- # * If the source type is a DB instance, then a `DBInstanceIdentifier`
154
- # must be supplied.
155
- #
156
- # * If the source type is a DB security group, a `DBSecurityGroupName`
157
- # must be supplied.
158
- #
159
- # * If the source type is a DB parameter group, a `DBParameterGroupName`
160
- # must be supplied.
161
- #
162
- # * If the source type is a DB snapshot, a `DBSnapshotIdentifier` must
163
- # be supplied.
164
- # @return [EventSubscription]
165
- def add_subscriber(options = {})
166
- options = options.merge(subscription_name: @name)
167
- resp = @client.add_source_identifier_to_subscription(options)
168
- EventSubscription.new(
169
- name: resp.data.event_subscription.cust_subscription_id,
170
- data: resp.data.event_subscription,
171
- client: @client
172
- )
173
- end
138
+ # @example Request syntax with placeholder values
139
+ #
140
+ # eventsubscription = event_subscription.add_subscriber({
141
+ # source_identifier: "String", # required
142
+ # })
143
+ # @param [Hash] options ({})
144
+ # @option options [required, String] :source_identifier
145
+ # The identifier of the event source to be added. An identifier must
146
+ # begin with a letter and must contain only ASCII letters, digits, and
147
+ # hyphens; it cannot end with a hyphen or contain two consecutive
148
+ # hyphens.
149
+ #
150
+ # Constraints:
151
+ #
152
+ # * If the source type is a DB instance, then a `DBInstanceIdentifier`
153
+ # must be supplied.
154
+ #
155
+ # * If the source type is a DB security group, a `DBSecurityGroupName`
156
+ # must be supplied.
157
+ #
158
+ # * If the source type is a DB parameter group, a `DBParameterGroupName`
159
+ # must be supplied.
160
+ #
161
+ # * If the source type is a DB snapshot, a `DBSnapshotIdentifier` must
162
+ # be supplied.
163
+ # @return [EventSubscription]
164
+ def add_subscriber(options = {})
165
+ options = options.merge(subscription_name: @name)
166
+ resp = @client.add_source_identifier_to_subscription(options)
167
+ EventSubscription.new(
168
+ name: resp.data.event_subscription.cust_subscription_id,
169
+ data: resp.data.event_subscription,
170
+ client: @client
171
+ )
172
+ end
174
173
 
175
- # @example Request syntax with placeholder values
176
- #
177
- # eventsubscription = event_subscription.create({
178
- # sns_topic_arn: "String", # required
179
- # source_type: "String",
180
- # event_categories: ["String"],
181
- # source_ids: ["String"],
182
- # enabled: false,
183
- # tags: [
184
- # {
185
- # key: "String",
186
- # value: "String",
187
- # },
188
- # ],
189
- # })
190
- # @param [Hash] options ({})
191
- # @option options [required, String] :sns_topic_arn
192
- # The Amazon Resource Name (ARN) of the SNS topic created for event
193
- # notification. The ARN is created by Amazon SNS when you create a topic
194
- # and subscribe to it.
195
- # @option options [String] :source_type
196
- # The type of source that will be generating the events. For example, if
197
- # you want to be notified of events generated by a DB instance, you
198
- # would set this parameter to db-instance. if this value is not
199
- # specified, all events are returned.
200
- #
201
- # Valid values: `db-instance` \| `db-cluster` \| `db-parameter-group` \|
202
- # `db-security-group` \| `db-snapshot` \| `db-cluster-snapshot`
203
- # @option options [Array<String>] :event_categories
204
- # A list of event categories for a SourceType that you want to subscribe
205
- # to. You can see a list of the categories for a given SourceType in the
206
- # [Events][1] topic in the Amazon RDS User Guide or by using the
207
- # **DescribeEventCategories** action.
208
- #
209
- #
210
- #
211
- # [1]: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html
212
- # @option options [Array<String>] :source_ids
213
- # The list of identifiers of the event sources for which events will be
214
- # returned. If not specified, then all sources are included in the
215
- # response. An identifier must begin with a letter and must contain only
216
- # ASCII letters, digits, and hyphens; it cannot end with a hyphen or
217
- # contain two consecutive hyphens.
218
- #
219
- # Constraints:
220
- #
221
- # * If SourceIds are supplied, SourceType must also be provided.
222
- #
223
- # * If the source type is a DB instance, then a `DBInstanceIdentifier`
224
- # must be supplied.
225
- #
226
- # * If the source type is a DB security group, a `DBSecurityGroupName`
227
- # must be supplied.
228
- #
229
- # * If the source type is a DB parameter group, a `DBParameterGroupName`
230
- # must be supplied.
231
- #
232
- # * If the source type is a DB snapshot, a `DBSnapshotIdentifier` must
233
- # be supplied.
234
- # @option options [Boolean] :enabled
235
- # A Boolean value; set to **true** to activate the subscription, set to
236
- # **false** to create the subscription but not active it.
237
- # @option options [Array<Types::Tag>] :tags
238
- # A list of tags.
239
- # @return [EventSubscription]
240
- def create(options = {})
241
- options = options.merge(subscription_name: @name)
242
- resp = @client.create_event_subscription(options)
243
- EventSubscription.new(
244
- name: resp.data.event_subscription.cust_subscription_id,
245
- data: resp.data.event_subscription,
246
- client: @client
247
- )
248
- end
174
+ # @example Request syntax with placeholder values
175
+ #
176
+ # eventsubscription = event_subscription.create({
177
+ # sns_topic_arn: "String", # required
178
+ # source_type: "String",
179
+ # event_categories: ["String"],
180
+ # source_ids: ["String"],
181
+ # enabled: false,
182
+ # tags: [
183
+ # {
184
+ # key: "String",
185
+ # value: "String",
186
+ # },
187
+ # ],
188
+ # })
189
+ # @param [Hash] options ({})
190
+ # @option options [required, String] :sns_topic_arn
191
+ # The Amazon Resource Name (ARN) of the SNS topic created for event
192
+ # notification. The ARN is created by Amazon SNS when you create a topic
193
+ # and subscribe to it.
194
+ # @option options [String] :source_type
195
+ # The type of source that will be generating the events. For example, if
196
+ # you want to be notified of events generated by a DB instance, you
197
+ # would set this parameter to db-instance. if this value is not
198
+ # specified, all events are returned.
199
+ #
200
+ # Valid values: `db-instance` \| `db-cluster` \| `db-parameter-group` \|
201
+ # `db-security-group` \| `db-snapshot` \| `db-cluster-snapshot`
202
+ # @option options [Array<String>] :event_categories
203
+ # A list of event categories for a SourceType that you want to subscribe
204
+ # to. You can see a list of the categories for a given SourceType in the
205
+ # [Events][1] topic in the Amazon RDS User Guide or by using the
206
+ # **DescribeEventCategories** action.
207
+ #
208
+ #
209
+ #
210
+ # [1]: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html
211
+ # @option options [Array<String>] :source_ids
212
+ # The list of identifiers of the event sources for which events will be
213
+ # returned. If not specified, then all sources are included in the
214
+ # response. An identifier must begin with a letter and must contain only
215
+ # ASCII letters, digits, and hyphens; it cannot end with a hyphen or
216
+ # contain two consecutive hyphens.
217
+ #
218
+ # Constraints:
219
+ #
220
+ # * If SourceIds are supplied, SourceType must also be provided.
221
+ #
222
+ # * If the source type is a DB instance, then a `DBInstanceIdentifier`
223
+ # must be supplied.
224
+ #
225
+ # * If the source type is a DB security group, a `DBSecurityGroupName`
226
+ # must be supplied.
227
+ #
228
+ # * If the source type is a DB parameter group, a `DBParameterGroupName`
229
+ # must be supplied.
230
+ #
231
+ # * If the source type is a DB snapshot, a `DBSnapshotIdentifier` must
232
+ # be supplied.
233
+ # @option options [Boolean] :enabled
234
+ # A Boolean value; set to **true** to activate the subscription, set to
235
+ # **false** to create the subscription but not active it.
236
+ # @option options [Array<Types::Tag>] :tags
237
+ # A list of tags.
238
+ # @return [EventSubscription]
239
+ def create(options = {})
240
+ options = options.merge(subscription_name: @name)
241
+ resp = @client.create_event_subscription(options)
242
+ EventSubscription.new(
243
+ name: resp.data.event_subscription.cust_subscription_id,
244
+ data: resp.data.event_subscription,
245
+ client: @client
246
+ )
247
+ end
249
248
 
250
- # @example Request syntax with placeholder values
251
- #
252
- # eventsubscription = event_subscription.delete()
253
- # @param [Hash] options ({})
254
- # @return [EventSubscription]
255
- def delete(options = {})
256
- options = options.merge(subscription_name: @name)
257
- resp = @client.delete_event_subscription(options)
258
- EventSubscription.new(
259
- name: resp.data.event_subscription.cust_subscription_id,
260
- data: resp.data.event_subscription,
261
- client: @client
262
- )
263
- end
249
+ # @example Request syntax with placeholder values
250
+ #
251
+ # event_subscription.delete()
252
+ # @param [Hash] options ({})
253
+ # @return [EventSubscription]
254
+ def delete(options = {})
255
+ options = options.merge(subscription_name: @name)
256
+ resp = @client.delete_event_subscription(options)
257
+ EventSubscription.new(
258
+ name: resp.data.event_subscription.cust_subscription_id,
259
+ data: resp.data.event_subscription,
260
+ client: @client
261
+ )
262
+ end
264
263
 
265
- # @example Request syntax with placeholder values
266
- #
267
- # eventsubscription = event_subscription.modify({
268
- # sns_topic_arn: "String",
269
- # source_type: "String",
270
- # event_categories: ["String"],
271
- # enabled: false,
272
- # })
273
- # @param [Hash] options ({})
274
- # @option options [String] :sns_topic_arn
275
- # The Amazon Resource Name (ARN) of the SNS topic created for event
276
- # notification. The ARN is created by Amazon SNS when you create a topic
277
- # and subscribe to it.
278
- # @option options [String] :source_type
279
- # The type of source that will be generating the events. For example, if
280
- # you want to be notified of events generated by a DB instance, you
281
- # would set this parameter to db-instance. if this value is not
282
- # specified, all events are returned.
283
- #
284
- # Valid values: db-instance \| db-parameter-group \| db-security-group
285
- # \| db-snapshot
286
- # @option options [Array<String>] :event_categories
287
- # A list of event categories for a SourceType that you want to subscribe
288
- # to. You can see a list of the categories for a given SourceType in the
289
- # [Events][1] topic in the Amazon RDS User Guide or by using the
290
- # **DescribeEventCategories** action.
291
- #
292
- #
293
- #
294
- # [1]: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html
295
- # @option options [Boolean] :enabled
296
- # A Boolean value; set to **true** to activate the subscription.
297
- # @return [EventSubscription]
298
- def modify(options = {})
299
- options = options.merge(subscription_name: @name)
300
- resp = @client.modify_event_subscription(options)
301
- EventSubscription.new(
302
- name: resp.data.event_subscription.cust_subscription_id,
303
- data: resp.data.event_subscription,
304
- client: @client
305
- )
306
- end
264
+ # @example Request syntax with placeholder values
265
+ #
266
+ # eventsubscription = event_subscription.modify({
267
+ # sns_topic_arn: "String",
268
+ # source_type: "String",
269
+ # event_categories: ["String"],
270
+ # enabled: false,
271
+ # })
272
+ # @param [Hash] options ({})
273
+ # @option options [String] :sns_topic_arn
274
+ # The Amazon Resource Name (ARN) of the SNS topic created for event
275
+ # notification. The ARN is created by Amazon SNS when you create a topic
276
+ # and subscribe to it.
277
+ # @option options [String] :source_type
278
+ # The type of source that will be generating the events. For example, if
279
+ # you want to be notified of events generated by a DB instance, you
280
+ # would set this parameter to db-instance. if this value is not
281
+ # specified, all events are returned.
282
+ #
283
+ # Valid values: db-instance \| db-parameter-group \| db-security-group
284
+ # \| db-snapshot
285
+ # @option options [Array<String>] :event_categories
286
+ # A list of event categories for a SourceType that you want to subscribe
287
+ # to. You can see a list of the categories for a given SourceType in the
288
+ # [Events][1] topic in the Amazon RDS User Guide or by using the
289
+ # **DescribeEventCategories** action.
290
+ #
291
+ #
292
+ #
293
+ # [1]: http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.html
294
+ # @option options [Boolean] :enabled
295
+ # A Boolean value; set to **true** to activate the subscription.
296
+ # @return [EventSubscription]
297
+ def modify(options = {})
298
+ options = options.merge(subscription_name: @name)
299
+ resp = @client.modify_event_subscription(options)
300
+ EventSubscription.new(
301
+ name: resp.data.event_subscription.cust_subscription_id,
302
+ data: resp.data.event_subscription,
303
+ client: @client
304
+ )
305
+ end
307
306
 
308
- # @example Request syntax with placeholder values
309
- #
310
- # eventsubscription = event_subscription.remove_subscriber({
311
- # source_identifier: "String", # required
312
- # })
313
- # @param [Hash] options ({})
314
- # @option options [required, String] :source_identifier
315
- # The source identifier to be removed from the subscription, such as the
316
- # **DB instance identifier** for a DB instance or the name of a security
317
- # group.
318
- # @return [EventSubscription]
319
- def remove_subscriber(options = {})
320
- options = options.merge(subscription_name: @name)
321
- resp = @client.remove_source_identifier_from_subscription(options)
322
- EventSubscription.new(
323
- name: resp.data.event_subscription.cust_subscription_id,
324
- data: resp.data.event_subscription,
325
- client: @client
326
- )
327
- end
307
+ # @example Request syntax with placeholder values
308
+ #
309
+ # eventsubscription = event_subscription.remove_subscriber({
310
+ # source_identifier: "String", # required
311
+ # })
312
+ # @param [Hash] options ({})
313
+ # @option options [required, String] :source_identifier
314
+ # The source identifier to be removed from the subscription, such as the
315
+ # **DB instance identifier** for a DB instance or the name of a security
316
+ # group.
317
+ # @return [EventSubscription]
318
+ def remove_subscriber(options = {})
319
+ options = options.merge(subscription_name: @name)
320
+ resp = @client.remove_source_identifier_from_subscription(options)
321
+ EventSubscription.new(
322
+ name: resp.data.event_subscription.cust_subscription_id,
323
+ data: resp.data.event_subscription,
324
+ client: @client
325
+ )
326
+ end
328
327
 
329
- # @deprecated
330
- # @api private
331
- def identifiers
332
- { name: @name }
333
- end
334
- deprecated(:identifiers)
328
+ # @deprecated
329
+ # @api private
330
+ def identifiers
331
+ { name: @name }
332
+ end
333
+ deprecated(:identifiers)
335
334
 
336
- private
335
+ private
337
336
 
338
- def extract_name(args, options)
339
- value = args[0] || options.delete(:name)
340
- case value
341
- when String then value
342
- when nil then raise ArgumentError, "missing required option :name"
343
- else
344
- msg = "expected :name to be a String, got #{value.class}"
345
- raise ArgumentError, msg
346
- end
337
+ def extract_name(args, options)
338
+ value = args[0] || options.delete(:name)
339
+ case value
340
+ when String then value
341
+ when nil then raise ArgumentError, "missing required option :name"
342
+ else
343
+ msg = "expected :name to be a String, got #{value.class}"
344
+ raise ArgumentError, msg
347
345
  end
348
-
349
- class Collection < Aws::Resources::Collection; end
350
346
  end
347
+
348
+ class Collection < Aws::Resources::Collection; end
351
349
  end
352
350
  end