aws-sdk-athena 1.7.0 → 1.8.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -16,16 +16,22 @@ module Aws::Athena
16
16
  BatchGetQueryExecutionInput = Shapes::StructureShape.new(name: 'BatchGetQueryExecutionInput')
17
17
  BatchGetQueryExecutionOutput = Shapes::StructureShape.new(name: 'BatchGetQueryExecutionOutput')
18
18
  Boolean = Shapes::BooleanShape.new(name: 'Boolean')
19
+ BoxedBoolean = Shapes::BooleanShape.new(name: 'BoxedBoolean')
20
+ BytesScannedCutoffValue = Shapes::IntegerShape.new(name: 'BytesScannedCutoffValue')
19
21
  ColumnInfo = Shapes::StructureShape.new(name: 'ColumnInfo')
20
22
  ColumnInfoList = Shapes::ListShape.new(name: 'ColumnInfoList')
21
23
  ColumnNullable = Shapes::StringShape.new(name: 'ColumnNullable')
22
24
  CreateNamedQueryInput = Shapes::StructureShape.new(name: 'CreateNamedQueryInput')
23
25
  CreateNamedQueryOutput = Shapes::StructureShape.new(name: 'CreateNamedQueryOutput')
26
+ CreateWorkGroupInput = Shapes::StructureShape.new(name: 'CreateWorkGroupInput')
27
+ CreateWorkGroupOutput = Shapes::StructureShape.new(name: 'CreateWorkGroupOutput')
24
28
  DatabaseString = Shapes::StringShape.new(name: 'DatabaseString')
25
29
  Date = Shapes::TimestampShape.new(name: 'Date')
26
30
  Datum = Shapes::StructureShape.new(name: 'Datum')
27
31
  DeleteNamedQueryInput = Shapes::StructureShape.new(name: 'DeleteNamedQueryInput')
28
32
  DeleteNamedQueryOutput = Shapes::StructureShape.new(name: 'DeleteNamedQueryOutput')
33
+ DeleteWorkGroupInput = Shapes::StructureShape.new(name: 'DeleteWorkGroupInput')
34
+ DeleteWorkGroupOutput = Shapes::StructureShape.new(name: 'DeleteWorkGroupOutput')
29
35
  DescriptionString = Shapes::StringShape.new(name: 'DescriptionString')
30
36
  EncryptionConfiguration = Shapes::StructureShape.new(name: 'EncryptionConfiguration')
31
37
  EncryptionOption = Shapes::StringShape.new(name: 'EncryptionOption')
@@ -37,6 +43,8 @@ module Aws::Athena
37
43
  GetQueryExecutionOutput = Shapes::StructureShape.new(name: 'GetQueryExecutionOutput')
38
44
  GetQueryResultsInput = Shapes::StructureShape.new(name: 'GetQueryResultsInput')
39
45
  GetQueryResultsOutput = Shapes::StructureShape.new(name: 'GetQueryResultsOutput')
46
+ GetWorkGroupInput = Shapes::StructureShape.new(name: 'GetWorkGroupInput')
47
+ GetWorkGroupOutput = Shapes::StructureShape.new(name: 'GetWorkGroupOutput')
40
48
  IdempotencyToken = Shapes::StringShape.new(name: 'IdempotencyToken')
41
49
  Integer = Shapes::IntegerShape.new(name: 'Integer')
42
50
  InternalServerException = Shapes::StructureShape.new(name: 'InternalServerException')
@@ -45,10 +53,13 @@ module Aws::Athena
45
53
  ListNamedQueriesOutput = Shapes::StructureShape.new(name: 'ListNamedQueriesOutput')
46
54
  ListQueryExecutionsInput = Shapes::StructureShape.new(name: 'ListQueryExecutionsInput')
47
55
  ListQueryExecutionsOutput = Shapes::StructureShape.new(name: 'ListQueryExecutionsOutput')
56
+ ListWorkGroupsInput = Shapes::StructureShape.new(name: 'ListWorkGroupsInput')
57
+ ListWorkGroupsOutput = Shapes::StructureShape.new(name: 'ListWorkGroupsOutput')
48
58
  Long = Shapes::IntegerShape.new(name: 'Long')
49
59
  MaxNamedQueriesCount = Shapes::IntegerShape.new(name: 'MaxNamedQueriesCount')
50
60
  MaxQueryExecutionsCount = Shapes::IntegerShape.new(name: 'MaxQueryExecutionsCount')
51
61
  MaxQueryResults = Shapes::IntegerShape.new(name: 'MaxQueryResults')
62
+ MaxWorkGroupsCount = Shapes::IntegerShape.new(name: 'MaxWorkGroupsCount')
52
63
  NameString = Shapes::StringShape.new(name: 'NameString')
53
64
  NamedQuery = Shapes::StructureShape.new(name: 'NamedQuery')
54
65
  NamedQueryId = Shapes::StringShape.new(name: 'NamedQueryId')
@@ -64,6 +75,7 @@ module Aws::Athena
64
75
  QueryExecutionStatus = Shapes::StructureShape.new(name: 'QueryExecutionStatus')
65
76
  QueryString = Shapes::StringShape.new(name: 'QueryString')
66
77
  ResultConfiguration = Shapes::StructureShape.new(name: 'ResultConfiguration')
78
+ ResultConfigurationUpdates = Shapes::StructureShape.new(name: 'ResultConfigurationUpdates')
67
79
  ResultSet = Shapes::StructureShape.new(name: 'ResultSet')
68
80
  ResultSetMetadata = Shapes::StructureShape.new(name: 'ResultSetMetadata')
69
81
  Row = Shapes::StructureShape.new(name: 'Row')
@@ -81,6 +93,16 @@ module Aws::Athena
81
93
  UnprocessedNamedQueryIdList = Shapes::ListShape.new(name: 'UnprocessedNamedQueryIdList')
82
94
  UnprocessedQueryExecutionId = Shapes::StructureShape.new(name: 'UnprocessedQueryExecutionId')
83
95
  UnprocessedQueryExecutionIdList = Shapes::ListShape.new(name: 'UnprocessedQueryExecutionIdList')
96
+ UpdateWorkGroupInput = Shapes::StructureShape.new(name: 'UpdateWorkGroupInput')
97
+ UpdateWorkGroupOutput = Shapes::StructureShape.new(name: 'UpdateWorkGroupOutput')
98
+ WorkGroup = Shapes::StructureShape.new(name: 'WorkGroup')
99
+ WorkGroupConfiguration = Shapes::StructureShape.new(name: 'WorkGroupConfiguration')
100
+ WorkGroupConfigurationUpdates = Shapes::StructureShape.new(name: 'WorkGroupConfigurationUpdates')
101
+ WorkGroupDescriptionString = Shapes::StringShape.new(name: 'WorkGroupDescriptionString')
102
+ WorkGroupName = Shapes::StringShape.new(name: 'WorkGroupName')
103
+ WorkGroupState = Shapes::StringShape.new(name: 'WorkGroupState')
104
+ WorkGroupSummary = Shapes::StructureShape.new(name: 'WorkGroupSummary')
105
+ WorkGroupsList = Shapes::ListShape.new(name: 'WorkGroupsList')
84
106
  datumList = Shapes::ListShape.new(name: 'datumList')
85
107
  datumString = Shapes::StringShape.new(name: 'datumString')
86
108
 
@@ -117,11 +139,19 @@ module Aws::Athena
117
139
  CreateNamedQueryInput.add_member(:database, Shapes::ShapeRef.new(shape: DatabaseString, required: true, location_name: "Database"))
