aws-sdk-dsql 1.0.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 +7 -0
- data/CHANGELOG.md +9 -0
- data/LICENSE.txt +202 -0
- data/VERSION +1 -0
- data/lib/aws-sdk-dsql/client.rb +1143 -0
- data/lib/aws-sdk-dsql/client_api.rb +377 -0
- data/lib/aws-sdk-dsql/customizations/auth_token_generator.rb +70 -0
- data/lib/aws-sdk-dsql/customizations.rb +3 -0
- data/lib/aws-sdk-dsql/endpoint_parameters.rb +59 -0
- data/lib/aws-sdk-dsql/endpoint_provider.rb +35 -0
- data/lib/aws-sdk-dsql/endpoints.rb +20 -0
- data/lib/aws-sdk-dsql/errors.rb +232 -0
- data/lib/aws-sdk-dsql/plugins/endpoints.rb +77 -0
- data/lib/aws-sdk-dsql/resource.rb +26 -0
- data/lib/aws-sdk-dsql/types.rb +682 -0
- data/lib/aws-sdk-dsql/waiters.rb +150 -0
- data/lib/aws-sdk-dsql.rb +62 -0
- data/sig/client.rbs +214 -0
- data/sig/errors.rbs +51 -0
- data/sig/resource.rbs +82 -0
- data/sig/types.rbs +196 -0
- data/sig/waiters.rbs +33 -0
- metadata +101 -0
@@ -0,0 +1,377 @@
|
|
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
|
+
|
11
|
+
module Aws::DSQL
|
12
|
+
# @api private
|
13
|
+
module ClientApi
|
14
|
+
|
15
|
+
include Seahorse::Model
|
16
|
+
|
17
|
+
AccessDeniedException = Shapes::StructureShape.new(name: 'AccessDeniedException')
|
18
|
+
Arn = Shapes::StringShape.new(name: 'Arn')
|
19
|
+
ClientToken = Shapes::StringShape.new(name: 'ClientToken')
|
20
|
+
ClusterArn = Shapes::StringShape.new(name: 'ClusterArn')
|
21
|
+
ClusterArnList = Shapes::ListShape.new(name: 'ClusterArnList')
|
22
|
+
ClusterCreationTime = Shapes::TimestampShape.new(name: 'ClusterCreationTime')
|
23
|
+
ClusterId = Shapes::StringShape.new(name: 'ClusterId')
|
24
|
+
ClusterList = Shapes::ListShape.new(name: 'ClusterList')
|
25
|
+
ClusterPropertyMap = Shapes::MapShape.new(name: 'ClusterPropertyMap')
|
26
|
+
ClusterStatus = Shapes::StringShape.new(name: 'ClusterStatus')
|
27
|
+
ClusterSummary = Shapes::StructureShape.new(name: 'ClusterSummary')
|
28
|
+
ConflictException = Shapes::StructureShape.new(name: 'ConflictException')
|
29
|
+
CreateClusterInput = Shapes::StructureShape.new(name: 'CreateClusterInput')
|
30
|
+
CreateClusterOutput = Shapes::StructureShape.new(name: 'CreateClusterOutput')
|
31
|
+
CreateMultiRegionClustersInput = Shapes::StructureShape.new(name: 'CreateMultiRegionClustersInput')
|
32
|
+
CreateMultiRegionClustersOutput = Shapes::StructureShape.new(name: 'CreateMultiRegionClustersOutput')
|
33
|
+
DeleteClusterInput = Shapes::StructureShape.new(name: 'DeleteClusterInput')
|
34
|
+
DeleteClusterOutput = Shapes::StructureShape.new(name: 'DeleteClusterOutput')
|
35
|
+
DeleteMultiRegionClustersInput = Shapes::StructureShape.new(name: 'DeleteMultiRegionClustersInput')
|
36
|
+
DeletionProtectionEnabled = Shapes::BooleanShape.new(name: 'DeletionProtectionEnabled')
|
37
|
+
GetClusterInput = Shapes::StructureShape.new(name: 'GetClusterInput')
|
38
|
+
GetClusterOutput = Shapes::StructureShape.new(name: 'GetClusterOutput')
|
39
|
+
Integer = Shapes::IntegerShape.new(name: 'Integer')
|
40
|
+
InternalServerException = Shapes::StructureShape.new(name: 'InternalServerException')
|
41
|
+
LinkedClusterProperties = Shapes::StructureShape.new(name: 'LinkedClusterProperties')
|
42
|
+
ListClustersInput = Shapes::StructureShape.new(name: 'ListClustersInput')
|
43
|
+
ListClustersOutput = Shapes::StructureShape.new(name: 'ListClustersOutput')
|
44
|
+
ListTagsForResourceInput = Shapes::StructureShape.new(name: 'ListTagsForResourceInput')
|
45
|
+
ListTagsForResourceOutput = Shapes::StructureShape.new(name: 'ListTagsForResourceOutput')
|
46
|
+
MaxResults = Shapes::IntegerShape.new(name: 'MaxResults')
|
47
|
+
NextToken = Shapes::StringShape.new(name: 'NextToken')
|
48
|
+
Region = Shapes::StringShape.new(name: 'Region')
|
49
|
+
RegionList = Shapes::ListShape.new(name: 'RegionList')
|
50
|
+
ResourceNotFoundException = Shapes::StructureShape.new(name: 'ResourceNotFoundException')
|
51
|
+
ServiceQuotaExceededException = Shapes::StructureShape.new(name: 'ServiceQuotaExceededException')
|
52
|
+
String = Shapes::StringShape.new(name: 'String')
|
53
|
+
TagKey = Shapes::StringShape.new(name: 'TagKey')
|
54
|
+
TagKeyList = Shapes::ListShape.new(name: 'TagKeyList')
|
55
|
+
TagMap = Shapes::MapShape.new(name: 'TagMap')
|
56
|
+
TagResourceInput = Shapes::StructureShape.new(name: 'TagResourceInput')
|
57
|
+
TagValue = Shapes::StringShape.new(name: 'TagValue')
|
58
|
+
ThrottlingException = Shapes::StructureShape.new(name: 'ThrottlingException')
|
59
|
+
UntagResourceInput = Shapes::StructureShape.new(name: 'UntagResourceInput')
|
60
|
+
UpdateClusterInput = Shapes::StructureShape.new(name: 'UpdateClusterInput')
|
61
|
+
UpdateClusterOutput = Shapes::StructureShape.new(name: 'UpdateClusterOutput')
|
62
|
+
ValidationException = Shapes::StructureShape.new(name: 'ValidationException')
|
63
|
+
ValidationExceptionField = Shapes::StructureShape.new(name: 'ValidationExceptionField')
|
64
|
+
ValidationExceptionFieldList = Shapes::ListShape.new(name: 'ValidationExceptionFieldList')
|
65
|
+
ValidationExceptionReason = Shapes::StringShape.new(name: 'ValidationExceptionReason')
|
66
|
+
|
67
|
+
AccessDeniedException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
68
|
+
AccessDeniedException.struct_class = Types::AccessDeniedException
|
69
|
+
|
70
|
+
ClusterArnList.member = Shapes::ShapeRef.new(shape: ClusterArn)
|
71
|
+
|
72
|
+
ClusterList.member = Shapes::ShapeRef.new(shape: ClusterSummary)
|
73
|
+
|
74
|
+
ClusterPropertyMap.key = Shapes::ShapeRef.new(shape: Region)
|
75
|
+
ClusterPropertyMap.value = Shapes::ShapeRef.new(shape: LinkedClusterProperties)
|
76
|
+
|
77
|
+
ClusterSummary.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location_name: "identifier"))
|
78
|
+
ClusterSummary.add_member(:arn, Shapes::ShapeRef.new(shape: ClusterArn, required: true, location_name: "arn"))
|
79
|
+
ClusterSummary.struct_class = Types::ClusterSummary
|
80
|
+
|
81
|
+
ConflictException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
82
|
+
ConflictException.add_member(:resource_id, Shapes::ShapeRef.new(shape: String, location_name: "resourceId"))
|
83
|
+
ConflictException.add_member(:resource_type, Shapes::ShapeRef.new(shape: String, location_name: "resourceType"))
|
84
|
+
ConflictException.struct_class = Types::ConflictException
|
85
|
+
|
86
|
+
CreateClusterInput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, location_name: "deletionProtectionEnabled"))
|
87
|
+
CreateClusterInput.add_member(:tags, Shapes::ShapeRef.new(shape: TagMap, location_name: "tags"))
|
88
|
+
CreateClusterInput.add_member(:client_token, Shapes::ShapeRef.new(shape: ClientToken, location_name: "clientToken", metadata: {"idempotencyToken"=>true}))
|
89
|
+
CreateClusterInput.struct_class = Types::CreateClusterInput
|
90
|
+
|
91
|
+
CreateClusterOutput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location_name: "identifier"))
|
92
|
+
CreateClusterOutput.add_member(:arn, Shapes::ShapeRef.new(shape: ClusterArn, required: true, location_name: "arn"))
|
93
|
+
CreateClusterOutput.add_member(:status, Shapes::ShapeRef.new(shape: ClusterStatus, required: true, location_name: "status"))
|
94
|
+
CreateClusterOutput.add_member(:creation_time, Shapes::ShapeRef.new(shape: ClusterCreationTime, required: true, location_name: "creationTime"))
|
95
|
+
CreateClusterOutput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, required: true, location_name: "deletionProtectionEnabled"))
|
96
|
+
CreateClusterOutput.struct_class = Types::CreateClusterOutput
|
97
|
+
|
98
|
+
CreateMultiRegionClustersInput.add_member(:linked_region_list, Shapes::ShapeRef.new(shape: RegionList, required: true, location_name: "linkedRegionList"))
|
99
|
+
CreateMultiRegionClustersInput.add_member(:cluster_properties, Shapes::ShapeRef.new(shape: ClusterPropertyMap, location_name: "clusterProperties"))
|
100
|
+
CreateMultiRegionClustersInput.add_member(:witness_region, Shapes::ShapeRef.new(shape: Region, required: true, location_name: "witnessRegion"))
|
101
|
+
CreateMultiRegionClustersInput.add_member(:client_token, Shapes::ShapeRef.new(shape: ClientToken, location_name: "clientToken", metadata: {"idempotencyToken"=>true}))
|
102
|
+
CreateMultiRegionClustersInput.struct_class = Types::CreateMultiRegionClustersInput
|
103
|
+
|
104
|
+
CreateMultiRegionClustersOutput.add_member(:linked_cluster_arns, Shapes::ShapeRef.new(shape: ClusterArnList, required: true, location_name: "linkedClusterArns"))
|
105
|
+
CreateMultiRegionClustersOutput.struct_class = Types::CreateMultiRegionClustersOutput
|
106
|
+
|
107
|
+
DeleteClusterInput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location: "uri", location_name: "identifier"))
|
108
|
+
DeleteClusterInput.add_member(:client_token, Shapes::ShapeRef.new(shape: ClientToken, location: "querystring", location_name: "client-token", metadata: {"idempotencyToken"=>true}))
|
109
|
+
DeleteClusterInput.struct_class = Types::DeleteClusterInput
|
110
|
+
|
111
|
+
DeleteClusterOutput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location_name: "identifier"))
|
112
|
+
DeleteClusterOutput.add_member(:arn, Shapes::ShapeRef.new(shape: ClusterArn, required: true, location_name: "arn"))
|
113
|
+
DeleteClusterOutput.add_member(:status, Shapes::ShapeRef.new(shape: ClusterStatus, required: true, location_name: "status"))
|
114
|
+
DeleteClusterOutput.add_member(:creation_time, Shapes::ShapeRef.new(shape: ClusterCreationTime, required: true, location_name: "creationTime"))
|
115
|
+
DeleteClusterOutput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, required: true, location_name: "deletionProtectionEnabled"))
|
116
|
+
DeleteClusterOutput.struct_class = Types::DeleteClusterOutput
|
117
|
+
|
118
|
+
DeleteMultiRegionClustersInput.add_member(:linked_cluster_arns, Shapes::ShapeRef.new(shape: ClusterArnList, required: true, location: "querystring", location_name: "linked-cluster-arns"))
|
119
|
+
DeleteMultiRegionClustersInput.add_member(:client_token, Shapes::ShapeRef.new(shape: ClientToken, location: "querystring", location_name: "client-token", metadata: {"idempotencyToken"=>true}))
|
120
|
+
DeleteMultiRegionClustersInput.struct_class = Types::DeleteMultiRegionClustersInput
|
121
|
+
|
122
|
+
GetClusterInput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location: "uri", location_name: "identifier"))
|
123
|
+
GetClusterInput.struct_class = Types::GetClusterInput
|
124
|
+
|
125
|
+
GetClusterOutput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location_name: "identifier"))
|
126
|
+
GetClusterOutput.add_member(:arn, Shapes::ShapeRef.new(shape: ClusterArn, required: true, location_name: "arn"))
|
127
|
+
GetClusterOutput.add_member(:status, Shapes::ShapeRef.new(shape: ClusterStatus, required: true, location_name: "status"))
|
128
|
+
GetClusterOutput.add_member(:creation_time, Shapes::ShapeRef.new(shape: ClusterCreationTime, required: true, location_name: "creationTime"))
|
129
|
+
GetClusterOutput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, required: true, location_name: "deletionProtectionEnabled"))
|
130
|
+
GetClusterOutput.add_member(:witness_region, Shapes::ShapeRef.new(shape: Region, location_name: "witnessRegion"))
|
131
|
+
GetClusterOutput.add_member(:linked_cluster_arns, Shapes::ShapeRef.new(shape: ClusterArnList, location_name: "linkedClusterArns"))
|
132
|
+
GetClusterOutput.struct_class = Types::GetClusterOutput
|
133
|
+
|
134
|
+
InternalServerException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
135
|
+
InternalServerException.add_member(:retry_after_seconds, Shapes::ShapeRef.new(shape: Integer, location: "header", location_name: "Retry-After"))
|
136
|
+
InternalServerException.struct_class = Types::InternalServerException
|
137
|
+
|
138
|
+
LinkedClusterProperties.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, location_name: "deletionProtectionEnabled"))
|
139
|
+
LinkedClusterProperties.add_member(:tags, Shapes::ShapeRef.new(shape: TagMap, location_name: "tags"))
|
140
|
+
LinkedClusterProperties.struct_class = Types::LinkedClusterProperties
|
141
|
+
|
142
|
+
ListClustersInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxResults, location: "querystring", location_name: "max-results"))
|
143
|
+
ListClustersInput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location: "querystring", location_name: "next-token"))
|
144
|
+
ListClustersInput.struct_class = Types::ListClustersInput
|
145
|
+
|
146
|
+
ListClustersOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: NextToken, location_name: "nextToken"))
|
147
|
+
ListClustersOutput.add_member(:clusters, Shapes::ShapeRef.new(shape: ClusterList, required: true, location_name: "clusters"))
|
148
|
+
ListClustersOutput.struct_class = Types::ListClustersOutput
|
149
|
+
|
150
|
+
ListTagsForResourceInput.add_member(:resource_arn, Shapes::ShapeRef.new(shape: Arn, required: true, location: "uri", location_name: "resourceArn"))
|
151
|
+
ListTagsForResourceInput.struct_class = Types::ListTagsForResourceInput
|
152
|
+
|
153
|
+
ListTagsForResourceOutput.add_member(:tags, Shapes::ShapeRef.new(shape: TagMap, location_name: "tags"))
|
154
|
+
ListTagsForResourceOutput.struct_class = Types::ListTagsForResourceOutput
|
155
|
+
|
156
|
+
RegionList.member = Shapes::ShapeRef.new(shape: Region)
|
157
|
+
|
158
|
+
ResourceNotFoundException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
159
|
+
ResourceNotFoundException.add_member(:resource_id, Shapes::ShapeRef.new(shape: String, required: true, location_name: "resourceId"))
|
160
|
+
ResourceNotFoundException.add_member(:resource_type, Shapes::ShapeRef.new(shape: String, required: true, location_name: "resourceType"))
|
161
|
+
ResourceNotFoundException.struct_class = Types::ResourceNotFoundException
|
162
|
+
|
163
|
+
ServiceQuotaExceededException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
164
|
+
ServiceQuotaExceededException.add_member(:resource_id, Shapes::ShapeRef.new(shape: String, required: true, location_name: "resourceId"))
|
165
|
+
ServiceQuotaExceededException.add_member(:resource_type, Shapes::ShapeRef.new(shape: String, required: true, location_name: "resourceType"))
|
166
|
+
ServiceQuotaExceededException.add_member(:service_code, Shapes::ShapeRef.new(shape: String, required: true, location_name: "serviceCode"))
|
167
|
+
ServiceQuotaExceededException.add_member(:quota_code, Shapes::ShapeRef.new(shape: String, required: true, location_name: "quotaCode"))
|
168
|
+
ServiceQuotaExceededException.struct_class = Types::ServiceQuotaExceededException
|
169
|
+
|
170
|
+
TagKeyList.member = Shapes::ShapeRef.new(shape: TagKey)
|
171
|
+
|
172
|
+
TagMap.key = Shapes::ShapeRef.new(shape: TagKey)
|
173
|
+
TagMap.value = Shapes::ShapeRef.new(shape: TagValue)
|
174
|
+
|
175
|
+
TagResourceInput.add_member(:resource_arn, Shapes::ShapeRef.new(shape: Arn, required: true, location: "uri", location_name: "resourceArn"))
|
176
|
+
TagResourceInput.add_member(:tags, Shapes::ShapeRef.new(shape: TagMap, required: true, location_name: "tags"))
|
177
|
+
TagResourceInput.struct_class = Types::TagResourceInput
|
178
|
+
|
179
|
+
ThrottlingException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
180
|
+
ThrottlingException.add_member(:service_code, Shapes::ShapeRef.new(shape: String, location_name: "serviceCode"))
|
181
|
+
ThrottlingException.add_member(:quota_code, Shapes::ShapeRef.new(shape: String, location_name: "quotaCode"))
|
182
|
+
ThrottlingException.add_member(:retry_after_seconds, Shapes::ShapeRef.new(shape: Integer, location: "header", location_name: "Retry-After"))
|
183
|
+
ThrottlingException.struct_class = Types::ThrottlingException
|
184
|
+
|
185
|
+
UntagResourceInput.add_member(:resource_arn, Shapes::ShapeRef.new(shape: Arn, required: true, location: "uri", location_name: "resourceArn"))
|
186
|
+
UntagResourceInput.add_member(:tag_keys, Shapes::ShapeRef.new(shape: TagKeyList, required: true, location: "querystring", location_name: "tagKeys"))
|
187
|
+
UntagResourceInput.struct_class = Types::UntagResourceInput
|
188
|
+
|
189
|
+
UpdateClusterInput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location: "uri", location_name: "identifier"))
|
190
|
+
UpdateClusterInput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, location_name: "deletionProtectionEnabled"))
|
191
|
+
UpdateClusterInput.add_member(:client_token, Shapes::ShapeRef.new(shape: ClientToken, location_name: "clientToken", metadata: {"idempotencyToken"=>true}))
|
192
|
+
UpdateClusterInput.struct_class = Types::UpdateClusterInput
|
193
|
+
|
194
|
+
UpdateClusterOutput.add_member(:identifier, Shapes::ShapeRef.new(shape: ClusterId, required: true, location_name: "identifier"))
|
195
|
+
UpdateClusterOutput.add_member(:arn, Shapes::ShapeRef.new(shape: ClusterArn, required: true, location_name: "arn"))
|
196
|
+
UpdateClusterOutput.add_member(:status, Shapes::ShapeRef.new(shape: ClusterStatus, required: true, location_name: "status"))
|
197
|
+
UpdateClusterOutput.add_member(:creation_time, Shapes::ShapeRef.new(shape: ClusterCreationTime, required: true, location_name: "creationTime"))
|
198
|
+
UpdateClusterOutput.add_member(:deletion_protection_enabled, Shapes::ShapeRef.new(shape: DeletionProtectionEnabled, required: true, location_name: "deletionProtectionEnabled"))
|
199
|
+
UpdateClusterOutput.add_member(:witness_region, Shapes::ShapeRef.new(shape: Region, location_name: "witnessRegion"))
|
200
|
+
UpdateClusterOutput.add_member(:linked_cluster_arns, Shapes::ShapeRef.new(shape: ClusterArnList, location_name: "linkedClusterArns"))
|
201
|
+
UpdateClusterOutput.struct_class = Types::UpdateClusterOutput
|
202
|
+
|
203
|
+
ValidationException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
204
|
+
ValidationException.add_member(:reason, Shapes::ShapeRef.new(shape: ValidationExceptionReason, required: true, location_name: "reason"))
|
205
|
+
ValidationException.add_member(:field_list, Shapes::ShapeRef.new(shape: ValidationExceptionFieldList, location_name: "fieldList"))
|
206
|
+
ValidationException.struct_class = Types::ValidationException
|
207
|
+
|
208
|
+
ValidationExceptionField.add_member(:name, Shapes::ShapeRef.new(shape: String, required: true, location_name: "name"))
|
209
|
+
ValidationExceptionField.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
|
210
|
+
ValidationExceptionField.struct_class = Types::ValidationExceptionField
|
211
|
+
|
212
|
+
ValidationExceptionFieldList.member = Shapes::ShapeRef.new(shape: ValidationExceptionField)
|
213
|
+
|
214
|
+
|
215
|
+
# @api private
|
216
|
+
API = Seahorse::Model::Api.new.tap do |api|
|
217
|
+
|
218
|
+
api.version = "2018-05-10"
|
219
|
+
|
220
|
+
api.metadata = {
|
221
|
+
"apiVersion" => "2018-05-10",
|
222
|
+
"auth" => ["aws.auth#sigv4"],
|
223
|
+
"endpointPrefix" => "dsql",
|
224
|
+
"protocol" => "rest-json",
|
225
|
+
"protocols" => ["rest-json"],
|
226
|
+
"serviceFullName" => "Amazon Aurora DSQL",
|
227
|
+
"serviceId" => "DSQL",
|
228
|
+
"signatureVersion" => "v4",
|
229
|
+
"signingName" => "dsql",
|
230
|
+
"uid" => "dsql-2018-05-10",
|
231
|
+
}
|
232
|
+
|
233
|
+
api.add_operation(:create_cluster, Seahorse::Model::Operation.new.tap do |o|
|
234
|
+
o.name = "CreateCluster"
|
235
|
+
o.http_method = "POST"
|
236
|
+
o.http_request_uri = "/cluster"
|
237
|
+
o.input = Shapes::ShapeRef.new(shape: CreateClusterInput)
|
238
|
+
o.output = Shapes::ShapeRef.new(shape: CreateClusterOutput)
|
239
|
+
o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
|
240
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
241
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
242
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
243
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
244
|
+
o.errors << Shapes::ShapeRef.new(shape: ConflictException)
|
245
|
+
end)
|
246
|
+
|
247
|
+
api.add_operation(:create_multi_region_clusters, Seahorse::Model::Operation.new.tap do |o|
|
248
|
+
o.name = "CreateMultiRegionClusters"
|
249
|
+
o.http_method = "POST"
|
250
|
+
o.http_request_uri = "/multi-region-clusters"
|
251
|
+
o.input = Shapes::ShapeRef.new(shape: CreateMultiRegionClustersInput)
|
252
|
+
o.output = Shapes::ShapeRef.new(shape: CreateMultiRegionClustersOutput)
|
253
|
+
o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
|
254
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
255
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
256
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
257
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
258
|
+
o.errors << Shapes::ShapeRef.new(shape: ConflictException)
|
259
|
+
end)
|
260
|
+
|
261
|
+
api.add_operation(:delete_cluster, Seahorse::Model::Operation.new.tap do |o|
|
262
|
+
o.name = "DeleteCluster"
|
263
|
+
o.http_method = "DELETE"
|
264
|
+
o.http_request_uri = "/cluster/{identifier}"
|
265
|
+
o.input = Shapes::ShapeRef.new(shape: DeleteClusterInput)
|
266
|
+
o.output = Shapes::ShapeRef.new(shape: DeleteClusterOutput)
|
267
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
268
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
269
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
270
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
271
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
272
|
+
o.errors << Shapes::ShapeRef.new(shape: ConflictException)
|
273
|
+
end)
|
274
|
+
|
275
|
+
api.add_operation(:delete_multi_region_clusters, Seahorse::Model::Operation.new.tap do |o|
|
276
|
+
o.name = "DeleteMultiRegionClusters"
|
277
|
+
o.http_method = "DELETE"
|
278
|
+
o.http_request_uri = "/multi-region-clusters"
|
279
|
+
o.input = Shapes::ShapeRef.new(shape: DeleteMultiRegionClustersInput)
|
280
|
+
o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
|
281
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
282
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
283
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
284
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
285
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
286
|
+
o.errors << Shapes::ShapeRef.new(shape: ConflictException)
|
287
|
+
end)
|
288
|
+
|
289
|
+
api.add_operation(:get_cluster, Seahorse::Model::Operation.new.tap do |o|
|
290
|
+
o.name = "GetCluster"
|
291
|
+
o.http_method = "GET"
|
292
|
+
o.http_request_uri = "/cluster/{identifier}"
|
293
|
+
o.input = Shapes::ShapeRef.new(shape: GetClusterInput)
|
294
|
+
o.output = Shapes::ShapeRef.new(shape: GetClusterOutput)
|
295
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
296
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
297
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
298
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
299
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
300
|
+
end)
|
301
|
+
|
302
|
+
api.add_operation(:list_clusters, Seahorse::Model::Operation.new.tap do |o|
|
303
|
+
o.name = "ListClusters"
|
304
|
+
o.http_method = "GET"
|
305
|
+
o.http_request_uri = "/cluster"
|
306
|
+
o.input = Shapes::ShapeRef.new(shape: ListClustersInput)
|
307
|
+
o.output = Shapes::ShapeRef.new(shape: ListClustersOutput)
|
308
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
309
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
310
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
311
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
312
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
313
|
+
o[:pager] = Aws::Pager.new(
|
314
|
+
limit_key: "max_results",
|
315
|
+
tokens: {
|
316
|
+
"next_token" => "next_token"
|
317
|
+
}
|
318
|
+
)
|
319
|
+
end)
|
320
|
+
|
321
|
+
api.add_operation(:list_tags_for_resource, Seahorse::Model::Operation.new.tap do |o|
|
322
|
+
o.name = "ListTagsForResource"
|
323
|
+
o.http_method = "GET"
|
324
|
+
o.http_request_uri = "/tags/{resourceArn}"
|
325
|
+
o.input = Shapes::ShapeRef.new(shape: ListTagsForResourceInput)
|
326
|
+
o.output = Shapes::ShapeRef.new(shape: ListTagsForResourceOutput)
|
327
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
328
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
329
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
330
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
331
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
332
|
+
end)
|
333
|
+
|
334
|
+
api.add_operation(:tag_resource, Seahorse::Model::Operation.new.tap do |o|
|
335
|
+
o.name = "TagResource"
|
336
|
+
o.http_method = "POST"
|
337
|
+
o.http_request_uri = "/tags/{resourceArn}"
|
338
|
+
o.input = Shapes::ShapeRef.new(shape: TagResourceInput)
|
339
|
+
o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
|
340
|
+
o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
|
341
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
342
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
343
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
344
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
345
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
346
|
+
end)
|
347
|
+
|
348
|
+
api.add_operation(:untag_resource, Seahorse::Model::Operation.new.tap do |o|
|
349
|
+
o.name = "UntagResource"
|
350
|
+
o.http_method = "DELETE"
|
351
|
+
o.http_request_uri = "/tags/{resourceArn}"
|
352
|
+
o.input = Shapes::ShapeRef.new(shape: UntagResourceInput)
|
353
|
+
o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
|
354
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
355
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
356
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
357
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
358
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
359
|
+
end)
|
360
|
+
|
361
|
+
api.add_operation(:update_cluster, Seahorse::Model::Operation.new.tap do |o|
|
362
|
+
o.name = "UpdateCluster"
|
363
|
+
o.http_method = "POST"
|
364
|
+
o.http_request_uri = "/cluster/{identifier}"
|
365
|
+
o.input = Shapes::ShapeRef.new(shape: UpdateClusterInput)
|
366
|
+
o.output = Shapes::ShapeRef.new(shape: UpdateClusterOutput)
|
367
|
+
o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
|
368
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
369
|
+
o.errors << Shapes::ShapeRef.new(shape: ValidationException)
|
370
|
+
o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
|
371
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
372
|
+
o.errors << Shapes::ShapeRef.new(shape: ConflictException)
|
373
|
+
end)
|
374
|
+
end
|
375
|
+
|
376
|
+
end
|
377
|
+
end
|
@@ -0,0 +1,70 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'aws-sigv4'
|
4
|
+
|
5
|
+
module Aws
|
6
|
+
module DSQL
|
7
|
+
# A utility class that generates an auth token that supports database
|
8
|
+
# logins for DSQL clusters. IAM credentials are used for authentication
|
9
|
+
# instead of the database password.
|
10
|
+
class AuthTokenGenerator
|
11
|
+
# @option options [Credentials] :credentials An object that
|
12
|
+
# responds to `#credentials` returning another object that responds to
|
13
|
+
# `#access_key_id`, `#secret_access_key`, and `#session_token`.
|
14
|
+
def initialize(options = {})
|
15
|
+
@credentials = options.fetch(:credentials)
|
16
|
+
end
|
17
|
+
|
18
|
+
# Generates an auth token for the DbConnect action.
|
19
|
+
#
|
20
|
+
# @param [Hash] options
|
21
|
+
# @option options [String] :region The AWS region where the DSQL Cluster
|
22
|
+
# is hosted. Defaults to the region of the client.
|
23
|
+
# @option options [String] :endpoint The DSQL endpoint host name.
|
24
|
+
# @option options [Integer] :expires_in (900) The number of seconds the
|
25
|
+
# presigned URL is valid for.
|
26
|
+
# @return [String]
|
27
|
+
def generate_db_connect_auth_token(options = {})
|
28
|
+
presigned_token(options, 'DbConnect')
|
29
|
+
end
|
30
|
+
|
31
|
+
# Generates an auth token for the DbConnectAdmin action.
|
32
|
+
#
|
33
|
+
# @param [Hash] options
|
34
|
+
# @option options [String] :region The AWS region where the DSQL Cluster
|
35
|
+
# is hosted. Defaults to the region of the client.
|
36
|
+
# @option options [String] :endpoint The DSQL endpoint host name.
|
37
|
+
# @option options [Integer] :expires_in (900) The number of seconds the
|
38
|
+
# token is valid for.
|
39
|
+
# @return [String]
|
40
|
+
def generate_db_connect_admin_auth_token(options = {})
|
41
|
+
presigned_token(options, 'DbConnectAdmin')
|
42
|
+
end
|
43
|
+
|
44
|
+
private
|
45
|
+
|
46
|
+
def presigned_token(options, action)
|
47
|
+
region = options.fetch(:region)
|
48
|
+
endpoint = options.fetch(:endpoint)
|
49
|
+
|
50
|
+
param_list = Aws::Query::ParamList.new
|
51
|
+
param_list.set('Action', action)
|
52
|
+
|
53
|
+
signer = Aws::Sigv4::Signer.new(
|
54
|
+
service: 'dsql',
|
55
|
+
region: region,
|
56
|
+
credentials_provider: @credentials
|
57
|
+
)
|
58
|
+
|
59
|
+
presigned_url = signer.presign_url(
|
60
|
+
http_method: 'GET',
|
61
|
+
url: "https://#{endpoint}/?#{param_list}",
|
62
|
+
body: '',
|
63
|
+
expires_in: options[:expires_in]
|
64
|
+
).to_s
|
65
|
+
# Remove extra scheme for token
|
66
|
+
presigned_url[8..-1]
|
67
|
+
end
|
68
|
+
end
|
69
|
+
end
|
70
|
+
end
|
@@ -0,0 +1,59 @@
|
|
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
|
+
module Aws::DSQL
|
11
|
+
# Endpoint parameters used to influence endpoints per request.
|
12
|
+
#
|
13
|
+
# @!attribute use_fips
|
14
|
+
# When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.
|
15
|
+
#
|
16
|
+
# @return [Boolean]
|
17
|
+
#
|
18
|
+
# @!attribute endpoint
|
19
|
+
# Override the endpoint used to send this request
|
20
|
+
#
|
21
|
+
# @return [String]
|
22
|
+
#
|
23
|
+
# @!attribute region
|
24
|
+
# The AWS region used to dispatch the request.
|
25
|
+
#
|
26
|
+
# @return [String]
|
27
|
+
#
|
28
|
+
EndpointParameters = Struct.new(
|
29
|
+
:use_fips,
|
30
|
+
:endpoint,
|
31
|
+
:region,
|
32
|
+
) do
|
33
|
+
include Aws::Structure
|
34
|
+
|
35
|
+
# @api private
|
36
|
+
class << self
|
37
|
+
PARAM_MAP = {
|
38
|
+
'UseFIPS' => :use_fips,
|
39
|
+
'Endpoint' => :endpoint,
|
40
|
+
'Region' => :region,
|
41
|
+
}.freeze
|
42
|
+
end
|
43
|
+
|
44
|
+
def initialize(options = {})
|
45
|
+
self[:use_fips] = options[:use_fips]
|
46
|
+
self[:use_fips] = false if self[:use_fips].nil?
|
47
|
+
self[:endpoint] = options[:endpoint]
|
48
|
+
self[:region] = options[:region]
|
49
|
+
end
|
50
|
+
|
51
|
+
def self.create(config, options={})
|
52
|
+
new({
|
53
|
+
use_fips: config.use_fips_endpoint,
|
54
|
+
endpoint: (config.endpoint.to_s unless config.regional_endpoint),
|
55
|
+
region: config.region,
|
56
|
+
}.merge(options))
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
@@ -0,0 +1,35 @@
|
|
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
|
+
module Aws::DSQL
|
11
|
+
class EndpointProvider
|
12
|
+
def resolve_endpoint(parameters)
|
13
|
+
use_fips = parameters.use_fips
|
14
|
+
endpoint = parameters.endpoint
|
15
|
+
region = parameters.region
|
16
|
+
if Aws::Endpoints::Matchers.set?(endpoint)
|
17
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
18
|
+
raise ArgumentError, "Invalid Configuration: FIPS and custom endpoint are not supported"
|
19
|
+
end
|
20
|
+
return Aws::Endpoints::Endpoint.new(url: endpoint, headers: {}, properties: {})
|
21
|
+
end
|
22
|
+
if Aws::Endpoints::Matchers.set?(region)
|
23
|
+
if (partition_result = Aws::Endpoints::Matchers.aws_partition(region))
|
24
|
+
if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
|
25
|
+
return Aws::Endpoints::Endpoint.new(url: "https://dsql-fips.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
|
26
|
+
end
|
27
|
+
return Aws::Endpoints::Endpoint.new(url: "https://dsql.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
|
28
|
+
end
|
29
|
+
end
|
30
|
+
raise ArgumentError, "Invalid Configuration: Missing Region"
|
31
|
+
raise ArgumentError, 'No endpoint could be resolved'
|
32
|
+
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
@@ -0,0 +1,20 @@
|
|
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
|
+
|
11
|
+
module Aws::DSQL
|
12
|
+
# @api private
|
13
|
+
module Endpoints
|
14
|
+
|
15
|
+
|
16
|
+
def self.parameters_for_operation(context)
|
17
|
+
Aws::DSQL::EndpointParameters.create(context.config)
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|