@Generated(value="software.amazon.awssdk:codegen") @ThreadSafe public interface AppConfigDataAsyncClient extends SdkClient
builder() method.
AppConfig Data provides the data plane APIs your application uses to retrieve configuration data. Here's how it works:
Your application retrieves configuration data by first establishing a configuration session using the AppConfig Data StartConfigurationSession API action. Your session's client then makes periodic calls to GetLatestConfiguration to check for and retrieve the latest data available.
When calling StartConfigurationSession, your code sends the following information:
Identifiers (ID or name) of an AppConfig application, environment, and configuration profile that the session tracks.
(Optional) The minimum amount of time the session's client must wait between calls to
GetLatestConfiguration.
In response, AppConfig provides an InitialConfigurationToken to be given to the session's client and
used the first time it calls GetLatestConfiguration for that session.
When calling GetLatestConfiguration, your client code sends the most recent
ConfigurationToken value it has and receives in response:
NextPollConfigurationToken: the ConfigurationToken value to use on the next call to
GetLatestConfiguration.
NextPollIntervalInSeconds: the duration the client should wait before making its next call to
GetLatestConfiguration. This duration may vary over the course of the session, so it should be used
instead of the value sent on the StartConfigurationSession call.
The configuration: the latest data intended for the session. This may be empty if the client already has the latest version of the configuration.
For more information and to view example CLI commands that show how to retrieve a configuration using the AppConfig
Data StartConfigurationSession and GetLatestConfiguration API actions, see Receiving the
configuration in the AppConfig User Guide.
| Modifier and Type | Field and Description |
|---|---|
static String |
SERVICE_METADATA_ID
Value for looking up the service's metadata from the
ServiceMetadataProvider. |
static String |
SERVICE_NAME |
serviceNameclosestatic final String SERVICE_NAME
static final String SERVICE_METADATA_ID
ServiceMetadataProvider.static AppConfigDataAsyncClient create()
AppConfigDataAsyncClient with the region loaded from the
DefaultAwsRegionProviderChain and credentials loaded from the
DefaultCredentialsProvider.static AppConfigDataAsyncClientBuilder builder()
AppConfigDataAsyncClient.default CompletableFuture<GetLatestConfigurationResponse> getLatestConfiguration(GetLatestConfigurationRequest getLatestConfigurationRequest)
Retrieves the latest deployed configuration. This API may return empty configuration data if the client already has the latest version. For more information about this API action and to view example CLI commands that show how to use it with the StartConfigurationSession API action, see Receiving the configuration in the AppConfig User Guide.
Note the following important information.
Each configuration token is only valid for one call to GetLatestConfiguration. The
GetLatestConfiguration response includes a NextPollConfigurationToken that should
always replace the token used for the just-completed call in preparation for the next one.
GetLatestConfiguration is a priced call. For more information, see Pricing.
getLatestConfigurationRequest - default CompletableFuture<GetLatestConfigurationResponse> getLatestConfiguration(Consumer<GetLatestConfigurationRequest.Builder> getLatestConfigurationRequest)
Retrieves the latest deployed configuration. This API may return empty configuration data if the client already has the latest version. For more information about this API action and to view example CLI commands that show how to use it with the StartConfigurationSession API action, see Receiving the configuration in the AppConfig User Guide.
Note the following important information.
Each configuration token is only valid for one call to GetLatestConfiguration. The
GetLatestConfiguration response includes a NextPollConfigurationToken that should
always replace the token used for the just-completed call in preparation for the next one.
GetLatestConfiguration is a priced call. For more information, see Pricing.
This is a convenience which creates an instance of the GetLatestConfigurationRequest.Builder avoiding the
need to create one manually via GetLatestConfigurationRequest.builder()
getLatestConfigurationRequest - A Consumer that will call methods on GetLatestConfigurationRequest.Builder to create a
request.default CompletableFuture<StartConfigurationSessionResponse> startConfigurationSession(StartConfigurationSessionRequest startConfigurationSessionRequest)
Starts a configuration session used to retrieve a deployed configuration. For more information about this API action and to view example CLI commands that show how to use it with the GetLatestConfiguration API action, see Receiving the configuration in the AppConfig User Guide.
startConfigurationSessionRequest - default CompletableFuture<StartConfigurationSessionResponse> startConfigurationSession(Consumer<StartConfigurationSessionRequest.Builder> startConfigurationSessionRequest)
Starts a configuration session used to retrieve a deployed configuration. For more information about this API action and to view example CLI commands that show how to use it with the GetLatestConfiguration API action, see Receiving the configuration in the AppConfig User Guide.
This is a convenience which creates an instance of the StartConfigurationSessionRequest.Builder avoiding
the need to create one manually via StartConfigurationSessionRequest.builder()
startConfigurationSessionRequest - A Consumer that will call methods on StartConfigurationSessionRequest.Builder to create a
request.Copyright © 2023. All rights reserved.