118
140
  CreateNamedQueryInput.add_member(:query_string, Shapes::ShapeRef.new(shape: QueryString, required: true, location_name: "QueryString"))
119
141
  CreateNamedQueryInput.add_member(:client_request_token, Shapes::ShapeRef.new(shape: IdempotencyToken, location_name: "ClientRequestToken", metadata: {"idempotencyToken"=>true}))
142
+ CreateNamedQueryInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
120
143
  CreateNamedQueryInput.struct_class = Types::CreateNamedQueryInput
121
144
 
122
145
  CreateNamedQueryOutput.add_member(:named_query_id, Shapes::ShapeRef.new(shape: NamedQueryId, location_name: "NamedQueryId"))
123
146
  CreateNamedQueryOutput.struct_class = Types::CreateNamedQueryOutput
124
147
 
148
+ CreateWorkGroupInput.add_member(:name, Shapes::ShapeRef.new(shape: WorkGroupName, required: true, location_name: "Name"))
149
+ CreateWorkGroupInput.add_member(:configuration, Shapes::ShapeRef.new(shape: WorkGroupConfiguration, location_name: "Configuration"))
150
+ CreateWorkGroupInput.add_member(:description, Shapes::ShapeRef.new(shape: WorkGroupDescriptionString, location_name: "Description"))
151
+ CreateWorkGroupInput.struct_class = Types::CreateWorkGroupInput
152
+
153
+ CreateWorkGroupOutput.struct_class = Types::CreateWorkGroupOutput
154
+
125
155
  Datum.add_member(:var_char_value, Shapes::ShapeRef.new(shape: datumString, location_name: "VarCharValue"))
126
156
  Datum.struct_class = Types::Datum
127
157
 
@@ -130,6 +160,12 @@ module Aws::Athena
130
160
 
131
161
  DeleteNamedQueryOutput.struct_class = Types::DeleteNamedQueryOutput
132
162
 
163
+ DeleteWorkGroupInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, required: true, location_name: "WorkGroup"))
164
+ DeleteWorkGroupInput.add_member(:recursive_delete_option, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "RecursiveDeleteOption"))
165
+ DeleteWorkGroupInput.struct_class = Types::DeleteWorkGroupInput
166
+
167
+ DeleteWorkGroupOutput.struct_class = Types::DeleteWorkGroupOutput
168
+
133
169
  EncryptionConfiguration.add_member(:encryption_option, Shapes::ShapeRef.new(shape: EncryptionOption, required: true, location_name: "EncryptionOption"))
134
170
  EncryptionConfiguration.add_member(:kms_key, Shapes::ShapeRef.new(shape: String, location_name: "KmsKey"))
135
171
  EncryptionConfiguration.struct_class = Types::EncryptionConfiguration
@@ -156,8 +192,15 @@ module Aws::Athena
156
192
  GetQueryResultsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
157
193
  GetQueryResultsOutput.struct_class = Types::GetQueryResultsOutput
158
194
 
195
+ GetWorkGroupInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, required: true, location_name: "WorkGroup"))
196
+ GetWorkGroupInput.struct_class = Types::GetWorkGroupInput
197
+
198
+ GetWorkGroupOutput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroup, location_name: "WorkGroup"))
199
+ GetWorkGroupOutput.struct_class = Types::GetWorkGroupOutput
200
+
159
201
  ListNamedQueriesInput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
160
202
  ListNamedQueriesInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxNamedQueriesCount, location_name: "MaxResults"))
203
+ ListNamedQueriesInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
161
204
  ListNamedQueriesInput.struct_class = Types::ListNamedQueriesInput
162
205
 
163
206
  ListNamedQueriesOutput.add_member(:named_query_ids, Shapes::ShapeRef.new(shape: NamedQueryIdList, location_name: "NamedQueryIds"))
@@ -166,17 +209,27 @@ module Aws::Athena
166
209
 
167
210
  ListQueryExecutionsInput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
168
211
  ListQueryExecutionsInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxQueryExecutionsCount, location_name: "MaxResults"))
212
+ ListQueryExecutionsInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
169
213
  ListQueryExecutionsInput.struct_class = Types::ListQueryExecutionsInput
170
214
 
171
215
  ListQueryExecutionsOutput.add_member(:query_execution_ids, Shapes::ShapeRef.new(shape: QueryExecutionIdList, location_name: "QueryExecutionIds"))
172
216
  ListQueryExecutionsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
173
217
  ListQueryExecutionsOutput.struct_class = Types::ListQueryExecutionsOutput
174
218
 
219
+ ListWorkGroupsInput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
220
+ ListWorkGroupsInput.add_member(:max_results, Shapes::ShapeRef.new(shape: MaxWorkGroupsCount, location_name: "MaxResults"))
221
+ ListWorkGroupsInput.struct_class = Types::ListWorkGroupsInput
222
+
223
+ ListWorkGroupsOutput.add_member(:work_groups, Shapes::ShapeRef.new(shape: WorkGroupsList, location_name: "WorkGroups"))
224
+ ListWorkGroupsOutput.add_member(:next_token, Shapes::ShapeRef.new(shape: Token, location_name: "NextToken"))
225
+ ListWorkGroupsOutput.struct_class = Types::ListWorkGroupsOutput
226
+
175
227
  NamedQuery.add_member(:name, Shapes::ShapeRef.new(shape: NameString, required: true, location_name: "Name"))
176
228
  NamedQuery.add_member(:description, Shapes::ShapeRef.new(shape: DescriptionString, location_name: "Description"))
177
229
  NamedQuery.add_member(:database, Shapes::ShapeRef.new(shape: DatabaseString, required: true, location_name: "Database"))
178
230
  NamedQuery.add_member(:query_string, Shapes::ShapeRef.new(shape: QueryString, required: true, location_name: "QueryString"))
179
231
  NamedQuery.add_member(:named_query_id, Shapes::ShapeRef.new(shape: NamedQueryId, location_name: "NamedQueryId"))
232
+ NamedQuery.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
180
233
  NamedQuery.struct_class = Types::NamedQuery
181
234
 
182
235
  NamedQueryIdList.member = Shapes::ShapeRef.new(shape: NamedQueryId)
@@ -190,6 +243,7 @@ module Aws::Athena
190
243
  QueryExecution.add_member(:query_execution_context, Shapes::ShapeRef.new(shape: QueryExecutionContext, location_name: "QueryExecutionContext"))
191
244
  QueryExecution.add_member(:status, Shapes::ShapeRef.new(shape: QueryExecutionStatus, location_name: "Status"))
192
245
  QueryExecution.add_member(:statistics, Shapes::ShapeRef.new(shape: QueryExecutionStatistics, location_name: "Statistics"))
246
+ QueryExecution.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
193
247
  QueryExecution.struct_class = Types::QueryExecution
194
248
 
195
249
  QueryExecutionContext.add_member(:database, Shapes::ShapeRef.new(shape: DatabaseString, location_name: "Database"))
@@ -209,10 +263,16 @@ module Aws::Athena
209
263
  QueryExecutionStatus.add_member(:completion_date_time, Shapes::ShapeRef.new(shape: Date, location_name: "CompletionDateTime"))
210
264
  QueryExecutionStatus.struct_class = Types::QueryExecutionStatus
211
265
 
