Skip to content

Commit

Permalink
feat(client-athena): Enforces a minimal level of encryption for the w…
Browse files Browse the repository at this point in the history
…orkgroup for query and calculation results that are written to Amazon S3. When enabled, workgroup users can set encryption only to the minimum level set by the administrator or higher when they submit queries.
  • Loading branch information
awstools committed Mar 27, 2023
1 parent 23a7115 commit 652bc31
Show file tree
Hide file tree
Showing 14 changed files with 171 additions and 133 deletions.
38 changes: 18 additions & 20 deletions clients/client-athena/src/Athena.ts
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,9 @@ export class Athena extends AthenaClient {
* @public
* <p>Gets an authentication token and the URL at which the notebook can be accessed. During
* programmatic access, <code>CreatePresignedNotebookUrl</code> must be called every 10
* minutes to refresh the authentication token.</p>
* minutes to refresh the authentication token. For information about granting programmatic
* access, see <a href="https://docs.aws.amazon.com/athena/latest/ug/setting-up.html#setting-up-grant-programmatic-access">Grant
* programmatic access</a>.</p>
*/
public createPresignedNotebookUrl(
args: CreatePresignedNotebookUrlCommandInput,
Expand Down Expand Up @@ -601,10 +603,8 @@ export class Athena extends AthenaClient {

/**
* @public
* <p>Creates a workgroup with the specified name. Only one of <code>Configurations</code>
* or <code>Configuration</code> can be specified; <code>Configurations</code> for a
* workgroup with multi engine support (for example, an Apache Spark enabled workgroup) or
* <code>Configuration</code> for an Athena SQL workgroup.</p>
* <p>Creates a workgroup with the specified name. A workgroup can be an Apache Spark
* enabled workgroup or an Athena SQL workgroup.</p>
*/
public createWorkGroup(
args: CreateWorkGroupCommandInput,
Expand Down Expand Up @@ -874,8 +874,7 @@ export class Athena extends AthenaClient {

/**
* @public
* <p>Retrieves a pre-signed URL to a copy of the code that was executed for the
* calculation.</p>
* <p>Retrieves the unencrypted code that was executed for the calculation.</p>
*/
public getCalculationExecutionCode(
args: GetCalculationExecutionCodeCommandInput,
Expand Down Expand Up @@ -1139,8 +1138,9 @@ export class Athena extends AthenaClient {
* @public
* <p>Streams the results of a single query execution specified by
* <code>QueryExecutionId</code> from the Athena query results location in
* Amazon S3. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Query Results</a> in the <i>Amazon Athena User Guide</i>. This request does not execute the query
* but returns results. Use <a>StartQueryExecution</a> to run a query.</p>
* Amazon S3. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Working with query results, recent queries, and
* output files</a> in the <i>Amazon Athena User Guide</i>.
* This request does not execute the query but returns results. Use <a>StartQueryExecution</a> to run a query.</p>
* <p>To stream query results successfully, the IAM principal with permission to call
* <code>GetQueryResults</code> also must have permissions to the Amazon S3
* <code>GetObject</code> action for the Athena query results location.</p>
Expand Down Expand Up @@ -1382,7 +1382,7 @@ export class Athena extends AthenaClient {
/**
* @public
* <p>Returns the supported DPU sizes for the supported application runtimes (for example,
* <code>Jupyter 1.0</code>). </p>
* <code>Athena notebook version 1</code>). </p>
*/
public listApplicationDPUSizes(
args: ListApplicationDPUSizesCommandInput,
Expand Down Expand Up @@ -1484,7 +1484,8 @@ export class Athena extends AthenaClient {
* @public
* <p>Lists the data catalogs in the current Amazon Web Services account.</p>
* <note>
* <p>In the Athena console, data catalogs are listed as "data sources" on the <b>Data sources</b> page under the <b>Data source name</b> column.</p>
* <p>In the Athena console, data catalogs are listed as "data sources" on
* the <b>Data sources</b> page under the <b>Data source name</b> column.</p>
* </note>
*/
public listDataCatalogs(
Expand Down Expand Up @@ -1552,9 +1553,9 @@ export class Athena extends AthenaClient {

/**
* @public
* <p>Lists, in descending order, the executors that have been submitted to a session. Newer
* executors are listed first; older executors are listed later. The result can be
* optionally filtered by state.</p>
* <p>Lists, in descending order, the executors that joined a session. Newer executors are
* listed first; older executors are listed later. The result can be optionally filtered by
* state.</p>
*/
public listExecutors(
args: ListExecutorsCommandInput,
Expand Down Expand Up @@ -1900,7 +1901,7 @@ export class Athena extends AthenaClient {
/**
* @public
* <p>Submits calculations for execution within a session. You can supply the code to run as
* an inline code block within the request or as an Amazon S3 URL.</p>
* an inline code block within the request.</p>
*/
public startCalculationExecution(
args: StartCalculationExecutionCommandInput,
Expand Down Expand Up @@ -2087,7 +2088,7 @@ export class Athena extends AthenaClient {
* example, you can use tags to categorize Athena workgroups or data catalogs
* by purpose, owner, or environment. Use a consistent set of tag keys to make it easier to
* search and filter workgroups or data catalogs in your account. For best practices, see
* <a href="https://aws.amazon.com/answers/account-management/aws-tagging-strategies/">Tagging Best Practices</a>. Tag keys can be from 1 to 128 UTF-8 Unicode
* <a href="https://docs.aws.amazon.com/whitepapers/latest/tagging-best-practices/tagging-best-practices.html">Tagging Best Practices</a>. Tag keys can be from 1 to 128 UTF-8 Unicode
* characters, and tag values can be from 0 to 256 UTF-8 Unicode characters. Tags can use
* letters and numbers representable in UTF-8, and the following characters: + - = . _ : /
* @. Tag keys and values are case-sensitive. Tag keys must be unique per resource. If you
Expand Down Expand Up @@ -2355,10 +2356,7 @@ export class Athena extends AthenaClient {
/**
* @public
* <p>Updates the workgroup with the specified name. The workgroup's name cannot be changed.
* Only one of <code>ConfigurationsUpdates</code> or <code>ConfigurationUpdates</code> can
* be specified; <code>ConfigurationsUpdates</code> for a workgroup with multi engine
* support (for example, an Apache Spark enabled workgroup) or
* <code>ConfigurationUpdates</code> for an Athena SQL workgroup.</p>
* Only <code>ConfigurationUpdates</code> can be specified.</p>
*/
public updateWorkGroup(
args: UpdateWorkGroupCommandInput,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ export interface CreatePresignedNotebookUrlCommandOutput extends CreatePresigned
* @public
* <p>Gets an authentication token and the URL at which the notebook can be accessed. During
* programmatic access, <code>CreatePresignedNotebookUrl</code> must be called every 10
* minutes to refresh the authentication token.</p>
* minutes to refresh the authentication token. For information about granting programmatic
* access, see <a href="https://docs.aws.amazon.com/athena/latest/ug/setting-up.html#setting-up-grant-programmatic-access">Grant
* programmatic access</a>.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
7 changes: 3 additions & 4 deletions clients/client-athena/src/commands/CreateWorkGroupCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,8 @@ export interface CreateWorkGroupCommandOutput extends CreateWorkGroupOutput, __M

/**
* @public
* <p>Creates a workgroup with the specified name. Only one of <code>Configurations</code>
* or <code>Configuration</code> can be specified; <code>Configurations</code> for a
* workgroup with multi engine support (for example, an Apache Spark enabled workgroup) or
* <code>Configuration</code> for an Athena SQL workgroup.</p>
* <p>Creates a workgroup with the specified name. A workgroup can be an Apache Spark
* enabled workgroup or an Athena SQL workgroup.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down Expand Up @@ -72,6 +70,7 @@ export interface CreateWorkGroupCommandOutput extends CreateWorkGroupOutput, __M
* CustomerContentEncryptionConfiguration: {
* KmsKey: "STRING_VALUE", // required
* },
* EnableMinimumEncryptionConfiguration: true || false,
* },
* Description: "STRING_VALUE",
* Tags: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@ export interface GetCalculationExecutionCodeCommandOutput

/**
* @public
* <p>Retrieves a pre-signed URL to a copy of the code that was executed for the
* calculation.</p>
* <p>Retrieves the unencrypted code that was executed for the calculation.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
5 changes: 3 additions & 2 deletions clients/client-athena/src/commands/GetQueryResultsCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,9 @@ export interface GetQueryResultsCommandOutput extends GetQueryResultsOutput, __M
* @public
* <p>Streams the results of a single query execution specified by
* <code>QueryExecutionId</code> from the Athena query results location in
* Amazon S3. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Query Results</a> in the <i>Amazon Athena User Guide</i>. This request does not execute the query
* but returns results. Use <a>StartQueryExecution</a> to run a query.</p>
* Amazon S3. For more information, see <a href="https://docs.aws.amazon.com/athena/latest/ug/querying.html">Working with query results, recent queries, and
* output files</a> in the <i>Amazon Athena User Guide</i>.
* This request does not execute the query but returns results. Use <a>StartQueryExecution</a> to run a query.</p>
* <p>To stream query results successfully, the IAM principal with permission to call
* <code>GetQueryResults</code> also must have permissions to the Amazon S3
* <code>GetObject</code> action for the Athena query results location.</p>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export interface ListApplicationDPUSizesCommandOutput extends ListApplicationDPU
/**
* @public
* <p>Returns the supported DPU sizes for the supported application runtimes (for example,
* <code>Jupyter 1.0</code>). </p>
* <code>Athena notebook version 1</code>). </p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ export interface ListDataCatalogsCommandOutput extends ListDataCatalogsOutput, _
* @public
* <p>Lists the data catalogs in the current Amazon Web Services account.</p>
* <note>
* <p>In the Athena console, data catalogs are listed as "data sources" on the <b>Data sources</b> page under the <b>Data source name</b> column.</p>
* <p>In the Athena console, data catalogs are listed as "data sources" on
* the <b>Data sources</b> page under the <b>Data source name</b> column.</p>
* </note>
* @example
* Use a bare-bones client and the command you need to make an API call.
Expand Down
6 changes: 3 additions & 3 deletions clients/client-athena/src/commands/ListExecutorsCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ export interface ListExecutorsCommandOutput extends ListExecutorsResponse, __Met

/**
* @public
* <p>Lists, in descending order, the executors that have been submitted to a session. Newer
* executors are listed first; older executors are listed later. The result can be
* optionally filtered by state.</p>
* <p>Lists, in descending order, the executors that joined a session. Newer executors are
* listed first; older executors are listed later. The result can be optionally filtered by
* state.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export interface StartCalculationExecutionCommandOutput extends StartCalculation
/**
* @public
* <p>Submits calculations for execution within a session. You can supply the code to run as
* an inline code block within the request or as an Amazon S3 URL.</p>
* an inline code block within the request.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down
2 changes: 1 addition & 1 deletion clients/client-athena/src/commands/TagResourceCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export interface TagResourceCommandOutput extends TagResourceOutput, __MetadataB
* example, you can use tags to categorize Athena workgroups or data catalogs
* by purpose, owner, or environment. Use a consistent set of tag keys to make it easier to
* search and filter workgroups or data catalogs in your account. For best practices, see
* <a href="https://aws.amazon.com/answers/account-management/aws-tagging-strategies/">Tagging Best Practices</a>. Tag keys can be from 1 to 128 UTF-8 Unicode
* <a href="https://docs.aws.amazon.com/whitepapers/latest/tagging-best-practices/tagging-best-practices.html">Tagging Best Practices</a>. Tag keys can be from 1 to 128 UTF-8 Unicode
* characters, and tag values can be from 0 to 256 UTF-8 Unicode characters. Tags can use
* letters and numbers representable in UTF-8, and the following characters: + - = . _ : /
* @. Tag keys and values are case-sensitive. Tag keys must be unique per resource. If you
Expand Down
6 changes: 2 additions & 4 deletions clients/client-athena/src/commands/UpdateWorkGroupCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,7 @@ export interface UpdateWorkGroupCommandOutput extends UpdateWorkGroupOutput, __M
/**
* @public
* <p>Updates the workgroup with the specified name. The workgroup's name cannot be changed.
* Only one of <code>ConfigurationsUpdates</code> or <code>ConfigurationUpdates</code> can
* be specified; <code>ConfigurationsUpdates</code> for a workgroup with multi engine
* support (for example, an Apache Spark enabled workgroup) or
* <code>ConfigurationUpdates</code> for an Athena SQL workgroup.</p>
* Only <code>ConfigurationUpdates</code> can be specified.</p>
* @example
* Use a bare-bones client and the command you need to make an API call.
* ```javascript
Expand Down Expand Up @@ -80,6 +77,7 @@ export interface UpdateWorkGroupCommandOutput extends UpdateWorkGroupOutput, __M
* CustomerContentEncryptionConfiguration: {
* KmsKey: "STRING_VALUE", // required
* },
* EnableMinimumEncryptionConfiguration: true || false,
* },
* State: "ENABLED" || "DISABLED",
* };
Expand Down
Loading

0 comments on commit 652bc31

Please sign in to comment.