Interface ResourceGroupsTaggingApiAsyncClient
- All Superinterfaces:
AutoCloseable
,AwsClient
,SdkAutoCloseable
,SdkClient
builder()
method.The asynchronous client performs non-blocking I/O when configured with any
SdkAsyncHttpClient
supported in the SDK. However, full non-blocking is not guaranteed as the async client may
perform blocking calls in some cases such as credentials retrieval and endpoint discovery as part of the async API
call.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Value for looking up the service's metadata from theServiceMetadataProvider
.static final String
-
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Create a builder that can be used to configure and create aResourceGroupsTaggingApiAsyncClient
.create()
Create aResourceGroupsTaggingApiAsyncClient
with the region loaded from theDefaultAwsRegionProviderChain
and credentials loaded from theDefaultCredentialsProvider
.describeReportCreation
(Consumer<DescribeReportCreationRequest.Builder> describeReportCreationRequest) Describes the status of theStartReportCreation
operation.describeReportCreation
(DescribeReportCreationRequest describeReportCreationRequest) Describes the status of theStartReportCreation
operation.getComplianceSummary
(Consumer<GetComplianceSummaryRequest.Builder> getComplianceSummaryRequest) Returns a table that shows counts of resources that are noncompliant with their tag policies.getComplianceSummary
(GetComplianceSummaryRequest getComplianceSummaryRequest) Returns a table that shows counts of resources that are noncompliant with their tag policies.default GetComplianceSummaryPublisher
getComplianceSummaryPaginator
(Consumer<GetComplianceSummaryRequest.Builder> getComplianceSummaryRequest) This is a variant ofgetComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation.default GetComplianceSummaryPublisher
getComplianceSummaryPaginator
(GetComplianceSummaryRequest getComplianceSummaryRequest) This is a variant ofgetComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation.default CompletableFuture
<GetResourcesResponse> Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.default CompletableFuture
<GetResourcesResponse> getResources
(Consumer<GetResourcesRequest.Builder> getResourcesRequest) Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.default CompletableFuture
<GetResourcesResponse> getResources
(GetResourcesRequest getResourcesRequest) Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.default GetResourcesPublisher
This is a variant ofgetResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.default GetResourcesPublisher
getResourcesPaginator
(Consumer<GetResourcesRequest.Builder> getResourcesRequest) This is a variant ofgetResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.default GetResourcesPublisher
getResourcesPaginator
(GetResourcesRequest getResourcesRequest) This is a variant ofgetResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.default CompletableFuture
<GetTagKeysResponse> Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.default CompletableFuture
<GetTagKeysResponse> getTagKeys
(Consumer<GetTagKeysRequest.Builder> getTagKeysRequest) Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.default CompletableFuture
<GetTagKeysResponse> getTagKeys
(GetTagKeysRequest getTagKeysRequest) Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.default GetTagKeysPublisher
This is a variant ofgetTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.default GetTagKeysPublisher
getTagKeysPaginator
(Consumer<GetTagKeysRequest.Builder> getTagKeysRequest) This is a variant ofgetTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.default GetTagKeysPublisher
getTagKeysPaginator
(GetTagKeysRequest getTagKeysRequest) This is a variant ofgetTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.default CompletableFuture
<GetTagValuesResponse> getTagValues
(Consumer<GetTagValuesRequest.Builder> getTagValuesRequest) Returns all tag values for the specified key that are used in the specified Amazon Web Services Region for the calling account.default CompletableFuture
<GetTagValuesResponse> getTagValues
(GetTagValuesRequest getTagValuesRequest) Returns all tag values for the specified key that are used in the specified Amazon Web Services Region for the calling account.default GetTagValuesPublisher
getTagValuesPaginator
(Consumer<GetTagValuesRequest.Builder> getTagValuesRequest) This is a variant ofgetTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation.default GetTagValuesPublisher
getTagValuesPaginator
(GetTagValuesRequest getTagValuesRequest) This is a variant ofgetTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation.The SDK service client configuration exposes client settings to the user, e.g., ClientOverrideConfigurationstartReportCreation
(Consumer<StartReportCreationRequest.Builder> startReportCreationRequest) Generates a report that lists all tagged resources in the accounts across your organization and tells whether each resource is compliant with the effective tag policy.startReportCreation
(StartReportCreationRequest startReportCreationRequest) Generates a report that lists all tagged resources in the accounts across your organization and tells whether each resource is compliant with the effective tag policy.default CompletableFuture
<TagResourcesResponse> tagResources
(Consumer<TagResourcesRequest.Builder> tagResourcesRequest) Applies one or more tags to the specified resources.default CompletableFuture
<TagResourcesResponse> tagResources
(TagResourcesRequest tagResourcesRequest) Applies one or more tags to the specified resources.default CompletableFuture
<UntagResourcesResponse> untagResources
(Consumer<UntagResourcesRequest.Builder> untagResourcesRequest) Removes the specified tags from the specified resources.default CompletableFuture
<UntagResourcesResponse> untagResources
(UntagResourcesRequest untagResourcesRequest) Removes the specified tags from the specified resources.Methods inherited from interface software.amazon.awssdk.utils.SdkAutoCloseable
close
Methods inherited from interface software.amazon.awssdk.core.SdkClient
serviceName
-
Field Details
-
SERVICE_NAME
- See Also:
-
SERVICE_METADATA_ID
Value for looking up the service's metadata from theServiceMetadataProvider
.- See Also:
-
-
Method Details
-
describeReportCreation
default CompletableFuture<DescribeReportCreationResponse> describeReportCreation(DescribeReportCreationRequest describeReportCreationRequest) Describes the status of the
StartReportCreation
operation.You can call this operation only from the organization's management account and from the us-east-1 Region.
- Parameters:
describeReportCreationRequest
-- Returns:
- A Java Future containing the result of the DescribeReportCreation operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
describeReportCreation
default CompletableFuture<DescribeReportCreationResponse> describeReportCreation(Consumer<DescribeReportCreationRequest.Builder> describeReportCreationRequest) Describes the status of the
StartReportCreation
operation.You can call this operation only from the organization's management account and from the us-east-1 Region.
This is a convenience which creates an instance of the
DescribeReportCreationRequest.Builder
avoiding the need to create one manually viaDescribeReportCreationRequest.builder()
- Parameters:
describeReportCreationRequest
- AConsumer
that will call methods onDescribeReportCreationRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the DescribeReportCreation operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
getComplianceSummary
default CompletableFuture<GetComplianceSummaryResponse> getComplianceSummary(GetComplianceSummaryRequest getComplianceSummaryRequest) Returns a table that shows counts of resources that are noncompliant with their tag policies.
For more information on tag policies, see Tag Policies in the Organizations User Guide.
You can call this operation only from the organization's management account and from the us-east-1 Region.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Parameters:
getComplianceSummaryRequest
-- Returns:
- A Java Future containing the result of the GetComplianceSummary operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
getComplianceSummary
default CompletableFuture<GetComplianceSummaryResponse> getComplianceSummary(Consumer<GetComplianceSummaryRequest.Builder> getComplianceSummaryRequest) Returns a table that shows counts of resources that are noncompliant with their tag policies.
For more information on tag policies, see Tag Policies in the Organizations User Guide.
You can call this operation only from the organization's management account and from the us-east-1 Region.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.
This is a convenience which creates an instance of the
GetComplianceSummaryRequest.Builder
avoiding the need to create one manually viaGetComplianceSummaryRequest.builder()
- Parameters:
getComplianceSummaryRequest
- AConsumer
that will call methods onGetComplianceSummaryRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the GetComplianceSummary operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
getComplianceSummaryPaginator
default GetComplianceSummaryPublisher getComplianceSummaryPaginator(GetComplianceSummaryRequest getComplianceSummaryRequest) This is a variant of
getComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetComplianceSummaryPublisher publisher = client.getComplianceSummaryPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetComplianceSummaryPublisher publisher = client.getComplianceSummaryPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryResponse response) { //... }; });
Please notice that the configuration of MaxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation.- Parameters:
getComplianceSummaryRequest
-- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
getComplianceSummaryPaginator
default GetComplianceSummaryPublisher getComplianceSummaryPaginator(Consumer<GetComplianceSummaryRequest.Builder> getComplianceSummaryRequest) This is a variant of
getComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetComplianceSummaryPublisher publisher = client.getComplianceSummaryPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetComplianceSummaryPublisher publisher = client.getComplianceSummaryPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryResponse response) { //... }; });
Please notice that the configuration of MaxResults won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getComplianceSummary(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetComplianceSummaryRequest)
operation.
This is a convenience which creates an instance of the
GetComplianceSummaryRequest.Builder
avoiding the need to create one manually viaGetComplianceSummaryRequest.builder()
- Parameters:
getComplianceSummaryRequest
- AConsumer
that will call methods onGetComplianceSummaryRequest.Builder
to create a request.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
- See Also:
-
getResources
default CompletableFuture<GetResourcesResponse> getResources(GetResourcesRequest getResourcesRequest) Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.
Depending on what information you want returned, you can also specify the following:
-
Filters that specify what tags and resource types you want returned. The response includes all tags that are associated with the requested resources.
-
Information about compliance with the account's effective tag policy. For more information on tag policies, see Tag Policies in the Organizations User Guide.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Parameters:
getResourcesRequest
-- Returns:
- A Java Future containing the result of the GetResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
getResources
default CompletableFuture<GetResourcesResponse> getResources(Consumer<GetResourcesRequest.Builder> getResourcesRequest) Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.
Depending on what information you want returned, you can also specify the following:
-
Filters that specify what tags and resource types you want returned. The response includes all tags that are associated with the requested resources.
-
Information about compliance with the account's effective tag policy. For more information on tag policies, see Tag Policies in the Organizations User Guide.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.
This is a convenience which creates an instance of the
GetResourcesRequest.Builder
avoiding the need to create one manually viaGetResourcesRequest.builder()
- Parameters:
getResourcesRequest
- AConsumer
that will call methods onGetResourcesRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the GetResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
getResources
Returns all the tagged or previously tagged resources that are located in the specified Amazon Web Services Region for the account.
Depending on what information you want returned, you can also specify the following:
-
Filters that specify what tags and resource types you want returned. The response includes all tags that are associated with the requested resources.
-
Information about compliance with the account's effective tag policy. For more information on tag policies, see Tag Policies in the Organizations User Guide.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Returns:
- A Java Future containing the result of the GetResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
getResourcesPaginator
This is a variant of
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse response) { //... }; });
Please notice that the configuration of ResourcesPerPage won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getResourcesPaginator
This is a variant of
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse response) { //... }; });
Please notice that the configuration of ResourcesPerPage won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.- Parameters:
getResourcesRequest
-- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getResourcesPaginator
default GetResourcesPublisher getResourcesPaginator(Consumer<GetResourcesRequest.Builder> getResourcesRequest) This is a variant of
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetResourcesPublisher publisher = client.getResourcesPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesResponse response) { //... }; });
Please notice that the configuration of ResourcesPerPage won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getResources(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetResourcesRequest)
operation.
This is a convenience which creates an instance of the
GetResourcesRequest.Builder
avoiding the need to create one manually viaGetResourcesRequest.builder()
- Parameters:
getResourcesRequest
- AConsumer
that will call methods onGetResourcesRequest.Builder
to create a request.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeys
Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Parameters:
getTagKeysRequest
-- Returns:
- A Java Future containing the result of the GetTagKeys operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeys
default CompletableFuture<GetTagKeysResponse> getTagKeys(Consumer<GetTagKeysRequest.Builder> getTagKeysRequest) Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.
This is a convenience which creates an instance of the
GetTagKeysRequest.Builder
avoiding the need to create one manually viaGetTagKeysRequest.builder()
- Parameters:
getTagKeysRequest
- AConsumer
that will call methods onGetTagKeysRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the GetTagKeys operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeys
Returns all tag keys currently in use in the specified Amazon Web Services Region for the calling account.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Returns:
- A Java Future containing the result of the GetTagKeys operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeysPaginator
This is a variant of
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse response) { //... }; });
Please notice that the configuration of null won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeysPaginator
This is a variant of
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse response) { //... }; });
Please notice that the configuration of null won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.- Parameters:
getTagKeysRequest
-- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagKeysPaginator
default GetTagKeysPublisher getTagKeysPaginator(Consumer<GetTagKeysRequest.Builder> getTagKeysRequest) This is a variant of
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagKeysPublisher publisher = client.getTagKeysPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysResponse response) { //... }; });
Please notice that the configuration of null won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTagKeys(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagKeysRequest)
operation.
This is a convenience which creates an instance of the
GetTagKeysRequest.Builder
avoiding the need to create one manually viaGetTagKeysRequest.builder()
- Parameters:
getTagKeysRequest
- AConsumer
that will call methods onGetTagKeysRequest.Builder
to create a request.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagValues
default CompletableFuture<GetTagValuesResponse> getTagValues(GetTagValuesRequest getTagValuesRequest) Returns all tag values for the specified key that are used in the specified Amazon Web Services Region for the calling account.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.- Parameters:
getTagValuesRequest
-- Returns:
- A Java Future containing the result of the GetTagValues operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagValues
default CompletableFuture<GetTagValuesResponse> getTagValues(Consumer<GetTagValuesRequest.Builder> getTagValuesRequest) Returns all tag values for the specified key that are used in the specified Amazon Web Services Region for the calling account.
This operation supports pagination, where the response can be sent in multiple pages. You should check the
PaginationToken
response parameter to determine if there are additional results available to return. Repeat the query, passing thePaginationToken
response parameter value as an input to the next request until you recieve anull
value. A null value forPaginationToken
indicates that there are no more results waiting to be returned.
This is a convenience which creates an instance of the
GetTagValuesRequest.Builder
avoiding the need to create one manually viaGetTagValuesRequest.builder()
- Parameters:
getTagValuesRequest
- AConsumer
that will call methods onGetTagValuesRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the GetTagValues operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagValuesPaginator
This is a variant of
getTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagValuesPublisher publisher = client.getTagValuesPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagValuesPublisher publisher = client.getTagValuesPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesResponse response) { //... }; });
Please notice that the configuration of null won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation.- Parameters:
getTagValuesRequest
-- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
getTagValuesPaginator
default GetTagValuesPublisher getTagValuesPaginator(Consumer<GetTagValuesRequest.Builder> getTagValuesRequest) This is a variant of
getTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation. The return type is a custom publisher that can be subscribed to request a stream of response pages. SDK will internally handle making service calls for you.When the operation is called, an instance of this class is returned. At this point, no service calls are made yet and so there is no guarantee that the request is valid. If there are errors in your request, you will see the failures only after you start streaming the data. The subscribe method should be called as a request to start streaming data. For more info, see
Publisher.subscribe(org.reactivestreams.Subscriber)
. Each call to the subscribe method will result in a newSubscription
i.e., a new contract to stream data from the starting request.The following are few ways to use the response class:
1) Using the subscribe helper methodsoftware.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagValuesPublisher publisher = client.getTagValuesPaginator(request); CompletableFuture<Void> future = publisher.subscribe(res -> { // Do something with the response }); future.get();
software.amazon.awssdk.services.resourcegroupstaggingapi.paginators.GetTagValuesPublisher publisher = client.getTagValuesPaginator(request); publisher.subscribe(new Subscriber<software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesResponse>() { public void onSubscribe(org.reactivestreams.Subscriber subscription) { //... }; public void onNext(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesResponse response) { //... }; });
Please notice that the configuration of null won't limit the number of results you get with the paginator. It only limits the number of results in each page.
Note: If you prefer to have control on service calls, use the
getTagValues(software.amazon.awssdk.services.resourcegroupstaggingapi.model.GetTagValuesRequest)
operation.
This is a convenience which creates an instance of the
GetTagValuesRequest.Builder
avoiding the need to create one manually viaGetTagValuesRequest.builder()
- Parameters:
getTagValuesRequest
- AConsumer
that will call methods onGetTagValuesRequest.Builder
to create a request.- Returns:
- A custom publisher that can be subscribed to request a stream of response pages.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- PaginationTokenExpiredException A
PaginationToken
is valid for a maximum of 15 minutes. Your request was denied because the specifiedPaginationToken
has expired. - SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
startReportCreation
default CompletableFuture<StartReportCreationResponse> startReportCreation(StartReportCreationRequest startReportCreationRequest) Generates a report that lists all tagged resources in the accounts across your organization and tells whether each resource is compliant with the effective tag policy. Compliance data is refreshed daily. The report is generated asynchronously.
The generated report is saved to the following location:
s3://example-bucket/AwsTagPolicies/o-exampleorgid/YYYY-MM-ddTHH:mm:ssZ/report.csv
You can call this operation only from the organization's management account and from the us-east-1 Region.
- Parameters:
startReportCreationRequest
-- Returns:
- A Java Future containing the result of the StartReportCreation operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConcurrentModificationException The target of the operation is currently being modified by a different request. Try again later.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- See Also:
-
startReportCreation
default CompletableFuture<StartReportCreationResponse> startReportCreation(Consumer<StartReportCreationRequest.Builder> startReportCreationRequest) Generates a report that lists all tagged resources in the accounts across your organization and tells whether each resource is compliant with the effective tag policy. Compliance data is refreshed daily. The report is generated asynchronously.
The generated report is saved to the following location:
s3://example-bucket/AwsTagPolicies/o-exampleorgid/YYYY-MM-ddTHH:mm:ssZ/report.csv
You can call this operation only from the organization's management account and from the us-east-1 Region.
This is a convenience which creates an instance of the
StartReportCreationRequest.Builder
avoiding the need to create one manually viaStartReportCreationRequest.builder()
- Parameters:
startReportCreationRequest
- AConsumer
that will call methods onStartReportCreationRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the StartReportCreation operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- ConcurrentModificationException The target of the operation is currently being modified by a different request. Try again later.
- ConstraintViolationException The request was denied because performing this operation violates a
constraint.
Some of the reasons in the following list might not apply to this specific operation.
-
You must meet the prerequisites for using tag policies. For information, see Prerequisites and Permissions for Using Tag Policies in the Organizations User Guide.
-
You must enable the tag policies service principal (
tagpolicies.tag.amazonaws.com
) to integrate with Organizations For information, see EnableAWSServiceAccess. -
You must have a tag policy attached to the organization root, an OU, or an account.
-
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- See Also:
-
tagResources
default CompletableFuture<TagResourcesResponse> tagResources(TagResourcesRequest tagResourcesRequest) Applies one or more tags to the specified resources. Note the following:
-
Not all resources can have tags. For a list of services with resources that support tagging using this operation, see Services that support the Resource Groups Tagging API. If the resource doesn't yet support this operation, the resource's service might support tagging using its own API operations. For more information, refer to the documentation for that service.
-
Each resource can have up to 50 tags. For other limits, see Tag Naming and Usage Conventions in the Amazon Web Services General Reference.
-
You can only tag resources that are located in the specified Amazon Web Services Region for the Amazon Web Services account.
-
To add tags to a resource, you need the necessary permissions for the service that the resource belongs to as well as permissions for adding tags. For more information, see the documentation for each service.
Do not store personally identifiable information (PII) or other confidential or sensitive information in tags. We use tags to provide you with billing and administration services. Tags are not intended to be used for private or sensitive data.
Minimum permissions
In addition to the
tag:TagResources
permission required by this operation, you must also have the tagging permission defined by the service that created the resource. For example, to tag an Amazon EC2 instance using theTagResources
operation, you must have both of the following permissions:-
tag:TagResource
-
ec2:CreateTags
- Parameters:
tagResourcesRequest
-- Returns:
- A Java Future containing the result of the TagResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
tagResources
default CompletableFuture<TagResourcesResponse> tagResources(Consumer<TagResourcesRequest.Builder> tagResourcesRequest) Applies one or more tags to the specified resources. Note the following:
-
Not all resources can have tags. For a list of services with resources that support tagging using this operation, see Services that support the Resource Groups Tagging API. If the resource doesn't yet support this operation, the resource's service might support tagging using its own API operations. For more information, refer to the documentation for that service.
-
Each resource can have up to 50 tags. For other limits, see Tag Naming and Usage Conventions in the Amazon Web Services General Reference.
-
You can only tag resources that are located in the specified Amazon Web Services Region for the Amazon Web Services account.
-
To add tags to a resource, you need the necessary permissions for the service that the resource belongs to as well as permissions for adding tags. For more information, see the documentation for each service.
Do not store personally identifiable information (PII) or other confidential or sensitive information in tags. We use tags to provide you with billing and administration services. Tags are not intended to be used for private or sensitive data.
Minimum permissions
In addition to the
tag:TagResources
permission required by this operation, you must also have the tagging permission defined by the service that created the resource. For example, to tag an Amazon EC2 instance using theTagResources
operation, you must have both of the following permissions:-
tag:TagResource
-
ec2:CreateTags
This is a convenience which creates an instance of the
TagResourcesRequest.Builder
avoiding the need to create one manually viaTagResourcesRequest.builder()
- Parameters:
tagResourcesRequest
- AConsumer
that will call methods onTagResourcesRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the TagResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
untagResources
default CompletableFuture<UntagResourcesResponse> untagResources(UntagResourcesRequest untagResourcesRequest) Removes the specified tags from the specified resources. When you specify a tag key, the action removes both that key and its associated value. The operation succeeds even if you attempt to remove tags from a resource that were already removed. Note the following:
-
To remove tags from a resource, you need the necessary permissions for the service that the resource belongs to as well as permissions for removing tags. For more information, see the documentation for the service whose resource you want to untag.
-
You can only tag resources that are located in the specified Amazon Web Services Region for the calling Amazon Web Services account.
Minimum permissions
In addition to the
tag:UntagResources
permission required by this operation, you must also have the remove tags permission defined by the service that created the resource. For example, to remove the tags from an Amazon EC2 instance using theUntagResources
operation, you must have both of the following permissions:-
tag:UntagResource
-
ec2:DeleteTags
- Parameters:
untagResourcesRequest
-- Returns:
- A Java Future containing the result of the UntagResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
untagResources
default CompletableFuture<UntagResourcesResponse> untagResources(Consumer<UntagResourcesRequest.Builder> untagResourcesRequest) Removes the specified tags from the specified resources. When you specify a tag key, the action removes both that key and its associated value. The operation succeeds even if you attempt to remove tags from a resource that were already removed. Note the following:
-
To remove tags from a resource, you need the necessary permissions for the service that the resource belongs to as well as permissions for removing tags. For more information, see the documentation for the service whose resource you want to untag.
-
You can only tag resources that are located in the specified Amazon Web Services Region for the calling Amazon Web Services account.
Minimum permissions
In addition to the
tag:UntagResources
permission required by this operation, you must also have the remove tags permission defined by the service that created the resource. For example, to remove the tags from an Amazon EC2 instance using theUntagResources
operation, you must have both of the following permissions:-
tag:UntagResource
-
ec2:DeleteTags
This is a convenience which creates an instance of the
UntagResourcesRequest.Builder
avoiding the need to create one manually viaUntagResourcesRequest.builder()
- Parameters:
untagResourcesRequest
- AConsumer
that will call methods onUntagResourcesRequest.Builder
to create a request.- Returns:
- A Java Future containing the result of the UntagResources operation returned by the service.
The CompletableFuture returned by this method can be completed exceptionally with the following exceptions. The exception returned is wrapped with CompletionException, so you need to invokeThrowable.getCause()
to retrieve the underlying exception.- InvalidParameterException This error indicates one of the following:
-
A parameter is missing.
-
A malformed string was supplied for the request parameter.
-
An out-of-range value was supplied for the request parameter.
-
The target ID is invalid, unsupported, or doesn't exist.
-
You can't access the Amazon S3 bucket for report storage. For more information, see Additional Requirements for Organization-wide Tag Compliance Reports in the Organizations User Guide.
-
- ThrottledException The request was denied to limit the frequency of submitted requests.
- InternalServiceException The request processing failed because of an unknown error, exception, or failure. You can retry the request.
- SdkException Base class for all exceptions that can be thrown by the SDK (both service and client). Can be used for catch all scenarios.
- SdkClientException If any client side error occurs such as an IO related failure, failure to get credentials, etc.
- ResourceGroupsTaggingApiException Base class for all service exceptions. Unknown exceptions will be thrown as an instance of this type.
- InvalidParameterException This error indicates one of the following:
- See Also:
-
-
serviceClientConfiguration
Description copied from interface:SdkClient
The SDK service client configuration exposes client settings to the user, e.g., ClientOverrideConfiguration- Specified by:
serviceClientConfiguration
in interfaceAwsClient
- Specified by:
serviceClientConfiguration
in interfaceSdkClient
- Returns:
- SdkServiceClientConfiguration
-
create
Create aResourceGroupsTaggingApiAsyncClient
with the region loaded from theDefaultAwsRegionProviderChain
and credentials loaded from theDefaultCredentialsProvider
. -
builder
Create a builder that can be used to configure and create aResourceGroupsTaggingApiAsyncClient
.
-