212
- ResultConfiguration.add_member(:output_location, Shapes::ShapeRef.new(shape: String, required: true, location_name: "OutputLocation"))
266
+ ResultConfiguration.add_member(:output_location, Shapes::ShapeRef.new(shape: String, location_name: "OutputLocation"))
213
267
  ResultConfiguration.add_member(:encryption_configuration, Shapes::ShapeRef.new(shape: EncryptionConfiguration, location_name: "EncryptionConfiguration"))
214
268
  ResultConfiguration.struct_class = Types::ResultConfiguration
215
269
 
270
+ ResultConfigurationUpdates.add_member(:output_location, Shapes::ShapeRef.new(shape: String, location_name: "OutputLocation"))
271
+ ResultConfigurationUpdates.add_member(:remove_output_location, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "RemoveOutputLocation"))
272
+ ResultConfigurationUpdates.add_member(:encryption_configuration, Shapes::ShapeRef.new(shape: EncryptionConfiguration, location_name: "EncryptionConfiguration"))
273
+ ResultConfigurationUpdates.add_member(:remove_encryption_configuration, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "RemoveEncryptionConfiguration"))
274
+ ResultConfigurationUpdates.struct_class = Types::ResultConfigurationUpdates
275
+
216
276
  ResultSet.add_member(:rows, Shapes::ShapeRef.new(shape: RowList, location_name: "Rows"))
217
277
  ResultSet.add_member(:result_set_metadata, Shapes::ShapeRef.new(shape: ResultSetMetadata, location_name: "ResultSetMetadata"))
218
278
  ResultSet.struct_class = Types::ResultSet
@@ -228,7 +288,8 @@ module Aws::Athena
228
288
  StartQueryExecutionInput.add_member(:query_string, Shapes::ShapeRef.new(shape: QueryString, required: true, location_name: "QueryString"))
229
289
  StartQueryExecutionInput.add_member(:client_request_token, Shapes::ShapeRef.new(shape: IdempotencyToken, location_name: "ClientRequestToken", metadata: {"idempotencyToken"=>true}))
230
290
  StartQueryExecutionInput.add_member(:query_execution_context, Shapes::ShapeRef.new(shape: QueryExecutionContext, location_name: "QueryExecutionContext"))
231
- StartQueryExecutionInput.add_member(:result_configuration, Shapes::ShapeRef.new(shape: ResultConfiguration, required: true, location_name: "ResultConfiguration"))
291
+ StartQueryExecutionInput.add_member(:result_configuration, Shapes::ShapeRef.new(shape: ResultConfiguration, location_name: "ResultConfiguration"))
292
+ StartQueryExecutionInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "WorkGroup"))
232
293
  StartQueryExecutionInput.struct_class = Types::StartQueryExecutionInput
233
294
 
234
295
  StartQueryExecutionOutput.add_member(:query_execution_id, Shapes::ShapeRef.new(shape: QueryExecutionId, location_name: "QueryExecutionId"))
@@ -253,6 +314,42 @@ module Aws::Athena
253
314
 
254
315
  UnprocessedQueryExecutionIdList.member = Shapes::ShapeRef.new(shape: UnprocessedQueryExecutionId)
255
316
 
317
+ UpdateWorkGroupInput.add_member(:work_group, Shapes::ShapeRef.new(shape: WorkGroupName, required: true, location_name: "WorkGroup"))
318
+ UpdateWorkGroupInput.add_member(:description, Shapes::ShapeRef.new(shape: WorkGroupDescriptionString, location_name: "Description"))
319
+ UpdateWorkGroupInput.add_member(:configuration_updates, Shapes::ShapeRef.new(shape: WorkGroupConfigurationUpdates, location_name: "ConfigurationUpdates"))
320
+ UpdateWorkGroupInput.add_member(:state, Shapes::ShapeRef.new(shape: WorkGroupState, location_name: "State"))
321
+ UpdateWorkGroupInput.struct_class = Types::UpdateWorkGroupInput
322
+
323
+ UpdateWorkGroupOutput.struct_class = Types::UpdateWorkGroupOutput
324
+
325
+ WorkGroup.add_member(:name, Shapes::ShapeRef.new(shape: WorkGroupName, required: true, location_name: "Name"))
326
+ WorkGroup.add_member(:state, Shapes::ShapeRef.new(shape: WorkGroupState, location_name: "State"))
327
+ WorkGroup.add_member(:configuration, Shapes::ShapeRef.new(shape: WorkGroupConfiguration, location_name: "Configuration"))
328
+ WorkGroup.add_member(:description, Shapes::ShapeRef.new(shape: WorkGroupDescriptionString, location_name: "Description"))
329
+ WorkGroup.add_member(:creation_time, Shapes::ShapeRef.new(shape: Date, location_name: "CreationTime"))
330
+ WorkGroup.struct_class = Types::WorkGroup
331
+
332
+ WorkGroupConfiguration.add_member(:result_configuration, Shapes::ShapeRef.new(shape: ResultConfiguration, location_name: "ResultConfiguration"))
333
+ WorkGroupConfiguration.add_member(:enforce_work_group_configuration, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "EnforceWorkGroupConfiguration"))
334
+ WorkGroupConfiguration.add_member(:publish_cloud_watch_metrics_enabled, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "PublishCloudWatchMetricsEnabled"))
335
+ WorkGroupConfiguration.add_member(:bytes_scanned_cutoff_per_query, Shapes::ShapeRef.new(shape: BytesScannedCutoffValue, location_name: "BytesScannedCutoffPerQuery"))
336
+ WorkGroupConfiguration.struct_class = Types::WorkGroupConfiguration
337
+
338
+ WorkGroupConfigurationUpdates.add_member(:enforce_work_group_configuration, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "EnforceWorkGroupConfiguration"))
339
+ WorkGroupConfigurationUpdates.add_member(:result_configuration_updates, Shapes::ShapeRef.new(shape: ResultConfigurationUpdates, location_name: "ResultConfigurationUpdates"))
340
+ WorkGroupConfigurationUpdates.add_member(:publish_cloud_watch_metrics_enabled, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "PublishCloudWatchMetricsEnabled"))
341
+ WorkGroupConfigurationUpdates.add_member(:bytes_scanned_cutoff_per_query, Shapes::ShapeRef.new(shape: BytesScannedCutoffValue, location_name: "BytesScannedCutoffPerQuery"))
342
+ WorkGroupConfigurationUpdates.add_member(:remove_bytes_scanned_cutoff_per_query, Shapes::ShapeRef.new(shape: BoxedBoolean, location_name: "RemoveBytesScannedCutoffPerQuery"))
343
+ WorkGroupConfigurationUpdates.struct_class = Types::WorkGroupConfigurationUpdates
344
+
345
+ WorkGroupSummary.add_member(:name, Shapes::ShapeRef.new(shape: WorkGroupName, location_name: "Name"))
346
+ WorkGroupSummary.add_member(:state, Shapes::ShapeRef.new(shape: WorkGroupState, location_name: "State"))
347
+ WorkGroupSummary.add_member(:description, Shapes::ShapeRef.new(shape: WorkGroupDescriptionString, location_name: "Description"))
348
+ WorkGroupSummary.add_member(:creation_time, Shapes::ShapeRef.new(shape: Date, location_name: "CreationTime"))
349
+ WorkGroupSummary.struct_class = Types::WorkGroupSummary
350
+
351
+ WorkGroupsList.member = Shapes::ShapeRef.new(shape: WorkGroupSummary)
352
+
256
353
  datumList.member = Shapes::ShapeRef.new(shape: Datum)
