Struct aws_sdk_athena::Client
source · [−]pub struct Client { /* private fields */ }
Expand description
Client for Amazon Athena
Client for invoking operations on Amazon Athena. Each operation on Amazon Athena is a method on this
this struct. .send()
MUST be invoked on the generated operations to dispatch the request to the service.
Examples
Constructing a client and invoking an operation
// create a shared configuration. This can be used & shared between multiple service clients.
let shared_config = aws_config::load_from_env().await;
let client = aws_sdk_athena::Client::new(&shared_config);
// invoke an operation
/* let rsp = client
.<operation_name>().
.<param>("some value")
.send().await; */
Constructing a client with custom configuration
use aws_config::RetryConfig;
let shared_config = aws_config::load_from_env().await;
let config = aws_sdk_athena::config::Builder::from(&shared_config)
.retry_config(RetryConfig::disabled())
.build();
let client = aws_sdk_athena::Client::from_conf(config);
Implementations
sourceimpl Client
impl Client
sourcepub fn with_config(
client: Client<DynConnector, DynMiddleware<DynConnector>>,
conf: Config
) -> Self
pub fn with_config(
client: Client<DynConnector, DynMiddleware<DynConnector>>,
conf: Config
) -> Self
Creates a client with the given service configuration.
sourceimpl Client
impl Client
sourcepub fn batch_get_named_query(&self) -> BatchGetNamedQuery
pub fn batch_get_named_query(&self) -> BatchGetNamedQuery
Constructs a fluent builder for the BatchGetNamedQuery
operation.
- The fluent builder is configurable:
named_query_ids(Vec<String>)
/set_named_query_ids(Option<Vec<String>>)
:An array of query IDs.
- On success, responds with
BatchGetNamedQueryOutput
with field(s):named_queries(Option<Vec<NamedQuery>>)
:Information about the named query IDs submitted.
unprocessed_named_query_ids(Option<Vec<UnprocessedNamedQueryId>>)
:Information about provided query IDs.
- On failure, responds with
SdkError<BatchGetNamedQueryError>
sourcepub fn batch_get_prepared_statement(&self) -> BatchGetPreparedStatement
pub fn batch_get_prepared_statement(&self) -> BatchGetPreparedStatement
Constructs a fluent builder for the BatchGetPreparedStatement
operation.
- The fluent builder is configurable:
prepared_statement_names(Vec<String>)
/set_prepared_statement_names(Option<Vec<String>>)
:A list of prepared statement names to return.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup to which the prepared statements belong.
- On success, responds with
BatchGetPreparedStatementOutput
with field(s):prepared_statements(Option<Vec<PreparedStatement>>)
:The list of prepared statements returned.
unprocessed_prepared_statement_names(Option<Vec<UnprocessedPreparedStatementName>>)
:A list of one or more prepared statements that were requested but could not be returned.
- On failure, responds with
SdkError<BatchGetPreparedStatementError>
sourcepub fn batch_get_query_execution(&self) -> BatchGetQueryExecution
pub fn batch_get_query_execution(&self) -> BatchGetQueryExecution
Constructs a fluent builder for the BatchGetQueryExecution
operation.
- The fluent builder is configurable:
query_execution_ids(Vec<String>)
/set_query_execution_ids(Option<Vec<String>>)
:An array of query execution IDs.
- On success, responds with
BatchGetQueryExecutionOutput
with field(s):query_executions(Option<Vec<QueryExecution>>)
:Information about a query execution.
unprocessed_query_execution_ids(Option<Vec<UnprocessedQueryExecutionId>>)
:Information about the query executions that failed to run.
- On failure, responds with
SdkError<BatchGetQueryExecutionError>
sourcepub fn create_data_catalog(&self) -> CreateDataCatalog
pub fn create_data_catalog(&self) -> CreateDataCatalog
Constructs a fluent builder for the CreateDataCatalog
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The name of the data catalog to create. The catalog name must be unique for the Amazon Web Services account and can use a maximum of 127 alphanumeric, underscore, at sign, or hyphen characters. The remainder of the length constraint of 256 is reserved for use by Athena.
r#type(DataCatalogType)
/set_type(Option<DataCatalogType>)
:The type of data catalog to create:
LAMBDA
for a federated catalog,HIVE
for an external hive metastore, orGLUE
for an Glue Data Catalog.description(impl Into<String>)
/set_description(Option<String>)
:A description of the data catalog to be created.
parameters(HashMap<String, String>)
/set_parameters(Option<HashMap<String, String>>)
:Specifies the Lambda function or functions to use for creating the data catalog. This is a mapping whose values depend on the catalog type.
-
For the
HIVE
data catalog type, use the following syntax. Themetadata-function
parameter is required.The sdk-version
parameter is optional and defaults to the currently supported version.metadata-function=lambda_arn, sdk-version=version_number
-
For the
LAMBDA
data catalog type, use one of the following sets of required parameters, but not both.-
If you have one Lambda function that processes metadata and another for reading the actual data, use the following syntax. Both parameters are required.
metadata-function=lambda_arn, record-function=lambda_arn
-
If you have a composite Lambda function that processes both metadata and data, use the following syntax to specify your Lambda function.
function=lambda_arn
-
-
The
GLUE
type takes a catalog ID parameter and is required. Thecatalog_id
is the account ID of the Amazon Web Services account to which the Glue Data Catalog belongs.catalog-id=catalog_id
-
The
GLUE
data catalog type also applies to the defaultAwsDataCatalog
that already exists in your account, of which you can have only one and cannot modify. -
Queries that specify a Glue Data Catalog other than the default
AwsDataCatalog
must be run on Athena engine version 2. -
In Regions where Athena engine version 2 is not available, creating new Glue data catalogs results in an
INVALID_INPUT
error.
-
-
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:A list of comma separated tags to add to the data catalog that is created.
- On success, responds with
CreateDataCatalogOutput
- On failure, responds with
SdkError<CreateDataCatalogError>
sourcepub fn create_named_query(&self) -> CreateNamedQuery
pub fn create_named_query(&self) -> CreateNamedQuery
Constructs a fluent builder for the CreateNamedQuery
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The query name.
description(impl Into<String>)
/set_description(Option<String>)
:The query description.
database(impl Into<String>)
/set_database(Option<String>)
:The database to which the query belongs.
query_string(impl Into<String>)
/set_query_string(Option<String>)
:The contents of the query with all query statements.
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:A unique case-sensitive string used to ensure the request to create the query is idempotent (executes only once). If another
CreateNamedQuery
request is received, the same response is returned and another query is not created. If a parameter has changed, for example, theQueryString
, an error is returned.This token is listed as not required because Amazon Web Services SDKs (for example the Amazon Web Services SDK for Java) auto-generate the token for users. If you are not using the Amazon Web Services SDK or the Amazon Web Services CLI, you must provide this token or the action will fail.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup in which the named query is being created.
- On success, responds with
CreateNamedQueryOutput
with field(s):named_query_id(Option<String>)
:The unique ID of the query.
- On failure, responds with
SdkError<CreateNamedQueryError>
sourcepub fn create_prepared_statement(&self) -> CreatePreparedStatement
pub fn create_prepared_statement(&self) -> CreatePreparedStatement
Constructs a fluent builder for the CreatePreparedStatement
operation.
- The fluent builder is configurable:
statement_name(impl Into<String>)
/set_statement_name(Option<String>)
:The name of the prepared statement.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup to which the prepared statement belongs.
query_statement(impl Into<String>)
/set_query_statement(Option<String>)
:The query string for the prepared statement.
description(impl Into<String>)
/set_description(Option<String>)
:The description of the prepared statement.
- On success, responds with
CreatePreparedStatementOutput
- On failure, responds with
SdkError<CreatePreparedStatementError>
sourcepub fn create_work_group(&self) -> CreateWorkGroup
pub fn create_work_group(&self) -> CreateWorkGroup
Constructs a fluent builder for the CreateWorkGroup
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The workgroup name.
configuration(WorkGroupConfiguration)
/set_configuration(Option<WorkGroupConfiguration>)
:The configuration for the workgroup, which includes the location in Amazon S3 where query results are stored, the encryption configuration, if any, used for encrypting query results, whether the Amazon CloudWatch Metrics are enabled for the workgroup, the limit for the amount of bytes scanned (cutoff) per query, if it is specified, and whether workgroup’s settings (specified with
EnforceWorkGroupConfiguration
) in theWorkGroupConfiguration
override client-side settings. SeeWorkGroupConfiguration$EnforceWorkGroupConfiguration
.description(impl Into<String>)
/set_description(Option<String>)
:The workgroup description.
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:A list of comma separated tags to add to the workgroup that is created.
- On success, responds with
CreateWorkGroupOutput
- On failure, responds with
SdkError<CreateWorkGroupError>
sourcepub fn delete_data_catalog(&self) -> DeleteDataCatalog
pub fn delete_data_catalog(&self) -> DeleteDataCatalog
Constructs a fluent builder for the DeleteDataCatalog
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The name of the data catalog to delete.
- On success, responds with
DeleteDataCatalogOutput
- On failure, responds with
SdkError<DeleteDataCatalogError>
sourcepub fn delete_named_query(&self) -> DeleteNamedQuery
pub fn delete_named_query(&self) -> DeleteNamedQuery
Constructs a fluent builder for the DeleteNamedQuery
operation.
- The fluent builder is configurable:
named_query_id(impl Into<String>)
/set_named_query_id(Option<String>)
:The unique ID of the query to delete.
- On success, responds with
DeleteNamedQueryOutput
- On failure, responds with
SdkError<DeleteNamedQueryError>
sourcepub fn delete_prepared_statement(&self) -> DeletePreparedStatement
pub fn delete_prepared_statement(&self) -> DeletePreparedStatement
Constructs a fluent builder for the DeletePreparedStatement
operation.
- The fluent builder is configurable:
statement_name(impl Into<String>)
/set_statement_name(Option<String>)
:The name of the prepared statement to delete.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The workgroup to which the statement to be deleted belongs.
- On success, responds with
DeletePreparedStatementOutput
- On failure, responds with
SdkError<DeletePreparedStatementError>
sourcepub fn delete_work_group(&self) -> DeleteWorkGroup
pub fn delete_work_group(&self) -> DeleteWorkGroup
Constructs a fluent builder for the DeleteWorkGroup
operation.
- The fluent builder is configurable:
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The unique name of the workgroup to delete.
recursive_delete_option(bool)
/set_recursive_delete_option(Option<bool>)
:The option to delete the workgroup and its contents even if the workgroup contains any named queries or query executions.
- On success, responds with
DeleteWorkGroupOutput
- On failure, responds with
SdkError<DeleteWorkGroupError>
sourcepub fn get_database(&self) -> GetDatabase
pub fn get_database(&self) -> GetDatabase
Constructs a fluent builder for the GetDatabase
operation.
- The fluent builder is configurable:
catalog_name(impl Into<String>)
/set_catalog_name(Option<String>)
:The name of the data catalog that contains the database to return.
database_name(impl Into<String>)
/set_database_name(Option<String>)
:The name of the database to return.
- On success, responds with
GetDatabaseOutput
with field(s):database(Option<Database>)
:The database returned.
- On failure, responds with
SdkError<GetDatabaseError>
sourcepub fn get_data_catalog(&self) -> GetDataCatalog
pub fn get_data_catalog(&self) -> GetDataCatalog
Constructs a fluent builder for the GetDataCatalog
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The name of the data catalog to return.
- On success, responds with
GetDataCatalogOutput
with field(s):data_catalog(Option<DataCatalog>)
:The data catalog returned.
- On failure, responds with
SdkError<GetDataCatalogError>
sourcepub fn get_named_query(&self) -> GetNamedQuery
pub fn get_named_query(&self) -> GetNamedQuery
Constructs a fluent builder for the GetNamedQuery
operation.
- The fluent builder is configurable:
named_query_id(impl Into<String>)
/set_named_query_id(Option<String>)
:The unique ID of the query. Use
ListNamedQueries
to get query IDs.
- On success, responds with
GetNamedQueryOutput
with field(s):named_query(Option<NamedQuery>)
:Information about the query.
- On failure, responds with
SdkError<GetNamedQueryError>
sourcepub fn get_prepared_statement(&self) -> GetPreparedStatement
pub fn get_prepared_statement(&self) -> GetPreparedStatement
Constructs a fluent builder for the GetPreparedStatement
operation.
- The fluent builder is configurable:
statement_name(impl Into<String>)
/set_statement_name(Option<String>)
:The name of the prepared statement to retrieve.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The workgroup to which the statement to be retrieved belongs.
- On success, responds with
GetPreparedStatementOutput
with field(s):prepared_statement(Option<PreparedStatement>)
:The name of the prepared statement that was retrieved.
- On failure, responds with
SdkError<GetPreparedStatementError>
sourcepub fn get_query_execution(&self) -> GetQueryExecution
pub fn get_query_execution(&self) -> GetQueryExecution
Constructs a fluent builder for the GetQueryExecution
operation.
- The fluent builder is configurable:
query_execution_id(impl Into<String>)
/set_query_execution_id(Option<String>)
:The unique ID of the query execution.
- On success, responds with
GetQueryExecutionOutput
with field(s):query_execution(Option<QueryExecution>)
:Information about the query execution.
- On failure, responds with
SdkError<GetQueryExecutionError>
sourcepub fn get_query_results(&self) -> GetQueryResults
pub fn get_query_results(&self) -> GetQueryResults
Constructs a fluent builder for the GetQueryResults
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
query_execution_id(impl Into<String>)
/set_query_execution_id(Option<String>)
:The unique ID of the query execution.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of results (rows) to return in this request.
- On success, responds with
GetQueryResultsOutput
with field(s):update_count(Option<i64>)
:The number of rows inserted with a
CREATE TABLE AS SELECT
statement.result_set(Option<ResultSet>)
:The results of the query execution.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.
- On failure, responds with
SdkError<GetQueryResultsError>
sourcepub fn get_table_metadata(&self) -> GetTableMetadata
pub fn get_table_metadata(&self) -> GetTableMetadata
Constructs a fluent builder for the GetTableMetadata
operation.
- The fluent builder is configurable:
catalog_name(impl Into<String>)
/set_catalog_name(Option<String>)
:The name of the data catalog that contains the database and table metadata to return.
database_name(impl Into<String>)
/set_database_name(Option<String>)
:The name of the database that contains the table metadata to return.
table_name(impl Into<String>)
/set_table_name(Option<String>)
:The name of the table for which metadata is returned.
- On success, responds with
GetTableMetadataOutput
with field(s):table_metadata(Option<TableMetadata>)
:An object that contains table metadata.
- On failure, responds with
SdkError<GetTableMetadataError>
sourcepub fn get_work_group(&self) -> GetWorkGroup
pub fn get_work_group(&self) -> GetWorkGroup
Constructs a fluent builder for the GetWorkGroup
operation.
- The fluent builder is configurable:
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup.
- On success, responds with
GetWorkGroupOutput
with field(s):work_group(Option<WorkGroup>)
:Information about the workgroup.
- On failure, responds with
SdkError<GetWorkGroupError>
sourcepub fn list_databases(&self) -> ListDatabases
pub fn list_databases(&self) -> ListDatabases
Constructs a fluent builder for the ListDatabases
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
catalog_name(impl Into<String>)
/set_catalog_name(Option<String>)
:The name of the data catalog that contains the databases to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:Specifies the maximum number of results to return.
- On success, responds with
ListDatabasesOutput
with field(s):database_list(Option<Vec<Database>>)
:A list of databases from a data catalog.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the NextToken from the response object of the previous page call.
- On failure, responds with
SdkError<ListDatabasesError>
sourcepub fn list_data_catalogs(&self) -> ListDataCatalogs
pub fn list_data_catalogs(&self) -> ListDataCatalogs
Constructs a fluent builder for the ListDataCatalogs
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the NextToken from the response object of the previous page call.
max_results(i32)
/set_max_results(Option<i32>)
:Specifies the maximum number of data catalogs to return.
- On success, responds with
ListDataCatalogsOutput
with field(s):data_catalogs_summary(Option<Vec<DataCatalogSummary>>)
:A summary list of data catalogs.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the NextToken from the response object of the previous page call.
- On failure, responds with
SdkError<ListDataCatalogsError>
sourcepub fn list_engine_versions(&self) -> ListEngineVersions
pub fn list_engine_versions(&self) -> ListEngineVersions
Constructs a fluent builder for the ListEngineVersions
operation.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of engine versions to return in this request.
- On success, responds with
ListEngineVersionsOutput
with field(s):engine_versions(Option<Vec<EngineVersion>>)
:A list of engine versions that are available to choose from.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.
- On failure, responds with
SdkError<ListEngineVersionsError>
sourcepub fn list_named_queries(&self) -> ListNamedQueries
pub fn list_named_queries(&self) -> ListNamedQueries
Constructs a fluent builder for the ListNamedQueries
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of queries to return in this request.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup from which the named queries are being returned. If a workgroup is not specified, the saved queries for the primary workgroup are returned.
- On success, responds with
ListNamedQueriesOutput
with field(s):named_query_ids(Option<Vec<String>>)
:The list of unique query IDs.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.
- On failure, responds with
SdkError<ListNamedQueriesError>
sourcepub fn list_prepared_statements(&self) -> ListPreparedStatements
pub fn list_prepared_statements(&self) -> ListPreparedStatements
Constructs a fluent builder for the ListPreparedStatements
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The workgroup to list the prepared statements for.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of results to return in this request.
- On success, responds with
ListPreparedStatementsOutput
with field(s):prepared_statements(Option<Vec<PreparedStatementSummary>>)
:The list of prepared statements for the workgroup.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.
- On failure, responds with
SdkError<ListPreparedStatementsError>
sourcepub fn list_query_executions(&self) -> ListQueryExecutions
pub fn list_query_executions(&self) -> ListQueryExecutions
Constructs a fluent builder for the ListQueryExecutions
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of query executions to return in this request.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup from which queries are being returned. If a workgroup is not specified, a list of available query execution IDs for the queries in the primary workgroup is returned.
- On success, responds with
ListQueryExecutionsOutput
with field(s):query_execution_ids(Option<Vec<String>>)
:The unique IDs of each query execution as an array of strings.
next_token(Option<String>)
:A token to be used by the next request if this request is truncated.
- On failure, responds with
SdkError<ListQueryExecutionsError>
sourcepub fn list_table_metadata(&self) -> ListTableMetadata
pub fn list_table_metadata(&self) -> ListTableMetadata
Constructs a fluent builder for the ListTableMetadata
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
catalog_name(impl Into<String>)
/set_catalog_name(Option<String>)
:The name of the data catalog for which table metadata should be returned.
database_name(impl Into<String>)
/set_database_name(Option<String>)
:The name of the database for which table metadata should be returned.
expression(impl Into<String>)
/set_expression(Option<String>)
:A regex filter that pattern-matches table names. If no expression is supplied, metadata for all tables are listed.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the NextToken from the response object of the previous page call.
max_results(i32)
/set_max_results(Option<i32>)
:Specifies the maximum number of results to return.
- On success, responds with
ListTableMetadataOutput
with field(s):table_metadata_list(Option<Vec<TableMetadata>>)
:A list of table metadata.
next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the NextToken from the response object of the previous page call.
- On failure, responds with
SdkError<ListTableMetadataError>
Constructs a fluent builder for the ListTagsForResource
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:Lists the tags for the resource with the specified ARN.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:The token for the next set of results, or null if there are no additional results for this request, where the request lists the tags for the resource with the specified ARN.
max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of results to be returned per request that lists the tags for the resource.
- On success, responds with
ListTagsForResourceOutput
with field(s):tags(Option<Vec<Tag>>)
:The list of tags associated with the specified resource.
next_token(Option<String>)
:A token to be used by the next request if this request is truncated.
- On failure, responds with
SdkError<ListTagsForResourceError>
sourcepub fn list_work_groups(&self) -> ListWorkGroups
pub fn list_work_groups(&self) -> ListWorkGroups
Constructs a fluent builder for the ListWorkGroups
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
next_token(impl Into<String>)
/set_next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of workgroups to return in this request.
- On success, responds with
ListWorkGroupsOutput
with field(s):work_groups(Option<Vec<WorkGroupSummary>>)
:A list of
WorkGroupSummary
objects that include the names, descriptions, creation times, and states for each workgroup.next_token(Option<String>)
:A token generated by the Athena service that specifies where to continue pagination if a previous request was truncated. To obtain the next set of pages, pass in the
NextToken
from the response object of the previous page call.
- On failure, responds with
SdkError<ListWorkGroupsError>
sourcepub fn start_query_execution(&self) -> StartQueryExecution
pub fn start_query_execution(&self) -> StartQueryExecution
Constructs a fluent builder for the StartQueryExecution
operation.
- The fluent builder is configurable:
query_string(impl Into<String>)
/set_query_string(Option<String>)
:The SQL query statements to be executed.
client_request_token(impl Into<String>)
/set_client_request_token(Option<String>)
:A unique case-sensitive string used to ensure the request to create the query is idempotent (executes only once). If another
StartQueryExecution
request is received, the same response is returned and another query is not created. If a parameter has changed, for example, theQueryString
, an error is returned.This token is listed as not required because Amazon Web Services SDKs (for example the Amazon Web Services SDK for Java) auto-generate the token for users. If you are not using the Amazon Web Services SDK or the Amazon Web Services CLI, you must provide this token or the action will fail.
query_execution_context(QueryExecutionContext)
/set_query_execution_context(Option<QueryExecutionContext>)
:The database within which the query executes.
result_configuration(ResultConfiguration)
/set_result_configuration(Option<ResultConfiguration>)
:Specifies information about where and how to save the results of the query execution. If the query runs in a workgroup, then workgroup’s settings may override query settings. This affects the query results location. The workgroup settings override is specified in EnforceWorkGroupConfiguration (true/false) in the WorkGroupConfiguration. See
WorkGroupConfiguration$EnforceWorkGroupConfiguration
.work_group(impl Into<String>)
/set_work_group(Option<String>)
:The name of the workgroup in which the query is being started.
execution_parameters(Vec<String>)
/set_execution_parameters(Option<Vec<String>>)
:A list of values for the parameters in a query. The values are applied sequentially to the parameters in the query in the order in which the parameters occur.
- On success, responds with
StartQueryExecutionOutput
with field(s):query_execution_id(Option<String>)
:The unique ID of the query that ran as a result of this request.
- On failure, responds with
SdkError<StartQueryExecutionError>
sourcepub fn stop_query_execution(&self) -> StopQueryExecution
pub fn stop_query_execution(&self) -> StopQueryExecution
Constructs a fluent builder for the StopQueryExecution
operation.
- The fluent builder is configurable:
query_execution_id(impl Into<String>)
/set_query_execution_id(Option<String>)
:The unique ID of the query execution to stop.
- On success, responds with
StopQueryExecutionOutput
- On failure, responds with
SdkError<StopQueryExecutionError>
sourcepub fn tag_resource(&self) -> TagResource
pub fn tag_resource(&self) -> TagResource
Constructs a fluent builder for the TagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:Specifies the ARN of the Athena resource (workgroup or data catalog) to which tags are to be added.
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:A collection of one or more tags, separated by commas, to be added to an Athena workgroup or data catalog resource.
- On success, responds with
TagResourceOutput
- On failure, responds with
SdkError<TagResourceError>
sourcepub fn untag_resource(&self) -> UntagResource
pub fn untag_resource(&self) -> UntagResource
Constructs a fluent builder for the UntagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:Specifies the ARN of the resource from which tags are to be removed.
tag_keys(Vec<String>)
/set_tag_keys(Option<Vec<String>>)
:A comma-separated list of one or more tag keys whose tags are to be removed from the specified resource.
- On success, responds with
UntagResourceOutput
- On failure, responds with
SdkError<UntagResourceError>
sourcepub fn update_data_catalog(&self) -> UpdateDataCatalog
pub fn update_data_catalog(&self) -> UpdateDataCatalog
Constructs a fluent builder for the UpdateDataCatalog
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The name of the data catalog to update. The catalog name must be unique for the Amazon Web Services account and can use a maximum of 127 alphanumeric, underscore, at sign, or hyphen characters. The remainder of the length constraint of 256 is reserved for use by Athena.
r#type(DataCatalogType)
/set_type(Option<DataCatalogType>)
:Specifies the type of data catalog to update. Specify
LAMBDA
for a federated catalog,HIVE
for an external hive metastore, orGLUE
for an Glue Data Catalog.description(impl Into<String>)
/set_description(Option<String>)
:New or modified text that describes the data catalog.
parameters(HashMap<String, String>)
/set_parameters(Option<HashMap<String, String>>)
:Specifies the Lambda function or functions to use for updating the data catalog. This is a mapping whose values depend on the catalog type.
-
For the
HIVE
data catalog type, use the following syntax. Themetadata-function
parameter is required.The sdk-version
parameter is optional and defaults to the currently supported version.metadata-function=lambda_arn, sdk-version=version_number
-
For the
LAMBDA
data catalog type, use one of the following sets of required parameters, but not both.-
If you have one Lambda function that processes metadata and another for reading the actual data, use the following syntax. Both parameters are required.
metadata-function=lambda_arn, record-function=lambda_arn
-
If you have a composite Lambda function that processes both metadata and data, use the following syntax to specify your Lambda function.
function=lambda_arn
-
-
- On success, responds with
UpdateDataCatalogOutput
- On failure, responds with
SdkError<UpdateDataCatalogError>
sourcepub fn update_named_query(&self) -> UpdateNamedQuery
pub fn update_named_query(&self) -> UpdateNamedQuery
Constructs a fluent builder for the UpdateNamedQuery
operation.
- The fluent builder is configurable:
named_query_id(impl Into<String>)
/set_named_query_id(Option<String>)
:The unique identifier (UUID) of the query.
name(impl Into<String>)
/set_name(Option<String>)
:The name of the query.
description(impl Into<String>)
/set_description(Option<String>)
:The query description.
query_string(impl Into<String>)
/set_query_string(Option<String>)
:The contents of the query with all query statements.
- On success, responds with
UpdateNamedQueryOutput
- On failure, responds with
SdkError<UpdateNamedQueryError>
sourcepub fn update_prepared_statement(&self) -> UpdatePreparedStatement
pub fn update_prepared_statement(&self) -> UpdatePreparedStatement
Constructs a fluent builder for the UpdatePreparedStatement
operation.
- The fluent builder is configurable:
statement_name(impl Into<String>)
/set_statement_name(Option<String>)
:The name of the prepared statement.
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The workgroup for the prepared statement.
query_statement(impl Into<String>)
/set_query_statement(Option<String>)
:The query string for the prepared statement.
description(impl Into<String>)
/set_description(Option<String>)
:The description of the prepared statement.
- On success, responds with
UpdatePreparedStatementOutput
- On failure, responds with
SdkError<UpdatePreparedStatementError>
sourcepub fn update_work_group(&self) -> UpdateWorkGroup
pub fn update_work_group(&self) -> UpdateWorkGroup
Constructs a fluent builder for the UpdateWorkGroup
operation.
- The fluent builder is configurable:
work_group(impl Into<String>)
/set_work_group(Option<String>)
:The specified workgroup that will be updated.
description(impl Into<String>)
/set_description(Option<String>)
:The workgroup description.
configuration_updates(WorkGroupConfigurationUpdates)
/set_configuration_updates(Option<WorkGroupConfigurationUpdates>)
:The workgroup configuration that will be updated for the given workgroup.
state(WorkGroupState)
/set_state(Option<WorkGroupState>)
:The workgroup state that will be updated for the given workgroup.
- On success, responds with
UpdateWorkGroupOutput
- On failure, responds with
SdkError<UpdateWorkGroupError>
sourceimpl Client
impl Client
sourcepub fn from_conf_conn<C, E>(conf: Config, conn: C) -> Self where
C: SmithyConnector<Error = E> + Send + 'static,
E: Into<ConnectorError>,
pub fn from_conf_conn<C, E>(conf: Config, conn: C) -> Self where
C: SmithyConnector<Error = E> + Send + 'static,
E: Into<ConnectorError>,
Creates a client with the given service config and connector override.
Trait Implementations
sourceimpl From<Client<DynConnector, DynMiddleware<DynConnector>, Standard>> for Client
impl From<Client<DynConnector, DynMiddleware<DynConnector>, Standard>> for Client
sourcefn from(client: Client<DynConnector, DynMiddleware<DynConnector>>) -> Self
fn from(client: Client<DynConnector, DynMiddleware<DynConnector>>) -> Self
Converts to this type from the input type.
Auto Trait Implementations
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more