Skip to content

Commit 625a6cf

Browse files
author
awstools
committed
feat(client-athena): Throwing validation errors on CreateNotebook with Name containing /,:,\
1 parent d52597c commit 625a6cf

File tree

4 files changed

+26
-25
lines changed

4 files changed

+26
-25
lines changed

clients/client-athena/src/commands/GetQueryRuntimeStatisticsCommand.ts

+6-5
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,12 @@ export interface GetQueryRuntimeStatisticsCommandOutput extends GetQueryRuntimeS
2828

2929
/**
3030
* <p>Returns query execution runtime statistics related to a single execution of a query if
31-
* you have access to the workgroup in which the query ran. Query execution runtime
32-
* statistics are returned only when <a>QueryExecutionStatus$State</a> is in a
33-
* SUCCEEDED or FAILED state. Stage-level input and output row count and data size
34-
* statistics are not shown when a query has row-level filters defined in Lake
35-
* Formation.</p>
31+
* you have access to the workgroup in which the query ran. Statistics from the
32+
* <code>Timeline</code> section of the response object are available as soon as <a>QueryExecutionStatus$State</a> is in a SUCCEEDED or FAILED state. The
33+
* remaining non-timeline statistics in the response (like stage-level input and output row
34+
* count and data size) are updated asynchronously and may not be available immediately
35+
* after a query completes. The non-timeline statistics are also not included when a query
36+
* has row-level filters defined in Lake Formation.</p>
3637
* @example
3738
* Use a bare-bones client and the command you need to make an API call.
3839
* ```javascript

clients/client-athena/src/commands/ImportNotebookCommand.ts

+5-4
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,11 @@ export interface ImportNotebookCommandOutput extends ImportNotebookOutput, __Met
2828

2929
/**
3030
* <p>Imports a single <code>ipynb</code> file to a Spark enabled workgroup. To import the
31-
* notebook, the request must specify a value for either <code>Payload</code> or <code>NoteBookS3LocationUri</code>. If neither is specified or both are specified, an
32-
* <code>InvalidRequestException</code> occurs. The maximum file size that can be imported is 10
33-
* megabytes. If an <code>ipynb</code> file with the same name already exists in the
34-
* workgroup, throws an error.</p>
31+
* notebook, the request must specify a value for either <code>Payload</code> or
32+
* <code>NoteBookS3LocationUri</code>. If neither is specified or both are specified,
33+
* an <code>InvalidRequestException</code> occurs. The maximum file size that can be
34+
* imported is 10 megabytes. If an <code>ipynb</code> file with the same name already
35+
* exists in the workgroup, throws an error.</p>
3536
* @example
3637
* Use a bare-bones client and the command you need to make an API call.
3738
* ```javascript

clients/client-athena/src/models/models_0.ts

+7-8
Original file line numberDiff line numberDiff line change
@@ -453,8 +453,7 @@ export interface ResultConfiguration {
453453
* such as <code>s3://path/to/query/bucket/</code>. To run the query, you must specify the
454454
* query results location using one of the ways: either for individual queries using either
455455
* this setting (client-side), or in the workgroup, using <a>WorkGroupConfiguration</a>. If none of them is set, Athena
456-
* issues an error that no output location is provided. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Working with query
457-
* results, recent queries, and output files</a>. If workgroup settings override
456+
* issues an error that no output location is provided. If workgroup settings override
458457
* client-side settings, then the query uses the settings specified for the workgroup. See
459458
* <a>WorkGroupConfiguration$EnforceWorkGroupConfiguration</a>.</p>
460459
* @public
@@ -1369,8 +1368,7 @@ export interface WorkGroupConfiguration {
13691368
* where query and calculation results are stored and the encryption option, if any, used
13701369
* for query and calculation results. To run the query, you must specify the query results
13711370
* location using one of the ways: either in the workgroup using this setting, or for
1372-
* individual queries (client-side), using <a>ResultConfiguration$OutputLocation</a>. If none of them is set, Athena issues an error that no output location is provided. For more
1373-
* information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Working with query results, recent queries, and output files</a>.</p>
1371+
* individual queries (client-side), using <a>ResultConfiguration$OutputLocation</a>. If none of them is set, Athena issues an error that no output location is provided.</p>
13741372
* @public
13751373
*/
13761374
ResultConfiguration?: ResultConfiguration;
@@ -3207,7 +3205,8 @@ export interface ImportNotebookInput {
32073205
Name: string | undefined;
32083206

32093207
/**
3210-
* <p>The notebook content to be imported. The payload must be in <code>ipynb</code> format.</p>
3208+
* <p>The notebook content to be imported. The payload must be in <code>ipynb</code>
3209+
* format.</p>
32113210
* @public
32123211
*/
32133212
Payload?: string;
@@ -3220,7 +3219,8 @@ export interface ImportNotebookInput {
32203219
Type: NotebookType | undefined;
32213220

32223221
/**
3223-
* <p>A URI that specifies the Amazon S3 location of a notebook file in <code>ipynb</code> format.</p>
3222+
* <p>A URI that specifies the Amazon S3 location of a notebook file in
3223+
* <code>ipynb</code> format.</p>
32243224
* @public
32253225
*/
32263226
NotebookS3LocationUri?: string;
@@ -5026,8 +5026,7 @@ export interface UpdatePreparedStatementOutput {}
50265026
export interface ResultConfigurationUpdates {
50275027
/**
50285028
* <p>The location in Amazon S3 where your query and calculation results are stored,
5029-
* such as <code>s3://path/to/query/bucket/</code>. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Working with query
5030-
* results, recent queries, and output files</a>. If workgroup settings override
5029+
* such as <code>s3://path/to/query/bucket/</code>. If workgroup settings override
50315030
* client-side settings, then the query uses the location for the query results and the
50325031
* encryption configuration that are specified for the workgroup. The "workgroup settings
50335032
* override" is specified in <code>EnforceWorkGroupConfiguration</code> (true/false) in the

codegen/sdk-codegen/aws-models/athena.json

+8-8
Original file line numberDiff line numberDiff line change
@@ -4188,7 +4188,7 @@
41884188
}
41894189
],
41904190
"traits": {
4191-
"smithy.api#documentation": "<p>Returns query execution runtime statistics related to a single execution of a query if\n you have access to the workgroup in which the query ran. Query execution runtime\n statistics are returned only when <a>QueryExecutionStatus$State</a> is in a\n SUCCEEDED or FAILED state. Stage-level input and output row count and data size\n statistics are not shown when a query has row-level filters defined in Lake\n Formation.</p>"
4191+
"smithy.api#documentation": "<p>Returns query execution runtime statistics related to a single execution of a query if\n you have access to the workgroup in which the query ran. Statistics from the\n <code>Timeline</code> section of the response object are available as soon as <a>QueryExecutionStatus$State</a> is in a SUCCEEDED or FAILED state. The\n remaining non-timeline statistics in the response (like stage-level input and output row\n count and data size) are updated asynchronously and may not be available immediately\n after a query completes. The non-timeline statistics are also not included when a query\n has row-level filters defined in Lake Formation.</p>"
41924192
}
41934193
},
41944194
"com.amazonaws.athena#GetQueryRuntimeStatisticsInput": {
@@ -4568,7 +4568,7 @@
45684568
}
45694569
],
45704570
"traits": {
4571-
"smithy.api#documentation": "<p>Imports a single <code>ipynb</code> file to a Spark enabled workgroup. To import the\n notebook, the request must specify a value for either <code>Payload</code> or <code>NoteBookS3LocationUri</code>. If neither is specified or both are specified, an\n <code>InvalidRequestException</code> occurs. The maximum file size that can be imported is 10\n megabytes. If an <code>ipynb</code> file with the same name already exists in the\n workgroup, throws an error.</p>"
4571+
"smithy.api#documentation": "<p>Imports a single <code>ipynb</code> file to a Spark enabled workgroup. To import the\n notebook, the request must specify a value for either <code>Payload</code> or\n <code>NoteBookS3LocationUri</code>. If neither is specified or both are specified,\n an <code>InvalidRequestException</code> occurs. The maximum file size that can be\n imported is 10 megabytes. If an <code>ipynb</code> file with the same name already\n exists in the workgroup, throws an error.</p>"
45724572
}
45734573
},
45744574
"com.amazonaws.athena#ImportNotebookInput": {
@@ -4591,7 +4591,7 @@
45914591
"Payload": {
45924592
"target": "com.amazonaws.athena#Payload",
45934593
"traits": {
4594-
"smithy.api#documentation": "<p>The notebook content to be imported. The payload must be in <code>ipynb</code> format.</p>"
4594+
"smithy.api#documentation": "<p>The notebook content to be imported. The payload must be in <code>ipynb</code>\n format.</p>"
45954595
}
45964596
},
45974597
"Type": {
@@ -4604,7 +4604,7 @@
46044604
"NotebookS3LocationUri": {
46054605
"target": "com.amazonaws.athena#S3Uri",
46064606
"traits": {
4607-
"smithy.api#documentation": "<p>A URI that specifies the Amazon S3 location of a notebook file in <code>ipynb</code> format.</p>"
4607+
"smithy.api#documentation": "<p>A URI that specifies the Amazon S3 location of a notebook file in\n <code>ipynb</code> format.</p>"
46084608
}
46094609
},
46104610
"ClientRequestToken": {
@@ -6212,7 +6212,7 @@
62126212
"min": 1,
62136213
"max": 255
62146214
},
6215-
"smithy.api#pattern": "^[\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF\\t]+$"
6215+
"smithy.api#pattern": "^(?!.*[/:\\\\])[\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF\\t]+$"
62166216
}
62176217
},
62186218
"com.amazonaws.athena#NotebookSessionSummary": {
@@ -6950,7 +6950,7 @@
69506950
"OutputLocation": {
69516951
"target": "com.amazonaws.athena#ResultOutputLocation",
69526952
"traits": {
6953-
"smithy.api#documentation": "<p>The location in Amazon S3 where your query and calculation results are stored,\n such as <code>s3://path/to/query/bucket/</code>. To run the query, you must specify the\n query results location using one of the ways: either for individual queries using either\n this setting (client-side), or in the workgroup, using <a>WorkGroupConfiguration</a>. If none of them is set, Athena\n issues an error that no output location is provided. For more information, see <a href=\"https://docs.aws.amazon.com/athena/latest/ug/querying.html\">Working with query\n results, recent queries, and output files</a>. If workgroup settings override\n client-side settings, then the query uses the settings specified for the workgroup. See\n <a>WorkGroupConfiguration$EnforceWorkGroupConfiguration</a>.</p>"
6953+
"smithy.api#documentation": "<p>The location in Amazon S3 where your query and calculation results are stored,\n such as <code>s3://path/to/query/bucket/</code>. To run the query, you must specify the\n query results location using one of the ways: either for individual queries using either\n this setting (client-side), or in the workgroup, using <a>WorkGroupConfiguration</a>. If none of them is set, Athena\n issues an error that no output location is provided. If workgroup settings override\n client-side settings, then the query uses the settings specified for the workgroup. See\n <a>WorkGroupConfiguration$EnforceWorkGroupConfiguration</a>.</p>"
69546954
}
69556955
},
69566956
"EncryptionConfiguration": {
@@ -6982,7 +6982,7 @@
69826982
"OutputLocation": {
69836983
"target": "com.amazonaws.athena#ResultOutputLocation",
69846984
"traits": {
6985-
"smithy.api#documentation": "<p>The location in Amazon S3 where your query and calculation results are stored,\n such as <code>s3://path/to/query/bucket/</code>. For more information, see <a href=\"https://docs.aws.amazon.com/athena/latest/ug/querying.html\">Working with query\n results, recent queries, and output files</a>. If workgroup settings override\n client-side settings, then the query uses the location for the query results and the\n encryption configuration that are specified for the workgroup. The \"workgroup settings\n override\" is specified in <code>EnforceWorkGroupConfiguration</code> (true/false) in the\n <code>WorkGroupConfiguration</code>. See <a>WorkGroupConfiguration$EnforceWorkGroupConfiguration</a>.</p>"
6985+
"smithy.api#documentation": "<p>The location in Amazon S3 where your query and calculation results are stored,\n such as <code>s3://path/to/query/bucket/</code>. If workgroup settings override\n client-side settings, then the query uses the location for the query results and the\n encryption configuration that are specified for the workgroup. The \"workgroup settings\n override\" is specified in <code>EnforceWorkGroupConfiguration</code> (true/false) in the\n <code>WorkGroupConfiguration</code>. See <a>WorkGroupConfiguration$EnforceWorkGroupConfiguration</a>.</p>"
69866986
}
69876987
},
69886988
"RemoveOutputLocation": {
@@ -8720,7 +8720,7 @@
87208720
"ResultConfiguration": {
87218721
"target": "com.amazonaws.athena#ResultConfiguration",
87228722
"traits": {
8723-
"smithy.api#documentation": "<p>The configuration for the workgroup, which includes the location in Amazon S3\n where query and calculation results are stored and the encryption option, if any, used\n for query and calculation results. To run the query, you must specify the query results\n location using one of the ways: either in the workgroup using this setting, or for\n individual queries (client-side), using <a>ResultConfiguration$OutputLocation</a>. If none of them is set, Athena issues an error that no output location is provided. For more\n information, see <a href=\"https://docs.aws.amazon.com/athena/latest/ug/querying.html\">Working with query results, recent queries, and output files</a>.</p>"
8723+
"smithy.api#documentation": "<p>The configuration for the workgroup, which includes the location in Amazon S3\n where query and calculation results are stored and the encryption option, if any, used\n for query and calculation results. To run the query, you must specify the query results\n location using one of the ways: either in the workgroup using this setting, or for\n individual queries (client-side), using <a>ResultConfiguration$OutputLocation</a>. If none of them is set, Athena issues an error that no output location is provided.</p>"
87248724
}
87258725
},
87268726
"EnforceWorkGroupConfiguration": {

0 commit comments

Comments
 (0)