257
354
 
258
355
 
@@ -303,6 +400,16 @@ module Aws::Athena
303
400
  o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
304
401
  end)
305
402
 
403
+ api.add_operation(:create_work_group, Seahorse::Model::Operation.new.tap do |o|
404
+ o.name = "CreateWorkGroup"
405
+ o.http_method = "POST"
406
+ o.http_request_uri = "/"
407
+ o.input = Shapes::ShapeRef.new(shape: CreateWorkGroupInput)
408
+ o.output = Shapes::ShapeRef.new(shape: CreateWorkGroupOutput)
409
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
410
+ o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
411
+ end)
412
+
306
413
  api.add_operation(:delete_named_query, Seahorse::Model::Operation.new.tap do |o|
307
414
  o.name = "DeleteNamedQuery"
308
415
  o.http_method = "POST"
@@ -313,6 +420,16 @@ module Aws::Athena
313
420
  o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
314
421
  end)
315
422
 
423
+ api.add_operation(:delete_work_group, Seahorse::Model::Operation.new.tap do |o|
424
+ o.name = "DeleteWorkGroup"
425
+ o.http_method = "POST"
426
+ o.http_request_uri = "/"
427
+ o.input = Shapes::ShapeRef.new(shape: DeleteWorkGroupInput)
428
+ o.output = Shapes::ShapeRef.new(shape: DeleteWorkGroupOutput)
429
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
430
+ o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
431
+ end)
432
+
316
433
  api.add_operation(:get_named_query, Seahorse::Model::Operation.new.tap do |o|
317
434
  o.name = "GetNamedQuery"
318
435
  o.http_method = "POST"
@@ -349,6 +466,16 @@ module Aws::Athena
349
466
  )
350
467
  end)
351
468
 
469
+ api.add_operation(:get_work_group, Seahorse::Model::Operation.new.tap do |o|
470
+ o.name = "GetWorkGroup"
471
+ o.http_method = "POST"
472
+ o.http_request_uri = "/"
473
+ o.input = Shapes::ShapeRef.new(shape: GetWorkGroupInput)
474
+ o.output = Shapes::ShapeRef.new(shape: GetWorkGroupOutput)
475
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
476
+ o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
477
+ end)
478
+
352
479
  api.add_operation(:list_named_queries, Seahorse::Model::Operation.new.tap do |o|
353
480
  o.name = "ListNamedQueries"
354
481
  o.http_method = "POST"
@@ -381,6 +508,22 @@ module Aws::Athena
381
508
  )
382
509
  end)
383
510
 
511
+ api.add_operation(:list_work_groups, Seahorse::Model::Operation.new.tap do |o|
512
+ o.name = "ListWorkGroups"
513
+ o.http_method = "POST"
514
+ o.http_request_uri = "/"
515
+ o.input = Shapes::ShapeRef.new(shape: ListWorkGroupsInput)
516
+ o.output = Shapes::ShapeRef.new(shape: ListWorkGroupsOutput)
517
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
518
+ o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
519
+ o[:pager] = Aws::Pager.new(
520
+ limit_key: "max_results",
521
+ tokens: {
522
+ "next_token" => "next_token"
523
+ }
524
+ )
525
+ end)
526
+
384
527
  api.add_operation(:start_query_execution, Seahorse::Model::Operation.new.tap do |o|
385
528
  o.name = "StartQueryExecution"
386
529
  o.http_method = "POST"
@@ -401,6 +544,16 @@ module Aws::Athena
401
544
  o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
402
545
  o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
403
546
  end)
547
+
548
+ api.add_operation(:update_work_group, Seahorse::Model::Operation.new.tap do |o|
549
+ o.name = "UpdateWorkGroup"
550
+ o.http_method = "POST"
551
+ o.http_request_uri = "/"
552
+ o.input = Shapes::ShapeRef.new(shape: UpdateWorkGroupInput)
553
+ o.output = Shapes::ShapeRef.new(shape: UpdateWorkGroupOutput)
554
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerException)
555
+ o.errors << Shapes::ShapeRef.new(shape: InvalidRequestException)
556
+ end)
404
557
  end
405
558
 
406
559
  end
@@ -145,14 +145,15 @@ module Aws::Athena
145
145
  # database: "DatabaseString", # required
146
146
  # query_string: "QueryString", # required
147
147
  # client_request_token: "IdempotencyToken",
148
+ # work_group: "WorkGroupName",
148
149
  # }
149
150
  #
150
151
  # @!attribute [rw] name
151
- # The plain language name for the query.
152
+ # The query name.
152
153
  # @return [String]
153
154
  #
154
155
  # @!attribute [rw] description
155
- # A brief explanation of the query.
156
+ # The query description.
156
157
  # @return [String]
157
158
  #
158
159
  # @!attribute [rw] database
@@ -160,7 +161,7 @@ module Aws::Athena
160
161
  # @return [String]
161
162
  #
162
163
  # @!attribute [rw] query_string
163
- # The text of the query itself. In other words, all query statements.
164
+ # The contents of the query with all query statements.
164
165
  # @return [String]
165
166
  #
166
167
  # @!attribute [rw] client_request_token
@@ -179,6 +180,10 @@ module Aws::Athena
179
180
  # not need to pass this option.
180
181
  # @return [String]
181
182
  #
183
+ # @!attribute [rw] work_group
184
+ # The name of the workgroup in which the named query is being created.
185
+ # @return [String]
186
+ #
182
187
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/CreateNamedQueryInput AWS API Documentation
183
188
  #
184
189
  class CreateNamedQueryInput < Struct.new(
@@ -186,7 +191,8 @@ module Aws::Athena
186
191
  :description,
187
192
  :database,
188
193
  :query_string,
189
- :client_request_token)
194
+ :client_request_token,
195
+ :work_group)
190
196
  include Aws::Structure
191
197
  end
192
198
 
@@ -201,6 +207,59 @@ module Aws::Athena
201
207
  include Aws::Structure
202
208
  end
203
209
 
210
+ # @note When making an API call, you may pass CreateWorkGroupInput
211
+ # data as a hash:
212
+ #
213
+ # {
214
+ # name: "WorkGroupName", # required
215
+ # configuration: {
216
+ # result_configuration: {
217
+ # output_location: "String",
218
+ # encryption_configuration: {
219
+ # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
220
+ # kms_key: "String",
221
+ # },
222
+ # },
223
+ # enforce_work_group_configuration: false,
224
+ # publish_cloud_watch_metrics_enabled: false,
225
+ # bytes_scanned_cutoff_per_query: 1,
226
+ # },
227
+ # description: "WorkGroupDescriptionString",
228
+ # }
229
+ #
230
+ # @!attribute [rw] name
231
+ # The workgroup name.
232
+ # @return [String]
233
+ #
234
+ # @!attribute [rw] configuration
235
+ # The configuration for the workgroup, which includes the location in
236
+ # Amazon S3 where query results are stored, the encryption
237
+ # configuration, if any, used for encrypting query results, whether
238
+ # the Amazon CloudWatch Metrics are enabled for the workgroup, the
239
+ # limit for the amount of bytes scanned (cutoff) per query, if it is
240
+ # specified, and whether workgroup's settings (specified with
241
+ # EnforceWorkGroupConfiguration) in the WorkGroupConfiguration
242
+ # override client-side settings. See
243
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
244
+ # @return [Types::WorkGroupConfiguration]
245
+ #
246
+ # @!attribute [rw] description
247
+ # The workgroup description.
248
+ # @return [String]
249
+ #
250
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/CreateWorkGroupInput AWS API Documentation
251
+ #
252
+ class CreateWorkGroupInput < Struct.new(
253
+ :name,
254
+ :configuration,
255
+ :description)
256
+ include Aws::Structure
257
+ end
258
+
259
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/CreateWorkGroupOutput AWS API Documentation
260
+ #
261
+ class CreateWorkGroupOutput < Aws::EmptyStructure; end
262
+
204
263
  # A piece of data (a field in the table).
205
264
  #
206
265
  # @!attribute [rw] var_char_value
@@ -239,6 +298,35 @@ module Aws::Athena
239
298
  #
240
299
  class DeleteNamedQueryOutput < Aws::EmptyStructure; end
241
300
 
301
+ # @note When making an API call, you may pass DeleteWorkGroupInput
302
+ # data as a hash:
303
+ #
304
+ # {
305
+ # work_group: "WorkGroupName", # required
306
+ # recursive_delete_option: false,
307
+ # }
308
+ #
309
+ # @!attribute [rw] work_group
310
+ # The unique name of the workgroup to delete.
311
+ # @return [String]
312
+ #
313
+ # @!attribute [rw] recursive_delete_option
314
+ # The option to delete the workgroup and its contents even if the
315
+ # workgroup contains any named queries.
316
+ # @return [Boolean]
317
+ #
318
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/DeleteWorkGroupInput AWS API Documentation
319
+ #
320
+ class DeleteWorkGroupInput < Struct.new(
321
+ :work_group,
322
+ :recursive_delete_option)
323
+ include Aws::Structure
324
+ end
325
+
326
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/DeleteWorkGroupOutput AWS API Documentation
327
+ #
328
+ class DeleteWorkGroupOutput < Aws::EmptyStructure; end
329
+
242
330
  # If query results are encrypted in Amazon S3, indicates the encryption
243
331
  # option used (for example, `SSE-KMS` or `CSE-KMS`) and key information.
244
332
  #
@@ -255,6 +343,11 @@ module Aws::Athena
255
343
  # S3-managed keys (`SSE-S3`), server-side encryption with KMS-managed
256
344
  # keys (`SSE-KMS`), or client-side encryption with KMS-managed keys
257
345
  # (CSE-KMS) is used.
346
+ #
347
+ # If a query runs in a workgroup and the workgroup overrides
348
+ # client-side settings, then the workgroup's setting for encryption
349
+ # is used. It specifies whether query results must be encrypted, for
350
+ # all queries that run in this workgroup.
258
351
  # @return [String]
259
352
  #
260
353
  # @!attribute [rw] kms_key
@@ -379,12 +472,42 @@ module Aws::Athena
379
472
  include Aws::Structure
380
473
  end
381
474
 
475
+ # @note When making an API call, you may pass GetWorkGroupInput
476
+ # data as a hash:
477
+ #
478
+ # {
479
+ # work_group: "WorkGroupName", # required
480
+ # }
481
+ #
482
+ # @!attribute [rw] work_group
483
+ # The name of the workgroup.
484
+ # @return [String]
485
+ #
486
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/GetWorkGroupInput AWS API Documentation
487
+ #
488
+ class GetWorkGroupInput < Struct.new(
489
+ :work_group)
490
+ include Aws::Structure
491
+ end
492
+
493
+ # @!attribute [rw] work_group
494
+ # Information about the workgroup.
495
+ # @return [Types::WorkGroup]
496
+ #
497
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/GetWorkGroupOutput AWS API Documentation
498
+ #
499
+ class GetWorkGroupOutput < Struct.new(
500
+ :work_group)
501
+ include Aws::Structure
502
+ end
503
+
382
504
  # @note When making an API call, you may pass ListNamedQueriesInput
383
505
  # data as a hash:
384
506
  #
385
507
  # {
386
508
  # next_token: "Token",
387
509
  # max_results: 1,
510
+ # work_group: "WorkGroupName",
388
511
  # }
389
512
  #
390
513
  # @!attribute [rw] next_token
@@ -396,11 +519,17 @@ module Aws::Athena
396
519
  # The maximum number of queries to return in this request.
397
520
  # @return [Integer]
398
521
  #
522
+ # @!attribute [rw] work_group
523
+ # The name of the workgroup from which the named queries are being
524
+ # returned.
525
+ # @return [String]
526
+ #
399
527
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ListNamedQueriesInput AWS API Documentation
400
528
  #
401
529
  class ListNamedQueriesInput < Struct.new(
402
530
  :next_token,
403
- :max_results)
531
+ :max_results,
532
+ :work_group)
404
533
  include Aws::Structure
405
534
  end
406
535
 
@@ -426,6 +555,7 @@ module Aws::Athena
426
555
  # {
427
556
  # next_token: "Token",
428
557
  # max_results: 1,
558
+ # work_group: "WorkGroupName",
429
559
  # }
430
560
  #
431
561
  # @!attribute [rw] next_token
@@ -437,11 +567,16 @@ module Aws::Athena
437
567
  # The maximum number of query executions to return in this request.
438
568
  # @return [Integer]
439
569
  #
570
+ # @!attribute [rw] work_group
571
+ # The name of the workgroup from which queries are being returned.
572
+ # @return [String]
573
+ #
440
574
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ListQueryExecutionsInput AWS API Documentation
441
575
  #
442
576
  class ListQueryExecutionsInput < Struct.new(
443
577
  :next_token,
444
- :max_results)
578
+ :max_results,
579
+ :work_group)
445
580
  include Aws::Structure
446
581
  end
447
582
 
@@ -461,15 +596,56 @@ module Aws::Athena
461
596
  include Aws::Structure
462
597
  end
463
598
 
464
- # A query, where `QueryString` is the SQL query statements that comprise
465
- # the query.
599
+ # @note When making an API call, you may pass ListWorkGroupsInput
600
+ # data as a hash:
601
+ #
602
+ # {
603
+ # next_token: "Token",
604
+ # max_results: 1,
605
+ # }
606
+ #
607
+ # @!attribute [rw] next_token
608
+ # A token to be used by the next request if this request is truncated.
609
+ # @return [String]
610
+ #
611
+ # @!attribute [rw] max_results
612
+ # The maximum number of workgroups to return in this request.
613
+ # @return [Integer]
614
+ #
615
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ListWorkGroupsInput AWS API Documentation
616
+ #
617
+ class ListWorkGroupsInput < Struct.new(
618
+ :next_token,
619
+ :max_results)
620
+ include Aws::Structure
621
+ end
622
+
623
+ # @!attribute [rw] work_groups
624
+ # The list of workgroups, including their names, descriptions,
625
+ # creation times, and states.
626
+ # @return [Array<Types::WorkGroupSummary>]
627
+ #
628
+ # @!attribute [rw] next_token
629
+ # A token to be used by the next request if this request is truncated.
630
+ # @return [String]
631
+ #
632
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ListWorkGroupsOutput AWS API Documentation
633
+ #
634
+ class ListWorkGroupsOutput < Struct.new(
635
+ :work_groups,
636
+ :next_token)
637
+ include Aws::Structure
638
+ end
639
+
640
+ # A query, where `QueryString` is the list of SQL query statements that
641
+ # comprise the query.
466
642
  #
467
643
  # @!attribute [rw] name
468
- # The plain-language name of the query.
644
+ # The query name.
469
645
  # @return [String]
470
646
  #
471
647
  # @!attribute [rw] description
472
- # A brief description of the query.
648
+ # The query description.
473
649
  # @return [String]
474
650
  #
475
651
  # @!attribute [rw] database
@@ -484,6 +660,10 @@ module Aws::Athena
484
660
  # The unique identifier of the query.
485
661
  # @return [String]
486
662
  #
663
+ # @!attribute [rw] work_group
664
+ # The name of the workgroup that contains the named query.
665
+ # @return [String]
666
+ #
487
667
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/NamedQuery AWS API Documentation
488
668
  #
489
669
  class NamedQuery < Struct.new(
@@ -491,7 +671,8 @@ module Aws::Athena
491
671
  :description,
492
672
  :database,
493
673
  :query_string,
494
- :named_query_id)
674
+ :named_query_id,
675
+ :work_group)
495
676
  include Aws::Structure
496
677
  end
497
678
 
@@ -515,7 +696,11 @@ module Aws::Athena
515
696
  #
516
697
  # @!attribute [rw] result_configuration
517
698
  # The location in Amazon S3 where query results were stored and the
518
- # encryption option, if any, used for query results.
699
+ # encryption option, if any, used for query results. These are known
700
+ # as "client-side settings". If workgroup settings override
701
+ # client-side settings, then the query uses the location for the query
702
+ # results and the encryption configuration that are specified for the
703
+ # workgroup.
519
704
  # @return [Types::ResultConfiguration]
520
705
  #
521
706
  # @!attribute [rw] query_execution_context
@@ -533,6 +718,10 @@ module Aws::Athena
533
718
  # run.
534
719
  # @return [Types::QueryExecutionStatistics]
535
720
  #
721
+ # @!attribute [rw] work_group
722
+ # The name of the workgroup in which the query ran.
723
+ # @return [String]
724
+ #
536
725
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/QueryExecution AWS API Documentation
537
726
  #
538
727
  class QueryExecution < Struct.new(
@@ -542,7 +731,8 @@ module Aws::Athena
542
731
  :result_configuration,
543
732
  :query_execution_context,
544
733
  :status,
545
- :statistics)
734
+ :statistics,
735
+ :work_group)
546
736
  include Aws::Structure
547
737
  end
548
738
 
@@ -594,10 +784,10 @@ module Aws::Athena
594
784
  # used by Athena and is reserved for future use. `RUNNING` indicates
595
785
  # that the query has been submitted to the service, and Athena will
596
786
  # execute the query as soon as resources are available. `SUCCEEDED`
597
- # indicates that the query completed without error. `FAILED` indicates
598
- # that the query experienced an error and did not complete
599
- # processing.`CANCELLED` indicates that user input interrupted query
600
- # execution.
787
+ # indicates that the query completed without errors. `FAILED`
788
+ # indicates that the query experienced an error and did not complete
789
+ # processing. `CANCELLED` indicates that a user input interrupted
790
+ # query execution.
601
791
  # @return [String]
602
792
  #
603
793
  # @!attribute [rw] state_change_reason
@@ -623,13 +813,16 @@ module Aws::Athena
623
813
  end
624
814
 
625
815
  # The location in Amazon S3 where query results are stored and the
626
- # encryption option, if any, used for query results.
816
+ # encryption option, if any, used for query results. These are known as
817
+ # "client-side settings". If workgroup settings override client-side
818
+ # settings, then the query uses the location for the query results and
819
+ # the encryption configuration that are specified for the workgroup.
627
820
  #
628
821
  # @note When making an API call, you may pass ResultConfiguration
629
822
  # data as a hash:
630
823
  #
631
824
  # {
632
- # output_location: "String", # required
825
+ # output_location: "String",
633
826
  # encryption_configuration: {
634
827
  # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
635
828
  # kms_key: "String",
@@ -639,17 +832,32 @@ module Aws::Athena
639
832
  # @!attribute [rw] output_location
640
833
  # The location in Amazon S3 where your query results are stored, such
641
834
  # as `s3://path/to/query/bucket/`. For more information, see [Queries
642
- # and Query Result Files. ][1]
835
+ # and Query Result Files.][1] If workgroup settings override
836
+ # client-side settings, then the query uses the location for the query
837
+ # results and the encryption configuration that are specified for the
838
+ # workgroup. The "workgroup settings override" is specified in
839
+ # EnforceWorkGroupConfiguration (true/false) in the
840
+ # WorkGroupConfiguration. See
841
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
643
842
  #
644
843
  #
645
844
  #
646
- # [1]: http://docs.aws.amazon.com/athena/latest/ug/querying.html
845
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/querying.html
647
846
  # @return [String]
648
847
  #
649
848
  # @!attribute [rw] encryption_configuration
650
849
  # If query results are encrypted in Amazon S3, indicates the
651
850
  # encryption option used (for example, `SSE-KMS` or `CSE-KMS`) and key
652
- # information.
851
+ # information. This is a client-side setting. If workgroup settings
852
+ # override client-side settings, then the query uses the encryption
853
+ # configuration that is specified for the workgroup, and also uses the
854
+ # location for storing query results specified in the workgroup. See
855
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration and [Workgroup
856
+ # Settings Override Client-Side Settings][1].
857
+ #
858
+ #
859
+ #
860
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/workgroups-settings-override.html
653
861
  # @return [Types::EncryptionConfiguration]
654
862
  #
655
863
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ResultConfiguration AWS API Documentation
@@ -660,6 +868,83 @@ module Aws::Athena
660
868
  include Aws::Structure
661
869
  end
662
870
 
871
+ # The information about the updates in the query results, such as output
872
+ # location and encryption configuration for the query results.
873
+ #
874
+ # @note When making an API call, you may pass ResultConfigurationUpdates
875
+ # data as a hash:
876
+ #
877
+ # {
878
+ # output_location: "String",
879
+ # remove_output_location: false,
880
+ # encryption_configuration: {
881
+ # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
882
+ # kms_key: "String",
883
+ # },
884
+ # remove_encryption_configuration: false,
885
+ # }
886
+ #
887
+ # @!attribute [rw] output_location
888
+ # The location in Amazon S3 where your query results are stored, such
889
+ # as `s3://path/to/query/bucket/`. For more information, see [Queries
890
+ # and Query Result Files.][1] If workgroup settings override
891
+ # client-side settings, then the query uses the location for the query
892
+ # results and the encryption configuration that are specified for the
893
+ # workgroup. The "workgroup settings override" is specified in
894
+ # EnforceWorkGroupConfiguration (true/false) in the
895
+ # WorkGroupConfiguration. See
896
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
897
+ #
898
+ #
899
+ #
900
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/querying.html
901
+ # @return [String]
902
+ #
903
+ # @!attribute [rw] remove_output_location
904
+ # If set to "true", indicates that the previously-specified query
905
+ # results location (also known as a client-side setting) for queries
906
+ # in this workgroup should be ignored and set to null. If set to
907
+ # "false" or not set, and a value is present in the OutputLocation
908
+ # in ResultConfigurationUpdates (the client-side setting), the
909
+ # OutputLocation in the workgroup's ResultConfiguration will be
910
+ # updated with the new value. For more information, see [Workgroup
911
+ # Settings Override Client-Side Settings][1].
912
+ #
913
+ #
914
+ #
915
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/workgroups-settings-override.html
916
+ # @return [Boolean]
917
+ #
918
+ # @!attribute [rw] encryption_configuration
919
+ # The encryption configuration for the query results.
920
+ # @return [Types::EncryptionConfiguration]
921
+ #
922
+ # @!attribute [rw] remove_encryption_configuration
923
+ # If set to "true", indicates that the previously-specified
924
+ # encryption configuration (also known as the client-side setting) for
925
+ # queries in this workgroup should be ignored and set to null. If set
926
+ # to "false" or not set, and a value is present in the
927
+ # EncryptionConfiguration in ResultConfigurationUpdates (the
928
+ # client-side setting), the EncryptionConfiguration in the
929
+ # workgroup's ResultConfiguration will be updated with the new value.
930
+ # For more information, see [Workgroup Settings Override Client-Side
931
+ # Settings][1].
932
+ #
933
+ #
934
+ #
935
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/workgroups-settings-override.html
936
+ # @return [Boolean]
937
+ #
938
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/ResultConfigurationUpdates AWS API Documentation
939
+ #
940
+ class ResultConfigurationUpdates < Struct.new(
941
+ :output_location,
942
+ :remove_output_location,
943
+ :encryption_configuration,
944
+ :remove_encryption_configuration)
945
+ include Aws::Structure
946
+ end
947
+
663
948
  # The metadata and rows that comprise a query result set. The metadata
664
949
  # describes the column structure and data types.
665
950
  #
@@ -716,13 +1001,14 @@ module Aws::Athena
716
1001
  # query_execution_context: {
717
1002
  # database: "DatabaseString",
718
1003
  # },
719
- # result_configuration: { # required
720
- # output_location: "String", # required
1004
+ # result_configuration: {
1005
+ # output_location: "String",
721
1006
  # encryption_configuration: {
722
1007
  # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
723
1008
  # kms_key: "String",
724
1009
  # },
725
1010
  # },
1011
+ # work_group: "WorkGroupName",
726
1012
  # }
727
1013
  #
728
1014
  # @!attribute [rw] query_string
@@ -751,16 +1037,26 @@ module Aws::Athena
751
1037
  #
752
1038
  # @!attribute [rw] result_configuration
753
1039
  # Specifies information about where and how to save the results of the
754
- # query execution.
1040
+ # query execution. If the query runs in a workgroup, then workgroup's
1041
+ # settings may override query settings. This affects the query results
1042
+ # location. The workgroup settings override is specified in
1043
+ # EnforceWorkGroupConfiguration (true/false) in the
1044
+ # WorkGroupConfiguration. See
1045
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
755
1046
  # @return [Types::ResultConfiguration]
756
1047
  #
1048
+ # @!attribute [rw] work_group
1049
+ # The name of the workgroup in which the query is being started.
1050
+ # @return [String]
1051
+ #
757
1052
  # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/StartQueryExecutionInput AWS API Documentation
758
1053
  #
759
1054
  class StartQueryExecutionInput < Struct.new(
760
1055
  :query_string,
761
1056
  :client_request_token,
762
1057
  :query_execution_context,
763
- :result_configuration)
1058
+ :result_configuration,
1059
+ :work_group)
764
1060
  include Aws::Structure
765
1061
  end
766
1062
 
@@ -850,5 +1146,274 @@ module Aws::Athena
850
1146
  include Aws::Structure
851
1147
  end
852
1148
 
1149
+ # @note When making an API call, you may pass UpdateWorkGroupInput
1150
+ # data as a hash:
1151
+ #
1152
+ # {
1153
+ # work_group: "WorkGroupName", # required
1154
+ # description: "WorkGroupDescriptionString",
1155
+ # configuration_updates: {
1156
+ # enforce_work_group_configuration: false,
1157
+ # result_configuration_updates: {
1158
+ # output_location: "String",
1159
+ # remove_output_location: false,
1160
+ # encryption_configuration: {
1161
+ # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
1162
+ # kms_key: "String",
1163
+ # },
1164
+ # remove_encryption_configuration: false,
1165
+ # },
1166
+ # publish_cloud_watch_metrics_enabled: false,
1167
+ # bytes_scanned_cutoff_per_query: 1,
1168
+ # remove_bytes_scanned_cutoff_per_query: false,
1169
+ # },
1170
+ # state: "ENABLED", # accepts ENABLED, DISABLED
1171
+ # }
1172
+ #
1173
+ # @!attribute [rw] work_group
1174
+ # The specified workgroup that will be updated.
1175
+ # @return [String]
1176
+ #
1177
+ # @!attribute [rw] description
1178
+ # The workgroup description.
1179
+ # @return [String]
1180
+ #
1181
+ # @!attribute [rw] configuration_updates
1182
+ # The workgroup configuration that will be updated for the given
1183
+ # workgroup.
1184
+ # @return [Types::WorkGroupConfigurationUpdates]
1185
+ #
1186
+ # @!attribute [rw] state
1187
+ # The workgroup state that will be updated for the given workgroup.
1188
+ # @return [String]
1189
+ #
1190
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/UpdateWorkGroupInput AWS API Documentation
1191
+ #
1192
+ class UpdateWorkGroupInput < Struct.new(
1193
+ :work_group,
1194
+ :description,
1195
+ :configuration_updates,
1196
+ :state)
1197
+ include Aws::Structure
1198
+ end
1199
+
1200
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/UpdateWorkGroupOutput AWS API Documentation
1201
+ #
1202
+ class UpdateWorkGroupOutput < Aws::EmptyStructure; end
1203
+
1204
+ # A workgroup, which contains a name, description, creation time, state,
1205
+ # and other configuration, listed under WorkGroup$Configuration. Each
1206
+ # workgroup enables you to isolate queries for you or your group of
1207
+ # users from other queries in the same account, to configure the query
1208
+ # results location and the encryption configuration (known as workgroup
1209
+ # settings), to enable sending query metrics to Amazon CloudWatch, and
1210
+ # to establish per-query data usage control limits for all queries in a
1211
+ # workgroup. The workgroup settings override is specified in
1212
+ # EnforceWorkGroupConfiguration (true/false) in the
1213
+ # WorkGroupConfiguration. See
1214
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
1215
+ #
1216
+ # @!attribute [rw] name
1217
+ # The workgroup name.
1218
+ # @return [String]
1219
+ #
1220
+ # @!attribute [rw] state
1221
+ # The state of the workgroup: ENABLED or DISABLED.
1222
+ # @return [String]
1223
+ #
1224
+ # @!attribute [rw] configuration
1225
+ # The configuration of the workgroup, which includes the location in
1226
+ # Amazon S3 where query results are stored, the encryption
1227
+ # configuration, if any, used for query results; whether the Amazon
1228
+ # CloudWatch Metrics are enabled for the workgroup; whether workgroup
1229
+ # settings override client-side settings; and the data usage limit for
1230
+ # the amount of data scanned per query, if it is specified. The
1231
+ # workgroup settings override is specified in
1232
+ # EnforceWorkGroupConfiguration (true/false) in the
1233
+ # WorkGroupConfiguration. See
1234
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
1235
+ # @return [Types::WorkGroupConfiguration]
1236
+ #
1237
+ # @!attribute [rw] description
1238
+ # The workgroup description.
1239
+ # @return [String]
1240
+ #
1241
+ # @!attribute [rw] creation_time
1242
+ # The date and time the workgroup was created.
1243
+ # @return [Time]
1244
+ #
1245
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/WorkGroup AWS API Documentation
1246
+ #
1247
+ class WorkGroup < Struct.new(
1248
+ :name,
1249
+ :state,
1250
+ :configuration,
1251
+ :description,
1252
+ :creation_time)
1253
+ include Aws::Structure
1254
+ end
1255
+
1256
+ # The configuration of the workgroup, which includes the location in
1257
+ # Amazon S3 where query results are stored, the encryption option, if
1258
+ # any, used for query results, whether the Amazon CloudWatch Metrics are
1259
+ # enabled for the workgroup and whether workgroup settings override
1260
+ # query settings, and the data usage limit for the amount of data
1261
+ # scanned per query, if it is specified. The workgroup settings override
1262
+ # is specified in EnforceWorkGroupConfiguration (true/false) in the
1263
+ # WorkGroupConfiguration. See
1264
+ # WorkGroupConfiguration$EnforceWorkGroupConfiguration.
1265
+ #
1266
+ # @note When making an API call, you may pass WorkGroupConfiguration
1267
+ # data as a hash:
1268
+ #
1269
+ # {
1270
+ # result_configuration: {
1271
+ # output_location: "String",
1272
+ # encryption_configuration: {
1273
+ # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
1274
+ # kms_key: "String",
1275
+ # },
1276
+ # },
1277
+ # enforce_work_group_configuration: false,
1278
+ # publish_cloud_watch_metrics_enabled: false,
1279
+ # bytes_scanned_cutoff_per_query: 1,
1280
+ # }
1281
+ #
1282
+ # @!attribute [rw] result_configuration
1283
+ # The configuration for the workgroup, which includes the location in
1284
+ # Amazon S3 where query results are stored and the encryption option,
1285
+ # if any, used for query results.
1286
+ # @return [Types::ResultConfiguration]
1287
+ #
1288
+ # @!attribute [rw] enforce_work_group_configuration
1289
+ # If set to "true", the settings for the workgroup override
1290
+ # client-side settings. If set to "false", client-side settings are
1291
+ # used. For more information, see [Workgroup Settings Override
1292
+ # Client-Side Settings][1].
1293
+ #
1294
+ #
1295
+ #
1296
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/workgroups-settings-override.html
1297
+ # @return [Boolean]
1298
+ #
1299
+ # @!attribute [rw] publish_cloud_watch_metrics_enabled
1300
+ # Indicates that the Amazon CloudWatch metrics are enabled for the
1301
+ # workgroup.
1302
+ # @return [Boolean]
1303
+ #
1304
+ # @!attribute [rw] bytes_scanned_cutoff_per_query
1305
+ # The upper data usage limit (cutoff) for the amount of bytes a single
1306
+ # query in a workgroup is allowed to scan.
1307
+ # @return [Integer]
1308
+ #
1309
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/WorkGroupConfiguration AWS API Documentation
1310
+ #
1311
+ class WorkGroupConfiguration < Struct.new(
1312
+ :result_configuration,
1313
+ :enforce_work_group_configuration,
1314
+ :publish_cloud_watch_metrics_enabled,
1315
+ :bytes_scanned_cutoff_per_query)
1316
+ include Aws::Structure
1317
+ end
1318
+
1319
+ # The configuration information that will be updated for this workgroup,
1320
+ # which includes the location in Amazon S3 where query results are
1321
+ # stored, the encryption option, if any, used for query results, whether
1322
+ # the Amazon CloudWatch Metrics are enabled for the workgroup, whether
1323
+ # the workgroup settings override the client-side settings, and the data
1324
+ # usage limit for the amount of bytes scanned per query, if it is
1325
+ # specified.
1326
+ #
1327
+ # @note When making an API call, you may pass WorkGroupConfigurationUpdates
1328
+ # data as a hash:
1329
+ #
1330
+ # {
1331
+ # enforce_work_group_configuration: false,
1332
+ # result_configuration_updates: {
1333
+ # output_location: "String",
1334
+ # remove_output_location: false,
1335
+ # encryption_configuration: {
1336
+ # encryption_option: "SSE_S3", # required, accepts SSE_S3, SSE_KMS, CSE_KMS
1337
+ # kms_key: "String",
1338
+ # },
1339
+ # remove_encryption_configuration: false,
1340
+ # },
1341
+ # publish_cloud_watch_metrics_enabled: false,
1342
+ # bytes_scanned_cutoff_per_query: 1,
1343
+ # remove_bytes_scanned_cutoff_per_query: false,
1344
+ # }
1345
+ #
1346
+ # @!attribute [rw] enforce_work_group_configuration
1347
+ # If set to "true", the settings for the workgroup override
1348
+ # client-side settings. If set to "false" client-side settings are
1349
+ # used. For more information, see [Workgroup Settings Override
1350
+ # Client-Side Settings][1].
1351
+ #
1352
+ #
1353
+ #
1354
+ # [1]: https://docs.aws.amazon.com/athena/latest/ug/workgroups-settings-override.html
1355
+ # @return [Boolean]
1356
+ #
1357
+ # @!attribute [rw] result_configuration_updates
1358
+ # The result configuration information about the queries in this
1359
+ # workgroup that will be updated. Includes the updated results
1360
+ # location and an updated option for encrypting query results.
1361
+ # @return [Types::ResultConfigurationUpdates]
1362
+ #
1363
+ # @!attribute [rw] publish_cloud_watch_metrics_enabled
1364
+ # Indicates whether this workgroup enables publishing metrics to
1365
+ # Amazon CloudWatch.
1366
+ # @return [Boolean]
1367
+ #
1368
+ # @!attribute [rw] bytes_scanned_cutoff_per_query
1369
+ # The upper limit (cutoff) for the amount of bytes a single query in a
1370
+ # workgroup is allowed to scan.
1371
+ # @return [Integer]
1372
+ #
1373
+ # @!attribute [rw] remove_bytes_scanned_cutoff_per_query
1374
+ # Indicates that the data usage control limit per query is removed.
1375
+ # WorkGroupConfiguration$BytesScannedCutoffPerQuery
1376
+ # @return [Boolean]
1377
+ #
1378
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/WorkGroupConfigurationUpdates AWS API Documentation
1379
+ #
1380
+ class WorkGroupConfigurationUpdates < Struct.new(
1381
+ :enforce_work_group_configuration,
1382
+ :result_configuration_updates,
1383
+ :publish_cloud_watch_metrics_enabled,
1384
+ :bytes_scanned_cutoff_per_query,
1385
+ :remove_bytes_scanned_cutoff_per_query)
1386
+ include Aws::Structure
1387
+ end
1388
+
1389
+ # The summary information for the workgroup, which includes its name,
1390
+ # state, description, and the date and time it was created.
1391
+ #
1392
+ # @!attribute [rw] name
1393
+ # The name of the workgroup.
1394
+ # @return [String]
1395
+ #
1396
+ # @!attribute [rw] state
1397
+ # The state of the workgroup.
1398
+ # @return [String]
1399
+ #
1400
+ # @!attribute [rw] description
1401
+ # The workgroup description.
1402
+ # @return [String]
1403
+ #
1404
+ # @!attribute [rw] creation_time
1405
+ # The workgroup creation date and time.
1406
+ # @return [Time]
1407
+ #
1408
+ # @see http://docs.aws.amazon.com/goto/WebAPI/athena-2017-05-18/WorkGroupSummary AWS API Documentation
1409
+ #
1410
+ class WorkGroupSummary < Struct.new(
1411
+ :name,
1412
+ :state,
1413
+ :description,
1414
+ :creation_time)
1415
+ include Aws::Structure
1416
+ end
1417
+
853
1418
  end
854
1419
  end